From 249f660d40cea5b6667e231b0ed9c32874df00cd Mon Sep 17 00:00:00 2001 From: Jon Staab Date: Tue, 22 Oct 2024 11:04:40 -0700 Subject: [PATCH] Parameterize app name --- .env | 1 + src/app/components/InfoHandle.svelte | 3 ++- src/app/components/InfoKeys.svelte | 5 +++-- src/app/components/InfoNostr.svelte | 5 +++-- src/app/components/InfoRelay.svelte | 3 ++- src/app/components/Landing.svelte | 3 ++- src/app/components/LogIn.svelte | 3 ++- src/app/components/MenuSettings.svelte | 7 ++++--- src/app/components/MenuSpace.svelte | 3 ++- src/app/components/PrimaryNav.svelte | 12 ++++++------ src/app/components/SignUp.svelte | 3 ++- src/app/components/SpaceCreateExternal.svelte | 7 ++++--- src/app/state.ts | 10 +++++++++- src/routes/chat/[chat]/+page.svelte | 4 ++-- src/routes/home/+page.svelte | 3 ++- src/routes/settings/+page.svelte | 4 ++-- src/routes/settings/about/+page.svelte | 3 ++- tailwind.config.js | 4 +--- 18 files changed, 51 insertions(+), 32 deletions(-) diff --git a/.env b/.env index 879775a..35912de 100644 --- a/.env +++ b/.env @@ -1,3 +1,4 @@ VITE_DEFAULT_PUBKEYS=fe7f6bc6f7338b76bbf80db402ade65953e20b2f23e66e898204b63cc42539a3,391819e2f2f13b90cac7209419eb574ef7c0d1f4e81867fc24c47a3ce5e8a248,84dee6e676e5bb67b4ad4e042cf70cbd8681155db535942fcc6a0533858a7240,dace63b00c42e6e017d00dd190a9328386002ff597b841eb5ef91de4f1ce8491,82341f882b6eabcd2ba7f1ef90aad961cf074af15b9ef44a09f9d2a8fbfbe6a2,58c741aa630c2da35a56a77c1d05381908bd10504fdd2d8b43f725efa6d23196,eeb11961b25442b16389fe6c7ebea9adf0ac36dd596816ea7119e521b8821b9e,b676ded7c768d66a757aa3967b1243d90bf57afb09d1044d3219d8d424e4aea0,61066504617ee79387021e18c89fb79d1ddbc3e7bff19cf2298f40466f8715e9 +VITE_PLATFORM_NAME=Flotilla VITE_PLATFORM_LOGO=/flotilla.png VITE_PLATFORM_RELAY= diff --git a/src/app/components/InfoHandle.svelte b/src/app/components/InfoHandle.svelte index 2b3d154..598f11e 100644 --- a/src/app/components/InfoHandle.svelte +++ b/src/app/components/InfoHandle.svelte @@ -2,6 +2,7 @@ import Button from "@lib/components/Button.svelte" import Link from "@lib/components/Link.svelte" import ModalHeader from "@lib/components/ModalHeader.svelte" + import {PLATFORM_NAME} from "@app/state"
@@ -9,7 +10,7 @@
What is a nostr address?

- Flotilla hosts spaces on the Nostr protocol. Nostr uses "nostr addresses" to make it easier for people to find you, without having to memorize your public key (your user id). diff --git a/src/app/components/InfoKeys.svelte b/src/app/components/InfoKeys.svelte index 0bbc772..9be2333 100644 --- a/src/app/components/InfoKeys.svelte +++ b/src/app/components/InfoKeys.svelte @@ -2,6 +2,7 @@ import Link from "@lib/components/Link.svelte" import Button from "@lib/components/Button.svelte" import ModalHeader from "@lib/components/ModalHeader.svelte" + import {PLATFORM_NAME} from "@app/state"

@@ -22,8 +23,8 @@

It's very important to keep private keys safe, but this can sometimes be confusing for - newcomers. This is why flotilla supports remote signer login. These services can - store your keys securely for you, giving you access using a username and password. + newcomers. This is why {PLATFORM_NAME} supports remote signer login. These services + can store your keys securely for you, giving you access using a username and password.

