mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-17 03:53:29 +01:00
feat(User): banners and accent colors (#6117)
* feat(User): support banners don't mind it for now, just trying * feat(User): support banners * fix(Constants): declare dynamic * fix(User): eslint * typings: update User typings * fix(User): add banner to equals and json bannerURL * typings: missing dynamic * refactor: xID to xId * types: re-add typings * feat: add banner color and fetch note * feat: switch to accent color (swap hex and dec)) * Update src/structures/User.js Co-authored-by: Rodry <38259440+ImRodry@users.noreply.github.com> * Update typings/index.d.ts Co-authored-by: Rodry <38259440+ImRodry@users.noreply.github.com> * Apply suggestions from code review Co-authored-by: Koyamie <koyamie1@gmail.com> Co-authored-by: Noel <icrawltogo@gmail.com> Co-authored-by: Rodry <38259440+ImRodry@users.noreply.github.com>
This commit is contained in:
12
typings/index.d.ts
vendored
12
typings/index.d.ts
vendored
@@ -1864,7 +1864,9 @@ export class Typing extends Base {
|
||||
|
||||
export class User extends PartialTextBasedChannel(Base) {
|
||||
public constructor(client: Client, data: RawUserData);
|
||||
public accentColor: number | null;
|
||||
public avatar: string | null;
|
||||
public banner: string | null;
|
||||
public bot: boolean;
|
||||
public readonly createdAt: Date;
|
||||
public readonly createdTimestamp: number;
|
||||
@@ -1872,12 +1874,14 @@ export class User extends PartialTextBasedChannel(Base) {
|
||||
public readonly defaultAvatarURL: string;
|
||||
public readonly dmChannel: DMChannel | null;
|
||||
public flags: Readonly<UserFlags> | null;
|
||||
public readonly hexAccentColor: HexColorString | null;
|
||||
public id: Snowflake;
|
||||
public readonly partial: false;
|
||||
public system: boolean;
|
||||
public readonly tag: string;
|
||||
public username: string;
|
||||
public avatarURL(options?: ImageURLOptions): string | null;
|
||||
public bannerURL(options?: ImageURLOptions): string | null;
|
||||
public createDM(): Promise<DMChannel>;
|
||||
public deleteDM(): Promise<DMChannel>;
|
||||
public displayAvatarURL(options?: ImageURLOptions): string;
|
||||
@@ -2199,7 +2203,13 @@ export const Constants: {
|
||||
size: AllowedImageSize,
|
||||
dynamic: boolean,
|
||||
) => string;
|
||||
Banner: (guildId: Snowflake, hash: string, format: AllowedImageFormat, size: AllowedImageSize) => string;
|
||||
Banner: (
|
||||
id: Snowflake,
|
||||
hash: string,
|
||||
format: DynamicImageFormat,
|
||||
size: AllowedImageSize,
|
||||
dynamic: boolean,
|
||||
) => string;
|
||||
Icon: (
|
||||
guildId: Snowflake,
|
||||
hash: string,
|
||||
|
||||
Reference in New Issue
Block a user