Skip to content

Commit 22c3a87

Browse files
committed
updated dogechat
1 parent 4f02fd6 commit 22c3a87

File tree

88 files changed

+514
-108
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

88 files changed

+514
-108
lines changed

README.md

+12-12

assets/logo-dark.png

147 KB

assets/logo.png

147 KB

capacitor.config.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { CapacitorConfig } from '@capacitor/cli';
22

33
const config: CapacitorConfig = {
44
appId: 'org.nostrchat.app',
5-
appName: 'NostrChat',
5+
appName: 'DogeChat',
66
webDir: 'build',
77
backgroundColor: '#343434',
88
server: {

icons/icon-128.webp

-1.75 KB
Binary file not shown.

icons/icon-192.webp

-2.69 KB
Binary file not shown.

icons/icon-256.webp

-3.72 KB
Binary file not shown.

icons/icon-48.webp

-760 Bytes
Binary file not shown.

icons/icon-512.webp

-8.76 KB
Binary file not shown.

icons/icon-72.webp

-1014 Bytes
Binary file not shown.

icons/icon-96.webp

-1.32 KB
Binary file not shown.

ios/App/App.xcodeproj/project.pbxproj

+2-2
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,7 @@
349349
CURRENT_PROJECT_VERSION = 3;
350350
DEVELOPMENT_TEAM = 3CK9WUFA83;
351351
INFOPLIST_FILE = App/Info.plist;
352-
INFOPLIST_KEY_CFBundleDisplayName = NostrChat;
352+
INFOPLIST_KEY_CFBundleDisplayName = DogeChat;
353353
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.social-networking";
354354
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
355355
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
@@ -372,7 +372,7 @@
372372
CURRENT_PROJECT_VERSION = 3;
373373
DEVELOPMENT_TEAM = 3CK9WUFA83;
374374
INFOPLIST_FILE = App/Info.plist;
375-
INFOPLIST_KEY_CFBundleDisplayName = NostrChat;
375+
INFOPLIST_KEY_CFBundleDisplayName = DogeChat;
376376
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.social-networking";
377377
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
378378
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";

ios/App/App/Info.plist

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<key>CFBundleDevelopmentRegion</key>
66
<string>en</string>
77
<key>CFBundleDisplayName</key>
8-
<string>NostrChat</string>
8+
<string>DogeChat</string>
99
<key>CFBundleExecutable</key>
1010
<string>$(EXECUTABLE_NAME)</string>
1111
<key>CFBundleIdentifier</key>

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -100,5 +100,6 @@
100100
"last 1 firefox version",
101101
"last 1 safari version"
102102
]
103-
}
103+
},
104+
"packageManager": "[email protected]+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
104105
}

public/apple-touch-icon-114x114.png

12.6 KB

public/apple-touch-icon-120x120.png

13.8 KB

public/apple-touch-icon-144x144.png

18.7 KB

public/apple-touch-icon-152x152.png

20.6 KB

public/apple-touch-icon-57x57.png

3.87 KB

public/apple-touch-icon-60x60.png

4.23 KB

public/apple-touch-icon-72x72.png

5.76 KB

public/apple-touch-icon-76x76.png

6.33 KB

public/config/chat-config.json