diff --git a/src/app/components/InfoNostr.svelte b/src/app/components/InfoNostr.svelte index 072b638..7f94c2e 100644 --- a/src/app/components/InfoNostr.svelte +++ b/src/app/components/InfoNostr.svelte @@ -2,6 +2,7 @@ import Link from "@lib/components/Link.svelte" import Button from "@lib/components/Button.svelte" import ModalHeader from "@lib/components/ModalHeader.svelte" + import {PLATFORM_NAME} from "@app/state"
@@ -15,8 +16,8 @@

This can be a little confusing when you're just getting started, but as long as you're using - Flotilla, it will work just like a normal app. When you're ready to start exploring nostr, visit - your settings page to learn more. + {PLATFORM_NAME}, it will work just like a normal app. When you're ready to start exploring + nostr, visit your settings page to learn more.

diff --git a/src/app/components/InfoRelay.svelte b/src/app/components/InfoRelay.svelte index 2ad7682..b159005 100644 --- a/src/app/components/InfoRelay.svelte +++ b/src/app/components/InfoRelay.svelte @@ -2,6 +2,7 @@ import Button from "@lib/components/Button.svelte" import Link from "@lib/components/Link.svelte" import ModalHeader from "@lib/components/ModalHeader.svelte" + import {PLATFORM_NAME} from "@app/state"
@@ -9,7 +10,7 @@
What is a relay?

- Flotilla hosts spaces on the Nostr protocol. Nostr uses "relays" to host data, which are special-purpose servers that speak nostr's language. This means that anyone can host their own data, making the web more decentralized and diff --git a/src/app/components/Landing.svelte b/src/app/components/Landing.svelte index abed902..384ed02 100644 --- a/src/app/components/Landing.svelte +++ b/src/app/components/Landing.svelte @@ -5,6 +5,7 @@ import CardButton from "@lib/components/CardButton.svelte" import LogIn from "@app/components/LogIn.svelte" import SignUp from "@app/components/SignUp.svelte" + import {PLATFORM_NAME} from "@app/state" import {pushModal} from "@app/modal" const logIn = () => pushModal(LogIn) @@ -15,7 +16,7 @@

-

Welcome to Flotilla!

+

Welcome to {PLATFORM_NAME}!

The chat app built for sovereign communities.

, which allows you to own your social identity.

diff --git a/src/app/components/MenuSettings.svelte b/src/app/components/MenuSettings.svelte index 51311e6..89a5152 100644 --- a/src/app/components/MenuSettings.svelte +++ b/src/app/components/MenuSettings.svelte @@ -4,6 +4,7 @@ import Button from "@lib/components/Button.svelte" import CardButton from "@lib/components/CardButton.svelte" import LogOut from "@app/components/LogOut.svelte" + import {PLATFORM_NAME} from "@app/state" import {pushModal} from "@app/modal" const logout = () => pushModal(LogOut) @@ -14,21 +15,21 @@
Relays
-
Control how Flotilla talks to the network
+
Control how {PLATFORM_NAME} talks to the network
Settings
-
Get into the details about how Flotilla works
+
Get into the details about how {PLATFORM_NAME} works
About
-
Learn about Flotilla and support the developer
+
Learn about {PLATFORM_NAME} and support the developer
- {#if !import.meta.env.VITE_PLATFORM_RELAY} + {#if !PLATFORM_RELAY}
  • {#if getMembershipUrls($userMembership).includes(url)} , which allows you to own your social identity.

    diff --git a/src/app/components/SpaceCreateExternal.svelte b/src/app/components/SpaceCreateExternal.svelte index e1aac07..c4f1c36 100644 --- a/src/app/components/SpaceCreateExternal.svelte +++ b/src/app/components/SpaceCreateExternal.svelte @@ -5,6 +5,7 @@ import ModalHeader from "@lib/components/ModalHeader.svelte" import ModalFooter from "@lib/components/ModalFooter.svelte" import SpaceInviteAccept from "@app/components/SpaceInviteAccept.svelte" + import {PLATFORM_NAME} from "@app/state" import {pushModal} from "@app/modal" const back = () => history.back() @@ -23,11 +24,11 @@

    relay.tools is a third-party - service that allows anyone to run their own relay for use with Flotilla, or any other nostr-compatible - app. + service that allows anyone to run their own relay for use with {PLATFORM_NAME}, or any other + nostr-compatible app.

    - Once you've created a relay of your own, come back here to link Flotilla with your new relay. + Once you've created a relay of your own, come back here to link {PLATFORM_NAME} with your new relay.