SendTimestamps (#891)

Co-authored-by: Tyler Flowers <contact@ggtylerr.dev>
This commit is contained in:
V 2023-04-15 04:42:18 +02:00 committed by GitHub
parent f75f887861
commit 88ad4f1b05
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 288 additions and 10 deletions

View file

@ -258,6 +258,10 @@ export const Devs = /* #__PURE__*/ Object.freeze({
name: "pylix",
id: 492949202121261067n
},
Tyler: {
name: "\\\\GGTyler\\\\",
id: 143117463788191746n
},
RyanCaoDev: {
name: "RyanCaoDev",
id: 952235800110694471n,

View file

@ -16,9 +16,12 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import { findLazy } from "@webpack";
import { ChannelStore, GuildStore, PrivateChannelsStore, SelectedChannelStore } from "@webpack/common";
import { Guild } from "discord-types/general";
const PreloadedUserSettings = findLazy(m => m.ProtoClass?.typeName.endsWith("PreloadedUserSettings"));
export function getCurrentChannel() {
return ChannelStore.getChannel(SelectedChannelStore.getChannelId());
}
@ -30,3 +33,12 @@ export function getCurrentGuild(): Guild | undefined {
export function openPrivateChannel(userId: string) {
PrivateChannelsStore.openPrivateChannel(userId);
}
export const enum Theme {
Dark = 1,
Light = 2
}
export function getTheme(): Theme {
return PreloadedUserSettings.getCurrentValue()?.appearance?.theme;
}