dev-classes 1.0.8 → 1.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -51,7 +51,7 @@ export declare class Color {
51
51
  static getAccentColor(baseHsv: number[], baseColor: ColorRgb, elementColor: ColorRgb): ColorRgb;
52
52
  static changeColorAccent(baseHsv: number[], accentHsv: number[], color: ColorRgb, isDarkTheme: boolean): ColorRgb;
53
53
  static changeBrightness(color: ColorRgb, amount: number): ColorRgb;
54
- static hexBrightness(hex: string, amount: number, type?: TypeBrightness_OR): any;
54
+ static hexBrightness(hex: string, amount: number): any;
55
55
  static getHexColorFromTelegramColor(color: number): string;
56
56
  static getRgbColorFromTelegramColor(color: number): ColorRgb;
57
57
  static getColorsFromWallPaper(wallPaper: any): string;
@@ -1,6 +1,6 @@
1
- var B = Object.defineProperty;
2
- var M = (l, t, n) => t in l ? B(l, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : l[t] = n;
3
- var p = (l, t, n) => (M(l, typeof t != "symbol" ? t + "" : t, n), n);
1
+ var M = Object.defineProperty;
2
+ var b = (l, t, n) => t in l ? M(l, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : l[t] = n;
3
+ var p = (l, t, n) => (b(l, typeof t != "symbol" ? t + "" : t, n), n);
4
4
  const o = class o {
5
5
  /**
6
6
  * https://stackoverflow.com/a/54070620/6758968
@@ -159,9 +159,9 @@ const o = class o {
159
159
  static changeBrightness(t, n) {
160
160
  return t.map((e) => o.clamp(Math.round(e * n), 0, 255));
161
161
  }
162
- static hexBrightness(t, n, e = "BT709") {
163
- const r = o.hexToRgb(t), s = o.getRgbByTypeBrightness(e), a = o.changeBrightness(r, n), [i, c, h] = a;
164
- return o.rgbToHex(i * s[0], c * s[1], h * s[2]);
162
+ static hexBrightness(t, n) {
163
+ const e = o.hexToRgb(t), r = o.changeBrightness(e, n), [s, a, i] = r;
164
+ return o.rgbToHex(s, a, i);
165
165
  }
166
166
  static getHexColorFromTelegramColor(t) {
167
167
  const n = (t < 0 ? 16777215 + t : t).toString(16);
package/package.json CHANGED
@@ -7,7 +7,7 @@
7
7
  "url": "git+https://github.com/SinGlEBW/dev-classes.git"
8
8
  },
9
9
  "license": "MIT",
10
- "version": "1.0.8",
10
+ "version": "1.0.9",
11
11
  "type": "module",
12
12
  "module": "./dist/index.js",
13
13
  "main": "./dist/index.js",