mirror of
https://github.com/spacebarchat/client.git
synced 2024-11-21 18:02:32 +01:00
e
This commit is contained in:
parent
a63e154431
commit
19fe08b602
@ -3,3 +3,4 @@ dist
|
||||
node_modules
|
||||
.github
|
||||
.vscode
|
||||
src-tauri/target
|
||||
|
@ -1,4 +1,4 @@
|
||||
<!DOCTYPE html>
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<!-- Primary Meta Tags -->
|
||||
|
12986
pnpm-lock.yaml
12986
pnpm-lock.yaml
File diff suppressed because it is too large
Load Diff
@ -1 +1,27 @@
|
||||
{"base":{"identifier":"base","description":"base","local":true,"windows":["main","splashscreen"],"permissions":["path:default","event:default","window:default","app:default","resources:default","menu:default","tray:default","updater:default","notification:default","os:allow-platform","os:allow-arch","os:allow-family","os:allow-locale","os:allow-os-type","os:allow-version","webview:allow-internal-toggle-devtools"],"platforms":["linux","macOS","windows","android","iOS"]}}
|
||||
{
|
||||
"base": {
|
||||
"identifier": "base",
|
||||
"description": "base",
|
||||
"local": true,
|
||||
"windows": ["main", "splashscreen"],
|
||||
"permissions": [
|
||||
"path:default",
|
||||
"event:default",
|
||||
"window:default",
|
||||
"app:default",
|
||||
"resources:default",
|
||||
"menu:default",
|
||||
"tray:default",
|
||||
"updater:default",
|
||||
"notification:default",
|
||||
"os:allow-platform",
|
||||
"os:allow-arch",
|
||||
"os:allow-family",
|
||||
"os:allow-locale",
|
||||
"os:allow-os-type",
|
||||
"os:allow-version",
|
||||
"webview:allow-internal-toggle-devtools"
|
||||
],
|
||||
"platforms": ["linux", "macOS", "windows", "android", "iOS"]
|
||||
}
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
@ -30,7 +30,9 @@ const Wrapper = styled(Container)<{ active?: boolean; hasImage?: boolean }>`
|
||||
border-radius: ${(props) => (props.active ? "30%" : "50%")};
|
||||
background-color: ${(props) =>
|
||||
props.hasImage ? "transparent" : props.active ? "var(--primary)" : "var(--background-secondary)"};
|
||||
transition: border-radius 0.2s ease, background-color 0.2s ease;
|
||||
transition:
|
||||
border-radius 0.2s ease,
|
||||
background-color 0.2s ease;
|
||||
|
||||
&:hover {
|
||||
border-radius: 30%;
|
||||
|
@ -22,7 +22,9 @@ const Container = styled.div`
|
||||
width: 340px;
|
||||
max-height: 600px;
|
||||
overflow: hidden;
|
||||
box-shadow: 0 0 0 1px rgb(0 0 0 / 15%), 0 4px 8px rgb(0 0 0 / 15%);
|
||||
box-shadow:
|
||||
0 0 0 1px rgb(0 0 0 / 15%),
|
||||
0 4px 8px rgb(0 0 0 / 15%);
|
||||
color: var(--text);
|
||||
`;
|
||||
|
||||
|
@ -8,7 +8,10 @@
|
||||
code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
color: #f92aad;
|
||||
text-shadow: 0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3;
|
||||
text-shadow:
|
||||
0 0 2px #100c0f,
|
||||
0 0 5px #dc078e33,
|
||||
0 0 10px #fff3;
|
||||
background: none;
|
||||
font-family: var(--font-family-code);
|
||||
font-size: 1em;
|
||||
@ -74,7 +77,10 @@ pre[class*="language-"] {
|
||||
.token.property,
|
||||
.token.selector {
|
||||
color: #72f1b8;
|
||||
text-shadow: 0 0 2px #100c0f, 0 0 10px #257c5575, 0 0 35px #21272475;
|
||||
text-shadow:
|
||||
0 0 2px #100c0f,
|
||||
0 0 10px #257c5575,
|
||||
0 0 35px #21272475;
|
||||
}
|
||||
|
||||
.token.function-name {
|
||||
@ -85,18 +91,29 @@ pre[class*="language-"] {
|
||||
.token.selector .token.id,
|
||||
.token.function {
|
||||
color: #fdfdfd;
|
||||
text-shadow: 0 0 2px #001716, 0 0 3px #03edf975, 0 0 5px #03edf975, 0 0 8px #03edf975;
|
||||
text-shadow:
|
||||
0 0 2px #001716,
|
||||
0 0 3px #03edf975,
|
||||
0 0 5px #03edf975,
|
||||
0 0 8px #03edf975;
|
||||
}
|
||||
|
||||
.token.class-name {
|
||||
color: #fff5f6;
|
||||
text-shadow: 0 0 2px #000, 0 0 10px #fc1f2c75, 0 0 5px #fc1f2c75, 0 0 25px #fc1f2c75;
|
||||
text-shadow:
|
||||
0 0 2px #000,
|
||||
0 0 10px #fc1f2c75,
|
||||
0 0 5px #fc1f2c75,
|
||||
0 0 25px #fc1f2c75;
|
||||
}
|
||||
|
||||
.token.constant,
|
||||
.token.symbol {
|
||||
color: #f92aad;
|
||||
text-shadow: 0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3;
|
||||
text-shadow:
|
||||
0 0 2px #100c0f,
|
||||
0 0 5px #dc078e33,
|
||||
0 0 10px #fff3;
|
||||
}
|
||||
|
||||
.token.important,
|
||||
@ -105,7 +122,10 @@ pre[class*="language-"] {
|
||||
.token.selector .token.class,
|
||||
.token.builtin {
|
||||
color: #f4eee4;
|
||||
text-shadow: 0 0 2px #393a33, 0 0 8px #f39f0575, 0 0 2px #f39f0575;
|
||||
text-shadow:
|
||||
0 0 2px #393a33,
|
||||
0 0 8px #f39f0575,
|
||||
0 0 2px #f39f0575;
|
||||
}
|
||||
|
||||
.token.string,
|
||||
|
@ -374,11 +374,14 @@ export default class GatewayConnectionStore {
|
||||
}
|
||||
};
|
||||
|
||||
this.initialHeartbeatTimeout = setTimeout(() => {
|
||||
this.initialHeartbeatTimeout = setTimeout(
|
||||
() => {
|
||||
this.initialHeartbeatTimeout = null;
|
||||
this.heartbeater = setInterval(heartbeaterFn, this.heartbeatInterval!);
|
||||
heartbeaterFn();
|
||||
}, Math.floor(Math.random() * this.heartbeatInterval!));
|
||||
},
|
||||
Math.floor(Math.random() * this.heartbeatInterval!),
|
||||
);
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -27,7 +27,10 @@ export default class MessageBase {
|
||||
type: MessageType;
|
||||
author: User;
|
||||
|
||||
constructor(public readonly app: AppStore, data: MessageLikeData) {
|
||||
constructor(
|
||||
public readonly app: AppStore,
|
||||
data: MessageLikeData,
|
||||
) {
|
||||
this.id = data.id;
|
||||
this.content = data.content;
|
||||
this.timestamp = new Date(data.timestamp);
|
||||
|
@ -100,7 +100,8 @@ export class Permissions extends BitField {
|
||||
|
||||
static channelPermission(overwrites: APIOverwrite[], init?: bigint) {
|
||||
// TODO: do not deny any permissions if admin
|
||||
return overwrites.reduce((permission, overwrite) => {
|
||||
return overwrites.reduce(
|
||||
(permission, overwrite) => {
|
||||
// apply disallowed permission
|
||||
// * permission: current calculated permission (e.g. 010)
|
||||
// * deny contains all denied permissions (e.g. 011)
|
||||
@ -109,7 +110,9 @@ export class Permissions extends BitField {
|
||||
// ~ operator inverts deny (e.g. 011 -> 100)
|
||||
// & operator only allows 1 for both ~deny and permission (e.g. 010 & 100 -> 000)
|
||||
// | operators adds both together (e.g. 000 + 100 -> 100)
|
||||
}, init || BigInt(0));
|
||||
},
|
||||
init || BigInt(0),
|
||||
);
|
||||
}
|
||||
|
||||
static rolePermission(roles: Role[]) {
|
||||
|
Loading…
Reference in New Issue
Block a user