diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 30f7518132eced..619d0d35a0d4f3 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -766,7 +766,6 @@ /types/carbon-components-react/ @matchilling /types/carbon__colors/ @vpicone @szbihary /types/carbon__elements/ @metonym -/types/carbon__feature-flags/ @metonym /types/carbon__layout/ @vpicone /types/carbon__motion/ @vpicone /types/carbon__themes/ @vpicone diff --git a/notNeededPackages.json b/notNeededPackages.json index c696bff3602577..4b74f97c1b234c 100644 --- a/notNeededPackages.json +++ b/notNeededPackages.json @@ -668,6 +668,10 @@ "libraryName": "canvaskit-wasm", "asOfVersion": "0.18.1" }, + "carbon__feature-flags": { + "libraryName": "@carbon/feature-flags", + "asOfVersion": "1.1.0" + }, "carbon__icon-helpers": { "libraryName": "@carbon/icon-helpers", "asOfVersion": "10.45.0" @@ -1108,6 +1112,10 @@ "libraryName": "codegen.macro", "asOfVersion": "4.1.0" }, + "color-convert": { + "libraryName": "color-convert", + "asOfVersion": "3.0.1" + }, "colorbrewer": { "libraryName": "colorbrewer", "asOfVersion": "1.6.0" diff --git a/types/carbon__feature-flags/.npmignore b/types/carbon__feature-flags/.npmignore deleted file mode 100644 index 93e307400a5456..00000000000000 --- a/types/carbon__feature-flags/.npmignore +++ /dev/null @@ -1,5 +0,0 @@ -* -!**/*.d.ts -!**/*.d.cts -!**/*.d.mts -!**/*.d.*.ts diff --git a/types/carbon__feature-flags/carbon__feature-flags-tests.ts b/types/carbon__feature-flags/carbon__feature-flags-tests.ts deleted file mode 100644 index 2c4f345d4200c3..00000000000000 --- a/types/carbon__feature-flags/carbon__feature-flags-tests.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { add, createScope, disable, enable, enabled, FeatureFlagScope, merge } from "@carbon/feature-flags"; - -add("feature-flag-a", false); - -enable("feature-flag-a"); - -disable("feature-flag-a"); - -merge({ - "feature-flag-a": true, - "feature-flag-b": false, - "feature-flag-c": true, - "enable-v11-release": true, -}); - -enabled("feature-flag-a"); - -const scope = new FeatureFlagScope({ - "enable-2021-release": true, -}); - -const scopeWithoutFlags = createScope(); -const scopeWithFlags = createScope({ - "custom-flag": true, - "enable-css-custom-properties": true, - "enable-use-controlled-state-with-value": true, -}); - -scopeWithFlags.add("custom", true); -scopeWithFlags.disable("custom"); -scopeWithFlags.mergeWithScope(scope); diff --git a/types/carbon__feature-flags/es/index.d.ts b/types/carbon__feature-flags/es/index.d.ts deleted file mode 100644 index 8a0f16ce83046f..00000000000000 --- a/types/carbon__feature-flags/es/index.d.ts +++ /dev/null @@ -1 +0,0 @@ -export * from "../"; diff --git a/types/carbon__feature-flags/index.d.ts b/types/carbon__feature-flags/index.d.ts deleted file mode 100644 index d3371c3d2ae7d6..00000000000000 --- a/types/carbon__feature-flags/index.d.ts +++ /dev/null @@ -1,26 +0,0 @@ -export type FeatureFlagName = - | "enable-css-custom-properties" - | "enable-use-controlled-state-with-value" - | "enable-css-grid" - | "enable-v11-release"; - -export type FeatureFlags = Partial> | Record; - -export class FeatureFlagScope { - flags: Map; - constructor(flags?: FeatureFlags); - checkForFlag(name: string): void; - add: typeof add; - enable: typeof enable; - disable: typeof disable; - merge: typeof merge; - mergeWithScope(scope: this): void; - enabled: typeof enabled; -} - -export function add(name: string, enabled: boolean): void; -export function createScope(flags?: FeatureFlags): FeatureFlagScope; -export function enable(name: string): void; -export function disable(name: string): void; -export function merge(flags: FeatureFlags): void; -export function enabled(name: string): boolean; diff --git a/types/carbon__feature-flags/package.json b/types/carbon__feature-flags/package.json deleted file mode 100644 index 8f88625038eb09..00000000000000 --- a/types/carbon__feature-flags/package.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "private": true, - "name": "@types/carbon__feature-flags", - "version": "0.8.9999", - "projects": [ - "https://github.com/carbon-design-system/carbon/tree/master/packages/feature-flags" - ], - "devDependencies": { - "@types/carbon__feature-flags": "workspace:." - }, - "owners": [ - { - "name": "Eric Liu", - "githubUsername": "metonym" - } - ] -} diff --git a/types/carbon__feature-flags/tsconfig.json b/types/carbon__feature-flags/tsconfig.json deleted file mode 100644 index d99c85d95e9b2c..00000000000000 --- a/types/carbon__feature-flags/tsconfig.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "compilerOptions": { - "module": "node16", - "lib": [ - "es6" - ], - "noImplicitAny": true, - "noImplicitThis": true, - "strictNullChecks": true, - "types": [], - "noEmit": true, - "forceConsistentCasingInFileNames": true, - "strictFunctionTypes": true - }, - "files": [ - "index.d.ts", - "carbon__feature-flags-tests.ts" - ] -} diff --git a/types/color-convert/.eslintrc.json b/types/color-convert/.eslintrc.json deleted file mode 100644 index 79ee5b5a1a5836..00000000000000 --- a/types/color-convert/.eslintrc.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "rules": { - "@definitelytyped/no-single-element-tuple-type": "off" - } -} diff --git a/types/color-convert/.npmignore b/types/color-convert/.npmignore deleted file mode 100644 index 93e307400a5456..00000000000000 --- a/types/color-convert/.npmignore +++ /dev/null @@ -1,5 +0,0 @@ -* -!**/*.d.ts -!**/*.d.cts -!**/*.d.mts -!**/*.d.*.ts diff --git a/types/color-convert/color-convert-tests.ts b/types/color-convert/color-convert-tests.ts deleted file mode 100644 index 29f8a9a094369f..00000000000000 --- a/types/color-convert/color-convert-tests.ts +++ /dev/null @@ -1,171 +0,0 @@ -import convert = require("color-convert"); - -convert.rgb.hsv([1, 2, 3]); -convert.rgb.hsv(1, 2, 3); -convert.rgb.hsv.raw([1, 2, 3]); -convert.rgb.hsv.raw(1, 2, 3); -convert.rgb.hsv([1, 2, 3]); -convert.rgb.hsv(1, 2, 3); - -convert.rgb.hex(123, 45, 67); -convert.rgb.hex([123, 45, 67]); - -convert.hex.lab("DEADBF"); -convert.hex.lab.raw("DEADBF"); - -convert.rgb.cmyk(167, 255, 4); -convert.rgb.cmyk.raw(167, 255, 4); - -convert.rgb.hsl([140, 200, 100]); -convert.rgb.hsv([140, 200, 100]); -convert.rgb.hwb([140, 200, 100]); -convert.rgb.cmyk([140, 200, 100]); -convert.rgb.keyword([255, 228, 196]); -convert.rgb.xyz([92, 191, 84]); -convert.rgb.lab([92, 191, 84]); -convert.rgb.lch([92, 191, 84]); -convert.rgb.ansi16([92, 191, 84]); -convert.rgb.ansi256([92, 191, 84]); -convert.rgb.hex([92, 191, 84]); -convert.rgb.hcg([140, 200, 100]); -convert.rgb.apple([255, 127, 0]); - -convert.hsl.rgb([96, 48, 59]); -convert.hsl.hsv([96, 48, 59]); -convert.hsl.hwb([96, 48, 59]); -convert.hsl.cmyk([96, 48, 59]); -convert.hsl.keyword([240, 100, 50]); -convert.hsl.ansi16([240, 100, 50]); -convert.hsl.ansi256([240, 100, 50]); -convert.hsl.hex([240, 100, 50]); -convert.hsl.hcg([96, 48, 59]); - -convert.hsv.rgb([96, 50, 78]); -convert.hsv.hsl([96, 50, 78]); -convert.hsv.hsl([0, 0, 0]); -convert.hsv.hwb([96, 50, 78]); -convert.hsv.cmyk([96, 50, 78]); -convert.hsv.keyword([240, 100, 100]); -convert.hsv.ansi16([240, 100, 100]); -convert.hsv.ansi256([240, 100, 100]); -convert.hsv.hex([251, 80, 42]); -convert.hsv.hcg([96, 50, 78]); - -convert.cmyk.rgb([30, 0, 50, 22]); -convert.cmyk.hsl([30, 0, 50, 22]); -convert.cmyk.hsv([30, 0, 50, 22]); -convert.cmyk.hwb([30, 0, 50, 22]); -convert.cmyk.keyword([100, 100, 0, 0]); -convert.cmyk.ansi16([30, 0, 50, 22]); -convert.cmyk.ansi256([30, 0, 50, 22]); -convert.cmyk.hex([30, 0, 50, 22]); - -convert.keyword.rgb("blue"); -convert.keyword.hsl("blue"); -convert.keyword.hsv("blue"); -convert.keyword.hwb("blue"); -convert.keyword.cmyk("blue"); -convert.keyword.lab("blue"); -convert.keyword.xyz("blue"); -convert.keyword.ansi16("purple"); -convert.keyword.ansi256("purple"); -convert.keyword.hex("blue"); - -convert.xyz.rgb([25, 40, 15]); -convert.xyz.rgb([50, 100, 100]); -convert.xyz.lab([25, 40, 15]); -convert.xyz.lch([25, 40, 15]); - -convert.lab.xyz([69, -48, 44]); -convert.lab.rgb([75, 20, -30]); -convert.lab.lch([69, -48, 44]); - -convert.lch.lab([69, 65, 137]); -convert.lch.xyz([69, 65, 137]); -convert.lch.rgb([69, 65, 137]); - -convert.ansi16.rgb(103); -convert.ansi256.rgb(175); - -convert.hex.rgb("ABCDEF"); -convert.hex.rgb("AABBCC"); -convert.hex.rgb("ABC"); - -convert.hcg.rgb([96, 39, 64]); -convert.hcg.hsv([96, 39, 64]); -convert.hcg.hsl([96, 39, 64]); -convert.rgb.hcg.raw([250, 0, 255]); -convert.hsl.rgb.raw([96, 48, 59]); -convert.rgb.hsl.raw([140, 200, 100]); - -convert.hsv.rgb.raw([96, 50, 78]); -convert.rgb.hsv.raw([140, 200, 100]); - -convert.hwb.rgb.raw([96, 39, 22]); -convert.rgb.hwb.raw([140, 200, 100]); - -convert.cmyk.rgb.raw([30, 0, 50, 22]); -convert.rgb.cmyk.raw([140, 200, 100]); - -convert.keyword.rgb.raw("blue"); -convert.rgb.keyword.raw([255, 228, 196]); - -convert.hsv.hsl.raw([96, 50, 78]); -convert.hsv.hsl.raw([302, 32, 55]); -convert.hsv.hsl.raw([267, 19, 89]); -convert.hsv.hsl.raw([267, 91, 95]); -convert.hsv.hsl.raw([267, 91, 12]); -convert.hsv.hsl.raw([180, 50, 0]); - -convert.hsl.hsv.raw([96, 48, 59]); -convert.hsl.hsv.raw([120, 54, 61]); -convert.hsl.hsv.raw([27, 51, 43]); -convert.hsl.hsv.raw([241, 17, 79]); -convert.hsl.hsv.raw([120, 50, 0]); - -convert.xyz.rgb.raw([25, 40, 15]); -convert.rgb.xyz.raw([92, 191, 84]); - -convert.rgb.lab.raw([92, 191, 84]); -convert.hwb.rgb([0, 0, 0]); -convert.hwb.rgb([0, 20, 40]); -convert.hwb.rgb([0, 40, 40]); -convert.hwb.rgb([0, 40, 20]); - -convert.hwb.rgb([120, 0, 0]); -convert.hwb.rgb([120, 20, 40]); -convert.hwb.rgb([120, 40, 40]); -convert.hwb.rgb([120, 40, 20]); - -convert.hwb.rgb([240, 0, 0]); -convert.hwb.rgb([240, 20, 40]); -convert.hwb.rgb([240, 40, 40]); -convert.hwb.rgb([240, 40, 20]); - -const val: [number, number, number] = [0, 0, 0]; - -convert.hsl.hsv(val); -convert.hsl.rgb(val); -convert.hsl.hwb(val); -convert.hsl.cmyk(val); -convert.hsl.hex(val); - -convert.rgb.keyword(255, 255, 0); -convert.rgb.keyword(255, 255, 1); -convert.rgb.keyword(250, 254, 1); -convert.gray.rgb([0]); -convert.gray.rgb([50]); -convert.gray.rgb([100]); -convert.gray.hsl([50]); -convert.gray.hsv([50]); -convert.gray.hwb([50]); -convert.gray.cmyk([50]); -convert.gray.lab([50]); -convert.gray.hex([50]); -convert.gray.hex([100]); -convert.gray.hex([0]); - -convert.rgb.gray([0, 0, 0]); -convert.rgb.gray([128, 128, 128]); -convert.rgb.gray([255, 255, 255]); -convert.rgb.gray([0, 128, 255]); diff --git a/types/color-convert/conversions.d.ts b/types/color-convert/conversions.d.ts deleted file mode 100644 index 9d5b5ffd4585c5..00000000000000 --- a/types/color-convert/conversions.d.ts +++ /dev/null @@ -1,149 +0,0 @@ -import colors = require("color-name"); - -export type RGB = [number, number, number]; -export type HSL = [number, number, number]; -export type HSV = [number, number, number]; -export type HWB = [number, number, number]; -export type CMYK = [number, number, number, number]; -export type XYZ = [number, number, number]; -export type LAB = [number, number, number]; -export type LCH = [number, number, number]; -export type HEX = string; -export type KEYWORD = keyof typeof colors; -export type ANSI16 = number; -export type ANSI256 = number; -export type HCG = [number, number, number]; -export type APPLE = [number, number, number]; -export type GRAY = [number]; - -export namespace rgb { - const channels: 3; - const labels: "rgb"; - function hsl(rgb: RGB): HSL; - function hsl(...rgb: RGB): HSL; - function hsv(rgb: RGB): HSV; - function hsv(...rgb: RGB): HSV; - function hwb(rgb: RGB): HWB; - function hwb(...rgb: RGB): HWB; - function cmyk(rgb: RGB): CMYK; - function cmyk(...rgb: RGB): CMYK; - function keyword(rgb: RGB): KEYWORD; - function keyword(...rgb: RGB): KEYWORD; - function xyz(rgb: RGB): XYZ; - function xyz(...rgb: RGB): XYZ; - function lab(rgb: RGB): LAB; - function lab(...rgb: RGB): LAB; - function ansi16(rgb: RGB): ANSI16; - function ansi16(...rgb: RGB): ANSI16; - function ansi256(rgb: RGB): ANSI256; - function ansi256(...rgb: RGB): ANSI256; - function hex(rgb: RGB): HEX; - function hex(...rgb: RGB): HEX; - function hcg(rgb: RGB): HCG; - function hcg(...rgb: RGB): HCG; - function apple(rgb: RGB): APPLE; - function apple(...rgb: RGB): APPLE; - function gray(rgb: RGB): GRAY; - function gray(...rgb: RGB): GRAY; -} - -export namespace hsl { - const channels: 3; - const labels: "hsl"; - function rgb(hsl: HSL): RGB; - function hsv(hsl: HSL): HSV; - function hcg(hsl: HSL): HCG; -} - -export namespace hsv { - const channels: 3; - const labels: "hsv"; - function rgb(hsv: HSV): RGB; - function hsl(hsv: HSV): HSL; - function ansi16(hsv: HSV): ANSI16; - function hcg(hsv: HSV): HCG; -} - -export namespace hwb { - const channels: 3; - const labels: "hwb"; - function rgb(hwb: HWB): RGB; - function hcg(hwb: HWB): HCG; -} - -export namespace cmyk { - const channels: 4; - const labels: "cmyk"; - function rgb(cmyk: CMYK): RGB; -} - -export namespace xyz { - const channels: 3; - const labels: "xyz"; - function rgb(xyz: XYZ): RGB; - function lab(xyz: XYZ): LAB; -} - -export namespace lab { - const channels: 3; - const labels: "lab"; - function xyz(lab: LAB): XYZ; - function lch(lab: LAB): LCH; -} - -export namespace lch { - const channels: 3; - const labels: "lch"; - function lab(lch: LCH): LAB; -} - -export namespace hex { - const channels: 1; - const labels: ["hex"]; - function rgb(hex: HEX): RGB; -} - -export namespace keyword { - const channels: 1; - const labels: ["keyword"]; - function rgb(keyword: KEYWORD): RGB; -} - -export namespace ansi16 { - const channels: 1; - const labels: ["ansi16"]; - function rgb(ansi16: ANSI16): RGB; -} - -export namespace ansi256 { - const channels: 1; - const labels: ["ansi256"]; - function rgb(ansi256: ANSI256): RGB; -} - -export namespace hcg { - const channels: 3; - const labels: ["h", "c", "g"]; - function rgb(hcg: HCG): RGB; - function hsv(hcg: HCG): HSV; - function hsl(hcg: HCG): HSL; - function hwb(hcg: HCG): HWB; -} - -export namespace apple { - const channels: 3; - const labels: ["r16", "g16", "b16"]; - function rgb(apple: APPLE): RGB; -} - -export namespace gray { - const channels: 1; - const labels: ["gray"]; - function rgb(gray: GRAY): RGB; - function hsl(gray: GRAY): HSL; - function hsv(gray: GRAY): HSV; - function hwb(gray: GRAY): HWB; - function cmyk(gray: GRAY): CMYK; - function lab(gray: GRAY): LAB; - function hex(gray: GRAY): HEX; -} diff --git a/types/color-convert/index.d.ts b/types/color-convert/index.d.ts deleted file mode 100644 index 3972b87b389dcb..00000000000000 --- a/types/color-convert/index.d.ts +++ /dev/null @@ -1,137 +0,0 @@ -import conversions = require("./conversions"); -import route = require("./route"); - -export const rgb: - & typeof conversions.rgb - & route.rgb - & { - [F in keyof route.rgb]: { - raw: route.rgb[F]; - }; - }; - -export const hsl: - & typeof conversions.hsl - & route.hsl - & { - [F in keyof route.hsl]: { - raw: route.hsl[F]; - }; - }; - -export const hsv: - & typeof conversions.hsv - & route.hsv - & { - [F in keyof route.hsv]: { - raw: route.hsv[F]; - }; - }; - -export const hwb: - & typeof conversions.hwb - & route.hwb - & { - [F in keyof route.hwb]: { - raw: route.hwb[F]; - }; - }; - -export const cmyk: - & typeof conversions.cmyk - & route.cmyk - & { - [F in keyof route.cmyk]: { - raw: route.cmyk[F]; - }; - }; - -export const xyz: - & typeof conversions.xyz - & route.xyz - & { - [F in keyof route.xyz]: { - raw: route.xyz[F]; - }; - }; - -export const lab: - & typeof conversions.lab - & route.lab - & { - [F in keyof route.lab]: { - raw: route.lab[F]; - }; - }; - -export const lch: - & typeof conversions.lch - & route.lch - & { - [F in keyof route.lch]: { - raw: route.lch[F]; - }; - }; - -export const hex: - & typeof conversions.hex - & route.hex - & { - [F in keyof route.hex]: { - raw: route.hex[F]; - }; - }; - -export const keyword: - & typeof conversions.keyword - & route.keyword - & { - [F in keyof route.keyword]: { - raw: route.keyword[F]; - }; - }; - -export const ansi16: - & typeof conversions.ansi16 - & route.ansi16 - & { - [F in keyof route.ansi16]: { - raw: route.ansi16[F]; - }; - }; - -export const ansi256: - & typeof conversions.ansi256 - & route.ansi256 - & { - [F in keyof route.ansi256]: { - raw: route.ansi256[F]; - }; - }; - -export const hcg: - & typeof conversions.hcg - & route.hcg - & { - [F in keyof route.hcg]: { - raw: route.hcg[F]; - }; - }; - -export const apple: - & typeof conversions.apple - & route.apple - & { - [F in keyof route.apple]: { - raw: route.apple[F]; - }; - }; - -export const gray: - & typeof conversions.gray - & route.gray - & { - [F in keyof route.gray]: { - raw: route.gray[F]; - }; - }; diff --git a/types/color-convert/package.json b/types/color-convert/package.json deleted file mode 100644 index c6004b3727dd11..00000000000000 --- a/types/color-convert/package.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "private": true, - "name": "@types/color-convert", - "version": "2.0.9999", - "projects": [ - "https://github.com/qix-/color-convert#readme" - ], - "dependencies": { - "@types/color-name": "^1.1.0" - }, - "devDependencies": { - "@types/color-convert": "workspace:." - }, - "owners": [ - { - "name": "Junyoung Clare Jang", - "githubUsername": "Airlun" - }, - { - "name": "Piotr Błażejewicz", - "githubUsername": "peterblazejewicz" - } - ] -} diff --git a/types/color-convert/route.d.ts b/types/color-convert/route.d.ts deleted file mode 100644 index ee2dbe97208cb8..00000000000000 --- a/types/color-convert/route.d.ts +++ /dev/null @@ -1,294 +0,0 @@ -import { - ANSI16, - ANSI256, - APPLE, - CMYK, - GRAY, - HCG, - HEX, - HSL, - HSV, - HWB, - KEYWORD, - LAB, - LCH, - RGB, - XYZ, -} from "./conversions"; - -declare namespace route { - interface rgb { - hsl(from: RGB): HSL; - hsl(...from: RGB): HSL; - hsl(from: RGB): HSL; - hsl(...from: RGB): HSL; - hsv(from: RGB): HSV; - hsv(...from: RGB): HSV; - hwb(from: RGB): HWB; - hwb(...from: RGB): HWB; - cmyk(from: RGB): CMYK; - cmyk(...from: RGB): CMYK; - xyz(from: RGB): XYZ; - xyz(...from: RGB): XYZ; - lab(from: RGB): LAB; - lab(...from: RGB): LAB; - lch(from: RGB): LCH; - lch(...from: RGB): LCH; - hex(from: RGB): HEX; - hex(...from: RGB): HEX; - keyword(from: RGB): KEYWORD; - keyword(...from: RGB): KEYWORD; - ansi16(from: RGB): ANSI16; - ansi16(...from: RGB): ANSI16; - ansi256(from: RGB): ANSI256; - ansi256(...from: RGB): ANSI256; - hcg(from: RGB): HCG; - hcg(...from: RGB): HCG; - apple(from: RGB): APPLE; - apple(...from: RGB): APPLE; - gray(from: RGB): GRAY; - gray(...from: RGB): GRAY; - } - interface hsl { - rgb(from: HSL): RGB; - hsv(from: HSL): HSV; - hwb(from: HSL): HWB; - cmyk(from: HSL): CMYK; - xyz(from: HSL): XYZ; - lab(from: HSL): LAB; - lch(from: HSL): LCH; - hex(from: HSL): HEX; - keyword(from: HSL): KEYWORD; - ansi16(from: HSL): ANSI16; - ansi256(from: HSL): ANSI256; - hcg(from: HSL): HCG; - apple(from: HSL): APPLE; - gray(from: HSL): GRAY; - } - interface hsv { - rgb(from: HSV): RGB; - hsl(from: HSV): HSL; - hwb(from: HSV): HWB; - cmyk(from: HSV): CMYK; - xyz(from: HSV): XYZ; - lab(from: HSV): LAB; - lch(from: HSV): LCH; - hex(from: HSV): HEX; - keyword(from: HSV): KEYWORD; - ansi16(from: HSV): ANSI16; - ansi256(from: HSV): ANSI256; - hcg(from: HSV): HCG; - apple(from: HSV): APPLE; - gray(from: HSV): GRAY; - } - interface hwb { - rgb(from: HWB): RGB; - hsl(from: HWB): HSL; - hsv(from: HWB): HSV; - cmyk(from: HWB): CMYK; - xyz(from: HWB): XYZ; - lab(from: HWB): LAB; - lch(from: HWB): LCH; - hex(from: HWB): HEX; - keyword(from: HWB): KEYWORD; - ansi16(from: HWB): ANSI16; - ansi256(from: HWB): ANSI256; - hcg(from: HWB): HCG; - apple(from: HWB): APPLE; - gray(from: HWB): GRAY; - } - interface cmyk { - rgb(from: CMYK): RGB; - hsl(from: CMYK): HSL; - hsv(from: CMYK): HSV; - hwb(from: CMYK): HWB; - xyz(from: CMYK): XYZ; - lab(from: CMYK): LAB; - lch(from: CMYK): LCH; - hex(from: CMYK): HEX; - keyword(from: CMYK): KEYWORD; - ansi16(from: CMYK): ANSI16; - ansi256(from: CMYK): ANSI256; - hcg(from: CMYK): HCG; - apple(from: CMYK): APPLE; - gray(from: CMYK): GRAY; - } - interface xyz { - rgb(from: XYZ): RGB; - hsl(from: XYZ): HSL; - hsv(from: XYZ): HSV; - hwb(from: XYZ): HWB; - cmyk(from: XYZ): CMYK; - lab(from: XYZ): LAB; - lch(from: XYZ): LCH; - hex(from: XYZ): HEX; - keyword(from: XYZ): KEYWORD; - ansi16(from: XYZ): ANSI16; - ansi256(from: XYZ): ANSI256; - hcg(from: XYZ): HCG; - apple(from: XYZ): APPLE; - gray(from: XYZ): GRAY; - } - interface lab { - rgb(from: LAB): RGB; - hsl(from: LAB): HSL; - hsv(from: LAB): HSV; - hwb(from: LAB): HWB; - cmyk(from: LAB): CMYK; - xyz(from: LAB): XYZ; - lch(from: LAB): LCH; - hex(from: LAB): HEX; - keyword(from: LAB): KEYWORD; - ansi16(from: LAB): ANSI16; - ansi256(from: LAB): ANSI256; - hcg(from: LAB): HCG; - apple(from: LAB): APPLE; - gray(from: LAB): GRAY; - } - interface lch { - rgb(from: LCH): RGB; - hsl(from: LCH): HSL; - hsv(from: LCH): HSV; - hwb(from: LCH): HWB; - cmyk(from: LCH): CMYK; - xyz(from: LCH): XYZ; - lab(from: LCH): LAB; - hex(from: LCH): HEX; - keyword(from: LCH): KEYWORD; - ansi16(from: LCH): ANSI16; - ansi256(from: LCH): ANSI256; - hcg(from: LCH): HCG; - apple(from: LCH): APPLE; - gray(from: LCH): GRAY; - } - interface hex { - rgb(from: HEX): RGB; - hsl(from: HEX): HSL; - hsv(from: HEX): HSV; - hwb(from: HEX): HWB; - cmyk(from: HEX): CMYK; - xyz(from: HEX): XYZ; - lab(from: HEX): LAB; - lch(from: HEX): LCH; - keyword(from: HEX): KEYWORD; - ansi16(from: HEX): ANSI16; - ansi256(from: HEX): ANSI256; - hcg(from: HEX): HCG; - apple(from: HEX): APPLE; - gray(from: HEX): GRAY; - } - interface keyword { - rgb(from: KEYWORD): RGB; - hsl(from: KEYWORD): HSL; - hsv(from: KEYWORD): HSV; - hwb(from: KEYWORD): HWB; - cmyk(from: KEYWORD): CMYK; - xyz(from: KEYWORD): XYZ; - lab(from: KEYWORD): LAB; - lch(from: KEYWORD): LCH; - hex(from: KEYWORD): HEX; - ansi16(from: KEYWORD): ANSI16; - ansi256(from: KEYWORD): ANSI256; - hcg(from: KEYWORD): HCG; - apple(from: KEYWORD): APPLE; - gray(from: KEYWORD): GRAY; - } - interface ansi16 { - rgb(from: ANSI16): RGB; - hsl(from: ANSI16): HSL; - hsv(from: ANSI16): HSV; - hwb(from: ANSI16): HWB; - cmyk(from: ANSI16): CMYK; - xyz(from: ANSI16): XYZ; - lab(from: ANSI16): LAB; - lch(from: ANSI16): LCH; - hex(from: ANSI16): HEX; - keyword(from: ANSI16): KEYWORD; - ansi256(from: ANSI16): ANSI256; - hcg(from: ANSI16): HCG; - apple(from: ANSI16): APPLE; - gray(from: ANSI16): GRAY; - } - interface ansi256 { - rgb(from: ANSI256): RGB; - hsl(from: ANSI256): HSL; - hsv(from: ANSI256): HSV; - hwb(from: ANSI256): HWB; - cmyk(from: ANSI256): CMYK; - xyz(from: ANSI256): XYZ; - lab(from: ANSI256): LAB; - lch(from: ANSI256): LCH; - hex(from: ANSI256): HEX; - keyword(from: ANSI256): KEYWORD; - ansi16(from: ANSI256): ANSI16; - hcg(from: ANSI256): HCG; - apple(from: ANSI256): APPLE; - gray(from: ANSI256): GRAY; - } - interface hcg { - rgb(from: HCG): RGB; - hsl(from: HCG): HSL; - hsv(from: HCG): HSV; - hwb(from: HCG): HWB; - cmyk(from: HCG): CMYK; - xyz(from: HCG): XYZ; - lab(from: HCG): LAB; - lch(from: HCG): LCH; - hex(from: HCG): HEX; - keyword(from: HCG): KEYWORD; - ansi16(from: HCG): ANSI16; - ansi256(from: HCG): ANSI256; - apple(from: HCG): APPLE; - gray(from: HCG): GRAY; - } - interface apple { - rgb(from: APPLE): RGB; - hsl(from: APPLE): HSL; - hsv(from: APPLE): HSV; - hwb(from: APPLE): HWB; - cmyk(from: APPLE): CMYK; - xyz(from: APPLE): XYZ; - lab(from: APPLE): LAB; - lch(from: APPLE): LCH; - hex(from: APPLE): HEX; - keyword(from: APPLE): KEYWORD; - ansi16(from: APPLE): ANSI16; - ansi256(from: APPLE): ANSI256; - hcg(from: APPLE): HCG; - gray(from: APPLE): GRAY; - } - interface gray { - rgb(from: GRAY): RGB; - hsl(from: GRAY): HSL; - hsv(from: GRAY): HSV; - hwb(from: GRAY): HWB; - cmyk(from: GRAY): CMYK; - xyz(from: GRAY): XYZ; - lab(from: GRAY): LAB; - lch(from: GRAY): LCH; - hex(from: GRAY): HEX; - keyword(from: GRAY): KEYWORD; - ansi16(from: GRAY): ANSI16; - ansi256(from: GRAY): ANSI256; - hcg(from: GRAY): HCG; - apple(from: GRAY): APPLE; - } -} - -declare function route(fromModel: "rgb"): route.rgb; -declare function route(fromModel: "hsl"): route.hsl; -declare function route(fromModel: "hsv"): route.hsv; -declare function route(fromModel: "hwb"): route.hwb; -declare function route(fromModel: "cmyk"): route.cmyk; -declare function route(fromModel: "xyz"): route.xyz; -declare function route(fromModel: "lab"): route.lab; -declare function route(fromModel: "lch"): route.lch; -declare function route(fromModel: "hex"): route.hex; -declare function route(fromModel: "keyword"): route.keyword; -declare function route(fromModel: "ansi16"): route.ansi16; -declare function route(fromModel: "ansi256"): route.ansi256; -declare function route(fromModel: "hcg"): route.hcg; -declare function route(fromModel: "apple"): route.apple; -declare function route(fromModel: "gray"): route.gray; - -export = route; diff --git a/types/color-convert/tsconfig.json b/types/color-convert/tsconfig.json deleted file mode 100644 index 49874770197345..00000000000000 --- a/types/color-convert/tsconfig.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "compilerOptions": { - "module": "node16", - "lib": [ - "es6" - ], - "noImplicitAny": true, - "noImplicitThis": true, - "strictNullChecks": true, - "strictFunctionTypes": true, - "types": [], - "noEmit": true, - "forceConsistentCasingInFileNames": true - }, - "files": [ - "index.d.ts", - "color-convert-tests.ts" - ] -} diff --git a/types/color/package.json b/types/color/package.json index 61765e3c1a6b48..0bb54e35eb8647 100644 --- a/types/color/package.json +++ b/types/color/package.json @@ -6,7 +6,7 @@ "https://github.com/qix-/color#readme" ], "dependencies": { - "@types/color-convert": "*" + "@types/color-convert": "2" }, "devDependencies": { "@types/color": "workspace:." diff --git a/types/color/v2/package.json b/types/color/v2/package.json index 81d4074f3d6e1a..fc62921019f703 100644 --- a/types/color/v2/package.json +++ b/types/color/v2/package.json @@ -6,7 +6,7 @@ "https://github.com/qix-/color#readme" ], "dependencies": { - "@types/color-convert": "*" + "@types/color-convert": "1" }, "devDependencies": { "@types/color": "workspace:." diff --git a/types/color/v3/package.json b/types/color/v3/package.json index 4f4d86f260c4d0..93da99145c6620 100644 --- a/types/color/v3/package.json +++ b/types/color/v3/package.json @@ -6,7 +6,7 @@ "https://github.com/qix-/color#readme" ], "dependencies": { - "@types/color-convert": "*" + "@types/color-convert": "1" }, "devDependencies": { "@types/color": "workspace:." diff --git a/types/lesgo/tests/services/JWTService.ts b/types/lesgo/tests/services/JWTService.ts index 83b6484f1fa898..35439583d3ea99 100644 --- a/types/lesgo/tests/services/JWTService.ts +++ b/types/lesgo/tests/services/JWTService.ts @@ -13,6 +13,6 @@ const jwtService = new JWTService("mytoken", { }, }); -jwtService.validate(); // $ExpectType JWTService<{ bar: any; foo: any; }> +jwtService.validate(); // $ExpectType JWTService<{ bar: any; foo: any; }> || JWTService<{ bar: any; foo: any; }> jwtService.jwt(); diff --git a/types/umami/.npmignore b/types/umami/.npmignore deleted file mode 100644 index 93e307400a5456..00000000000000 --- a/types/umami/.npmignore +++ /dev/null @@ -1,5 +0,0 @@ -* -!**/*.d.ts -!**/*.d.cts -!**/*.d.mts -!**/*.d.*.ts diff --git a/types/umami/index.d.ts b/types/umami/index.d.ts deleted file mode 100644 index 138fa3c3ae4afb..00000000000000 --- a/types/umami/index.d.ts +++ /dev/null @@ -1,41 +0,0 @@ -declare var umami: umami.umami; - -/** - * @see {@link https://umami.is/docs/tracker-functions|Umami Docs} - */ -declare namespace umami { - interface umami { - track(): Promise | undefined; - track( - event_name: string, - event_data?: { [key: string]: any }, - ): Promise | undefined; - track(custom_payload: { - website: string; - [key: string]: any; - }): Promise | undefined; - track( - callback: (props: { - hostname: string; - language: string; - referrer: string; - screen: string; - title: string; - url: string; - website: string; - }) => { website: string; [key: string]: any }, - ): Promise | undefined; - - /** Pass in your own ID to identify a user. */ - identify(identity_id: string): Promise; - - /** Save data about the current session. */ - identify( - indentity_id: string, - data: Record, - ): Promise; - - /** To save data without a unique ID, pass in only a JSON object. */ - identify(data: Record): Promise; - } -} diff --git a/types/umami/package.json b/types/umami/package.json deleted file mode 100644 index 4a79d77e098fb9..00000000000000 --- a/types/umami/package.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "private": true, - "name": "@types/umami", - "version": "2.10.9999", - "projects": [ - "https://github.com/umami-software/umami" - ], - "devDependencies": { - "@types/umami": "workspace:." - }, - "owners": [ - { - "name": "Noah Overcash", - "githubUsername": "ncovercash" - } - ] -} diff --git a/types/umami/tsconfig.json b/types/umami/tsconfig.json deleted file mode 100644 index 74392e0288973e..00000000000000 --- a/types/umami/tsconfig.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "compilerOptions": { - "module": "node16", - "lib": [ - "es6" - ], - "noImplicitAny": true, - "noImplicitThis": true, - "strictFunctionTypes": true, - "strictNullChecks": true, - "types": [], - "noEmit": true, - "forceConsistentCasingInFileNames": true - }, - "files": [ - "index.d.ts", - "umami-tests.ts" - ] -} diff --git a/types/umami/umami-tests.ts b/types/umami/umami-tests.ts deleted file mode 100644 index 8bc539526dcaff..00000000000000 --- a/types/umami/umami-tests.ts +++ /dev/null @@ -1,25 +0,0 @@ -umami.track(); - -umami.track({ website: "e676c9b4-11e4-4ef1-a4d7-87001773e9f2", url: "/home", title: "Home page" }); - -umami.track(props => ({ ...props, url: "/home", title: "Home page" })); - -umami.track("signup-button"); - -umami.track("signup-button", { name: "newsletter", id: 123 }); - -umami.track(props => ({ - ...props, - name: "signup-button", - data: { - name: "newsletter", - id: 123, - }, -})); - -// identify -umami.identify("123"); - -umami.identify("123", { name: "test" }); - -umami.identify({ name: "test" });