Repository: discordjs/discord.js
File: packages/discord.js/src/structures/Role.js (JavaScript)

Code before:
  permissionsIn(channel, checkAdmin = true) {
    const resolvedChannel = this.guild.channels.resolve(channel);
    if (!resolvedChannel) throw new DiscordjsError(ErrorCodes.GuildChannelResolve);
    return resolvedChannel.rolePermissions(this, checkAdmin);
  }

  /**
   * Sets a new name for the role.
   *
   * @param {string} name The new name of the role
   * @param {string} [reason] Reason for changing the role's name
   * @returns {Promise<Role>}
   * @example
   * // Set the name of the role
   * role.setName('new role')
   *   .then(updated => console.log(`Updated role name to ${updated.name}`))
   *   .catch(console.error);
   */
  async setName(name, reason) {
    return this.edit({ name, reason });
  }

  /**
   * Sets new colors for the role.
   *
   * @param {RoleColors} colors The colors of the role
   * @param {string} [reason] Reason for changing the role's colors
   * @returns {Promise<Role>}
   * @example
   * // Set the colors of a role
   * role.setColors({ primaryColor: '#FF0000', secondaryColor: '#00FF00', tertiaryColor: '#0000FF' })
   *   .then(updated => console.log(`Set colors of role to ${updated.colors}`))
   *   .catch(console.error);
   */
  async setColors(colors, reason) {
    return this.edit({ colors, reason });
  }

  /**
   * Sets whether or not the role should be hoisted.
   *
   * @param {boolean} [hoist=true] Whether or not to hoist the role
   * @param {string} [reason] Reason for setting whether or not the role should be hoisted
   * @returns {Promise<Role>}
   * @example
   * // Set the hoist of the role
   * role.setHoist(true)
   *   .then(updated => console.log(`Role hoisted: ${updated.hoist}`))
   *   .catch(console.error);
   */
  async setHoist(hoist = true, reason = undefined) {

Review comment (suggestion):
```suggestion
   * @param {RoleColorsResolvable} colors The colors of the role
```

Code after:

  /**
   * Returns `channel.permissionsFor(role)`. Returns permissions for a role in a guild channel,
   * taking into account permission overwrites.
   *
   * @param {GuildChannel|Snowflake} channel The guild channel to use as context
   * @param {boolean} [checkAdmin=true] Whether having the {@link PermissionFlagsBits.Administrator} permission
   * will return all permissions
   * @returns {Readonly<PermissionsBitField>}
   */
  permissionsIn(channel, checkAdmin = true) {
    const resolvedChannel = this.guild.channels.resolve(channel);
    if (!resolvedChannel) throw new DiscordjsError(ErrorCodes.GuildChannelResolve);
    return resolvedChannel.rolePermissions(this, checkAdmin);
  }

  /**
   * Sets a new name for the role.
   *
   * @param {string} name The new name of the role
   * @param {string} [reason] Reason for changing the role's name
   * @returns {Promise<Role>}
   * @example
   * // Set the name of the role
   * role.setName('new role')
   *   .then(updated => console.log(`Updated role name to ${updated.name}`))
   *   .catch(console.error);
   */
  async setName(name, reason) {
    return this.edit({ name, reason });
  }

  /**
   * Sets new colors for the role.
   *
   * @param {RoleColorsResolvable} colors The colors of the role
   * @param {string} [reason] Reason for changing the role's colors
   * @returns {Promise<Role>}
   * @example
   * // Set the colors of a role
   * role.setColors({ primaryColor: '#FF0000', secondaryColor: '#00FF00', tertiaryColor: '#0000FF' })
   *   .then(updated => console.log(`Set colors of role to ${updated.colors}`))
   *   .catch(console.error);
   * @example
   * // Set holographic colors using constants
   * role.setColors({
   *   primaryColor: Constants.HolographicStyle.Primary,
   *   secondaryColor: Constants.HolographicStyle.Secondary,
   *   tertiaryColor: Constants.HolographicStyle.Tertiary,
   * })
   *   .then(updated => console.log(`Set holographic colors for role ${updated.name}`))