+58
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
{
2+
"updatedAt": "2024-08-24T03:21:11.699Z",
3+
"version": "0.1.0",
4+
"motd": "Welcome to DogeChat - A place for dogecoin enthusiasts to chat and share ideas.",
5+
"blockedWords": [
6+
"/t.me/"
7+
],
8+
"allowedLinkHostnames": [
9+
"github.com",
10+
"www.github.com",
11+
"gist.github.com",
12+
"qedprotocol.com",
13+
"www.qedprotocol.com",
14+
"blog.qedprotocol.com",
15+
"gitlab.com",
16+
"www.gitlab.com",
17+
"bitbucket.org",
18+
"www.bitbucket.org",
19+
"*.qed.me",
20+
"*.doge.toys"
21+
],
22+
"allowedImageHostnames": [
23+
"*.qed.me"
24+
],
25+
"allowedVideoHostnames": [
26+
"*.qed.me"
27+
],
28+
"userDefs": [
29+
{
30+
"id": "c3ee95cac6806bdbd2262e8f486c81ec0d2420c6bfeff34f02c54d41f3c5c731",
31+
"verifiedGroups": ["staff"],
32+
"role": "admin",
33+
"verifiedDescription": "Creator of DogeChat",
34+
"github": "cf",
35+
"twitter": "cmepeq",
36+
"profileNameClass": "staff",
37+
"inlineIcon": "staff_verified"
38+
}
39+
],
40+
"defaultChannels": [
41+
{
42+
"id": "d6e3172b630ef52fe07e922f54678028213676579eb73ef36a1bc3bfc24e101c",
43+
"name": "Dogecoin Core",
44+
"description": "Discuss all things related to Dogecoin Core Development",
45+
"creator": "c3ee95cac6806bdbd2262e8f486c81ec0d2420c6bfeff34f02c54d41f3c5c731",
46+
"created": 1678198928,
47+
"picture": ""
48+
},
49+
{
50+
"id": "35a06e207f4fdcc2aae311bcf2d237c14b58dd6991a7ecaacd8238f61f88f90f",
51+
"name": "Dogecoin Ecosystem Dev",
52+
"description": "Discuss any Dogecoin Ecosystem development topics here including SDKs, Wallets, Indexers and Layer 2s",
53+
"creator": "c3ee95cac6806bdbd2262e8f486c81ec0d2420c6bfeff34f02c54d41f3c5c731",
54+
"created": 1724475440,
55+
"picture": ""
56+
}
57+
]
58+
}

public/favicon-128.png

15.4 KB

public/favicon-16x16.png

634 Bytes

public/favicon-196x196.png

31.6 KB

public/favicon-32x32.png

1.58 KB

public/favicon-96x96.png

9.43 KB

public/favicon.ico

30.1 KB
Binary file not shown.

public/index.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@
2121
work correctly both with client-side routing and a non-root public URL.
2222
Learn how to configure a non-root public URL by running `npm run build`.
2323
-->
24-
<title>NostrChat</title>
24+
<title>DogeChat</title>
2525
<meta name="twitter:card" content="summary"/>
26-
<meta name="twitter:title" content="NostrChat"/>
26+
<meta name="twitter:title" content="DogeChat"/>
2727
<meta name="twitter:description" content="A decentralized chat application"/>
28-
<meta name="twitter:image" content="https://www.nostrchat.io/logo512.png"/>
28+
<meta name="twitter:image" content="https://dogechat.org/logo512.png"/>
2929
</head>
3030
<body>
3131
<noscript>You need to enable JavaScript to run this app.</noscript>

public/logo-large-white.png

76.8 KB

public/logo-large-white1.png

642 KB

public/logo192.png

35.2 KB

public/logo512.png

40.5 KB

