This commit is contained in:
Yuzu 2022-07-13 13:16:56 -05:00
parent 723548e5f2
commit dec7f63b43
8 changed files with 727 additions and 709 deletions

View File

@ -1,6 +1,7 @@
# biscuit
## A brand new bleeding edge non bloated Discord library
<img align="middle" src="https://raw.githubusercontent.com/oasisjs/biscuit/main/assets/biscuit.svg" alt="biscuit" />
ETA: **biscuit will be on the npm registry the next week!**
@ -79,7 +80,8 @@ session.start();
- We got the library running on WSL (Ubuntu) without any trouble
### Known issues:
* some properties may be not implemented yet
* some structures are not implemented (see https://github.com/oasisjs/biscuit/issues)
* cache (wip)
* no optimal way to create embeds, should be fixed in builders tho
- some properties may be not implemented yet
- some structures are not implemented (see https://github.com/oasisjs/biscuit/issues)
- cache (wip)
- no optimal way to create embeds, should be fixed in builders tho

View File

@ -4,14 +4,13 @@
"entry": "./mod.ts",
"description": "A brand new bleeding edge non bloated Discord library",
"homepage": "https://github.com/oasisjs/biscuit",
"version": "0.0.1",
"version": "0.1.0",
"releaseType": "minor",
"unstable": false,
"unlisted": false,
"files": [
"./packages/**/*",
"./mod.ts",
"./deps.ts",
"LICENSE",
"README.md"
],

View File

@ -1,6 +1,6 @@
/**
* Deno example
*/
*/
import "https://deno.land/std@0.146.0/dotenv/load.ts";
// TODO: remove and include the library appropriately

View File

@ -14,7 +14,7 @@ import type {
import { TargetTypes } from "../../discordeno/mod.ts";
import { GuildChannel } from "./channels.ts";
import { Member } from "./Member.ts";
import { InviteGuild, Guild } from "./guilds.ts";
import { Guild, InviteGuild } from "./guilds.ts";
import User from "./User.ts";
import Application from "./Application.ts";

View File

@ -137,9 +137,9 @@ export class Message implements Model {
return {
id: si.id,
name: si.name,
formatType: si.format_type
}
})
formatType: si.format_type,
};
});
}
}

View File

@ -7,7 +7,7 @@ import * as Routes from "../Routes.ts";
/**
* A member that comes from a thread
* @link https://discord.com/developers/docs/resources/channel#thread-member-object
* * */
* **/
export class ThreadMember implements Model {
constructor(session: Session, data: DiscordThreadMember) {
this.session = session;

View File

@ -1,6 +1,22 @@
import type { Model } from "./Base.ts";
import type { Session } from "../Session.ts";
import type { ChannelTypes, DefaultMessageNotificationLevels, DiscordEmoji, DiscordGuild, DiscordInviteMetadata, DiscordListActiveThreads, DiscordMemberWithUser, DiscordOverwrite, DiscordRole, ExplicitContentFilterLevels, GuildNsfwLevel, MakeRequired, SystemChannelFlags, VerificationLevels, VideoQualityModes } from "../../discordeno/mod.ts";
import type {
ChannelTypes,
DefaultMessageNotificationLevels,
DiscordEmoji,
DiscordGuild,
DiscordInviteMetadata,
DiscordListActiveThreads,
DiscordMemberWithUser,
DiscordOverwrite,
DiscordRole,
ExplicitContentFilterLevels,
GuildNsfwLevel,
MakeRequired,
SystemChannelFlags,
VerificationLevels,
VideoQualityModes,
} from "../../discordeno/mod.ts";
import type { ImageFormat, ImageSize } from "../Util.ts";
import { GuildFeatures } from "../../discordeno/mod.ts";
import { Snowflake } from "../Snowflake.ts";
@ -675,7 +691,8 @@ export class Guild extends BaseGuild implements Model {
splash: "splashURL" in options
? options.splashURL || urlToBase64(options.splashURL!)
: options.splashHash || Util.iconBigintToHash(options.iconHash!),
banner: "bannerURL" in options ? options.bannerURL || urlToBase64(options.bannerURL!)
banner: "bannerURL" in options
? options.bannerURL || urlToBase64(options.bannerURL!)
: options.bannerHash || Util.iconBigintToHash(options.bannerHash!),
discovery_splash: "discoverySplashURL" in options
? options.discoverySplashURL || urlToBase64(options.discoverySplashURL!)
@ -693,4 +710,4 @@ export class Guild extends BaseGuild implements Model {
}
}
export default Guild
export default Guild;