mirror of
https://github.com/coracle-social/coracle.git
synced 2024-09-30 00:41:12 +00:00
Add capacitorjs
This commit is contained in:
parent
8cb7fddfea
commit
139209c83e
1
.gitignore
vendored
1
.gitignore
vendored
@ -12,6 +12,7 @@ lerna-debug.log*
|
|||||||
node_modules
|
node_modules
|
||||||
dist
|
dist
|
||||||
dist-ssr
|
dist-ssr
|
||||||
|
android
|
||||||
|
|
||||||
# Editor directories and files
|
# Editor directories and files
|
||||||
.vscode/*
|
.vscode/*
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
# Current
|
# Current
|
||||||
|
|
||||||
|
- [ ] Fix multiplexing
|
||||||
- [ ] Extract libraries
|
- [ ] Extract libraries
|
||||||
- Cursor
|
- Cursor
|
||||||
- parseContent
|
- parseContent
|
||||||
|
10
capacitor.config.ts
Normal file
10
capacitor.config.ts
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
import {CapacitorConfig} from "@capacitor/cli"
|
||||||
|
|
||||||
|
const config: CapacitorConfig = {
|
||||||
|
appId: "social.coracle.app",
|
||||||
|
appName: "Coracle",
|
||||||
|
webDir: "dist",
|
||||||
|
bundledWebRuntime: false,
|
||||||
|
}
|
||||||
|
|
||||||
|
export default config
|
BIN
package-lock.json
generated
BIN
package-lock.json
generated
Binary file not shown.
@ -15,6 +15,7 @@
|
|||||||
"watch": "find src -type f | entr -r"
|
"watch": "find src -type f | entr -r"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@capacitor/cli": "^4.7.3",
|
||||||
"@sveltejs/vite-plugin-svelte": "^1.1.0",
|
"@sveltejs/vite-plugin-svelte": "^1.1.0",
|
||||||
"@typescript-eslint/eslint-plugin": "^5.50.0",
|
"@typescript-eslint/eslint-plugin": "^5.50.0",
|
||||||
"@typescript-eslint/parser": "^5.50.0",
|
"@typescript-eslint/parser": "^5.50.0",
|
||||||
@ -32,6 +33,9 @@
|
|||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@bugsnag/js": "^7.18.0",
|
"@bugsnag/js": "^7.18.0",
|
||||||
|
"@capacitor/android": "^4.7.3",
|
||||||
|
"@capacitor/core": "^4.7.3",
|
||||||
|
"@capacitor/ios": "^4.7.3",
|
||||||
"@fortawesome/fontawesome-free": "^6.2.1",
|
"@fortawesome/fontawesome-free": "^6.2.1",
|
||||||
"@noble/secp256k1": "^1.7.0",
|
"@noble/secp256k1": "^1.7.0",
|
||||||
"@scure/base": "^1.1.1",
|
"@scure/base": "^1.1.1",
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
|
import {Capacitor} from "@capacitor/core"
|
||||||
import {fly} from "svelte/transition"
|
import {fly} from "svelte/transition"
|
||||||
import {navigate} from "svelte-routing"
|
import {navigate} from "svelte-routing"
|
||||||
import {modal} from "src/partials/state"
|
import {modal} from "src/partials/state"
|
||||||
@ -43,8 +44,11 @@
|
|||||||
<i>To the Nostr Network</i>
|
<i>To the Nostr Network</i>
|
||||||
</div>
|
</div>
|
||||||
<p class="text-center">
|
<p class="text-center">
|
||||||
Click below to log in or create an account. If you have a <Anchor href={nip07} external
|
Click below to log in or create an account.
|
||||||
>compatible browser extension</Anchor> installed, we will use that.
|
{#if !Capacitor.isNativePlatform()}
|
||||||
|
If you have a <Anchor href={nip07} external>compatible browser extension</Anchor> installed,
|
||||||
|
we will use that.
|
||||||
|
{/if}
|
||||||
</p>
|
</p>
|
||||||
<div class="flex flex-col items-center gap-4">
|
<div class="flex flex-col items-center gap-4">
|
||||||
<div class="flex gap-4">
|
<div class="flex gap-4">
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
|
import {Capacitor} from "@capacitor/core"
|
||||||
import {toHex} from "src/util/nostr"
|
import {toHex} from "src/util/nostr"
|
||||||
import {toast} from "src/partials/state"
|
import {toast} from "src/partials/state"
|
||||||
import Input from "src/partials/Input.svelte"
|
import Input from "src/partials/Input.svelte"
|
||||||
@ -37,9 +38,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<Anchor type="button" on:click={logIn}>Log In</Anchor>
|
<Anchor type="button" on:click={logIn}>Log In</Anchor>
|
||||||
</div>
|
</div>
|
||||||
|
{#if !Capacitor.isNativePlatform()}
|
||||||
<p class="rounded border-2 border-solid border-warning bg-gray-8 py-3 px-6">
|
<p class="rounded border-2 border-solid border-warning bg-gray-8 py-3 px-6">
|
||||||
Note that sharing your private key directly is not recommended, instead you should use a <Anchor
|
Note that sharing your private key directly is not recommended, instead you should use a <Anchor
|
||||||
href={nip07}
|
href={nip07}
|
||||||
external>compatible browser extension</Anchor> to securely store your key.
|
external>compatible browser extension</Anchor> to securely store your key.
|
||||||
</p>
|
</p>
|
||||||
|
{/if}
|
||||||
</Content>
|
</Content>
|
||||||
|
Loading…
Reference in New Issue
Block a user