public/manifest.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"short_name": "NostrChat",
3-
"name": "NostrChat",
2+
"short_name": "DogeChat",
3+
"name": "DogeChat",
44
"description": "A decentralized chat application",
55
"icons": [
66
{

public/mstile-144x144.png

18.7 KB

public/mstile-150x150.png

54.4 KB

public/mstile-310x150.png

128 KB

public/mstile-310x310.png

180 KB

public/mstile-70x70.png

15.4 KB
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

src/atoms/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import {
1818
} from 'types';
1919
import {GLOBAL_CHAT} from 'const';
2020
import Raven from 'raven/raven';
21+
import type { DogeChatConfig } from 'util/dogeChatConfig';
2122

2223
export * from 'atoms/ui';
2324

@@ -47,4 +48,5 @@ export const backupWarnAtom = atom<boolean>(false);
4748
export const activeMessageAtom = atom<string | null>(null);
4849
export const readMarkMapAtom = atom<ReadMarkMap>({});
4950
export const showRequestsAtom = atom<boolean>(false);
50-
export const spammersAtom = atom<Record<string, number>>({});
51+
export const spammersAtom = atom<Record<string, number>>({});
52+
export const dogeChatConfigAtom = atom<DogeChatConfig | null>(null);

src/const.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ export const ACCEPTABLE_LESS_PAGE_MESSAGES = 5;
1515
export const SCROLL_DETECT_THRESHOLD = 5;
1616

1717
export const GLOBAL_CHAT: Channel = {
18-
id: 'f412192fdc846952c75058e911d37a7392aa7fd2e727330f4344badc92fb8a22',
19-
name: 'Global Chat',
20-
about: 'Whatever you want it to be, just be nice',
18+
id: 'd6e3172b630ef52fe07e922f54678028213676579eb73ef36a1bc3bfc24e101c',
19+
name: 'Dogecoin Core',
20+
about: 'Discuss all things related to Dogecoin Core Development',
2121
picture: '',
22-
creator: 'aea59833635dd0868bc7cf923926e51df936405d8e6a753b78038981c75c4a74',
22+
creator: 'c3ee95cac6806bdbd2262e8f486c81ec0d2420c6bfeff34f02c54d41f3c5c731',
2323
created: 1678198928
2424
};
2525

src/hooks/use-render-content.tsx

+22
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,27 @@ import {notEmpty} from 'util/misc';
1818
const imgReg = /(https:\/\/)([^\s(["<,>/]*)(\/)[^\s[",><]*(.png|.jpg|.jpeg|.gif|.webp)(\?[^\s[",><]*)?/;
1919
const channelReg = new RegExp(`^${window.location.protocol}//${window.location.host}/channel/[a-f0-9]{64}$`, 'm');
2020

21+
const ALLOWED_LINK_DOMAINS = [
22+
'dogechat.org',
23+
'www.dogechat.org',
24+
'github.com',
25+
'www.github.com',
26+
'gist.github.com',
27+
'gitlab.com',
28+
'www.gitlab.com',
29+
'qedprotocol.com',
30+
'www.qedprotocol.com',
31+
'doge-testnet-explorer.qed.me',
32+
'doge-explorer.qed.me',
33+
];
34+
35+
function isValidLink(url: string){
36+
if(url.indexOf('https://') !== 0) return false;
37+
const parsed = new URL(url);
38+
if(ALLOWED_LINK_DOMAINS.includes(parsed.hostname)) return true;
39+
return false;
40+
}
41+
2142
const useRenderContent = () => {
2243
const [, showModal] = useModal();
2344
const styles = useStyles();
@@ -29,6 +50,7 @@ const useRenderContent = () => {
2950

3051
const renderLink = (args: IntermediateRepresentation) => {
3152
const {href} = args.attributes;
53+
if(!isValidLink(href)) return <span className='badLink'>[Link Removed]</span>;
3254

3355
if (href.match(channelReg)) {
3456
const s = href.split('/');

src/hooks/use-styles.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ const useStyles = () => {
3232
overflowX: 'hidden'
3333
},
3434
sideBarWidth: '270px',
35-
sideBarFooterHeight: '50px',
35+
sideBarFooterHeight: '60px',
36+
sideBarFooterImageHeight: '40px',
3637
headerHeight: '88px'
3738
}
3839
}

src/index.scss

+87-20
Original file line numberDiff line numberDiff line change
@@ -14,34 +14,68 @@ body {
1414
}
1515

1616

17-
body {
18-
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
19-
'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
20-
sans-serif;
21-
-webkit-font-smoothing: antialiased;
22-
-moz-osx-font-smoothing: grayscale;
17+
/* comic-neue-300 - latin */
18+
@font-face {
19+
font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
20+
font-family: 'Comic Neue';
21+
font-style: normal;
22+
font-weight: 300;
23+
src: url('assets/fonts/ComicNeue/comic-neue-v8-latin-300.woff2') format('woff2'), /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
24+
url('assets/fonts/ComicNeue/comic-neue-v8-latin-300.ttf') format('truetype'); /* Chrome 4+, Firefox 3.5+, IE 9+, Safari 3.1+, iOS 4.2+, Android Browser 2.2+ */
2325
}
24-
26+
/* comic-neue-300italic - latin */
2527
@font-face {
26-
font-weight: 400;
27-
font-family: 'Faktum';
28+
font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
29+
font-family: 'Comic Neue';
30+
font-style: italic;
31+
font-weight: 300;
32+
src: url('assets/fonts/ComicNeue/comic-neue-v8-latin-300italic.woff2') format('woff2'), /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
33+
url('assets/fonts/ComicNeue/comic-neue-v8-latin-300italic.ttf') format('truetype'); /* Chrome 4+, Firefox 3.5+, IE 9+, Safari 3.1+, iOS 4.2+, Android Browser 2.2+ */
34+
}
35+
/* comic-neue-regular - latin */
36+
@font-face {
37+
font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
38+
font-family: 'Comic Neue';
2839
font-style: normal;
29-
src: url('assets/fonts/faktum/FaktumWideMedium.otf') format('opentype'),
30-
url('assets/fonts/faktum/FaktumWideMedium.woff') format('woff'),
31-
url('assets/fonts/faktum/FaktumWideMedium.woff2') format('woff2');
32-
font-display: block;
40+
font-weight: 400;
41+
src: url('assets/fonts/ComicNeue/comic-neue-v8-latin-regular.woff2') format('woff2'), /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
42+
url('assets/fonts/ComicNeue/comic-neue-v8-latin-regular.ttf') format('truetype'); /* Chrome 4+, Firefox 3.5+, IE 9+, Safari 3.1+, iOS 4.2+, Android Browser 2.2+ */
3343
}
34-
44+
/* comic-neue-italic - latin */
3545
@font-face {
36-
font-weight: 600;
37-
font-family: 'Faktum';
46+
font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
47+
font-family: 'Comic Neue';
48+
font-style: italic;
49+
font-weight: 400;
50+
src: url('assets/fonts/ComicNeue/comic-neue-v8-latin-italic.woff2') format('woff2'), /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
51+
url('assets/fonts/ComicNeue/comic-neue-v8-latin-italic.ttf') format('truetype'); /* Chrome 4+, Firefox 3.5+, IE 9+, Safari 3.1+, iOS 4.2+, Android Browser 2.2+ */
52+
}
53+
/* comic-neue-700 - latin */
54+
@font-face {
55+
font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
56+
font-family: 'Comic Neue';
3857
font-style: normal;
39-
src: url('assets/fonts/faktum/FaktumWideSemiBold.otf') format('opentype'),
40-
url('assets/fonts/faktum/FaktumWideSemiBold.woff') format('woff'),
41-
url('assets/fonts/faktum/FaktumWideSemiBold.woff2') format('woff2');
42-
font-display: block;
58+
font-weight: 700;
59+
src: url('assets/fonts/ComicNeue/comic-neue-v8-latin-700.woff2') format('woff2'), /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
60+
url('assets/fonts/ComicNeue/comic-neue-v8-latin-700.ttf') format('truetype'); /* Chrome 4+, Firefox 3.5+, IE 9+, Safari 3.1+, iOS 4.2+, Android Browser 2.2+ */
61+
}
62+
/* comic-neue-700italic - latin */
63+
@font-face {
64+
font-display: swap; /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
65+
font-family: 'Comic Neue';
66+
font-style: italic;
67+
font-weight: 700;
68+
src: url('assets/fonts/ComicNeue/comic-neue-v8-latin-700italic.woff2') format('woff2'), /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
69+
url('assets/fonts/ComicNeue/comic-neue-v8-latin-700italic.ttf') format('truetype'); /* Chrome 4+, Firefox 3.5+, IE 9+, Safari 3.1+, iOS 4.2+, Android Browser 2.2+ */
4370
}
4471

72+
body {
73+
font-family: 'Comic Neue', 'Comic Sans MS', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
74+
'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
75+
sans-serif;
76+
-webkit-font-smoothing: antialiased;
77+
-moz-osx-font-smoothing: grayscale;
78+
}
4579
#root {
4680
height: 100%;
4781
}
@@ -83,3 +117,36 @@ em-emoji-picker {
83117
color: #FFD60A;
84118
}
85119
}
120+
121+
.message {
122+
font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
123+
}
124+
125+
.profileName {
126+
font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
127+
}
128+
129+
.profileNameGithub, a.profileNameGithub:visited {
130+
display: inline;
131+
color:inherit;
132+
align-items: flex-end;
133+
justify-content: flex-end;
134+
font-weight: 500;
135+
font-size:0.9em;
136+
text-decoration: none;
137+
margin-left: 4px;
138+
padding:2px 6px;
139+
border-radius: 3px;
140+
background:rgba(200,200,200,0.25);
141+
color:#fff;
142+
143+
.profileGithubIcon {
144+
height:0.75em;
145+
padding-right:0.35em;
146+
}
147+
}
148+
149+
.MuiDialog-paper {
150+
background:#1f1f1f;
151+
background-image: none !important;
152+
}

0 commit comments

Comments
 (0)