视频会议上传文件

This commit is contained in:
gyj
2024-04-08 16:23:29 +08:00
parent c098116879
commit a551f33a6e
1272 changed files with 84366 additions and 63430 deletions
+38 -38
View File
@@ -1,38 +1,38 @@
import { AnyColor } from "../types";
import { Plugin } from "../extend";
interface ReadabilityOptions {
level?: "AA" | "AAA";
size?: "normal" | "large";
}
declare module "../colord" {
interface Colord {
/**
* Returns the relative luminance of a color,
* normalized to 0 for darkest black and 1 for lightest white.
* https://www.w3.org/TR/WCAG20/#relativeluminancedef
* https://developer.mozilla.org/en-US/docs/Web/Accessibility/Understanding_Colors_and_Luminance
*/
luminance(): number;
/**
* Calculates a contrast ratio for a color pair.
* This luminance difference is expressed as a ratio ranging
* from 1 (e.g. white on white) to 21 (e.g., black on a white).
* WCAG requires a ratio of at least 4.5 for normal text and 3 for large text.
* https://www.w3.org/TR/UNDERSTANDING-WCAG20/visual-audio-contrast-contrast.html
* https://webaim.org/articles/contrast/
*/
contrast(color2?: AnyColor | Colord): number;
/**
* Checks that a background and text color pair conforms to WCAG 2.0 requirements.
* https://www.w3.org/TR/UNDERSTANDING-WCAG20/visual-audio-contrast-contrast.html
*/
isReadable(color2?: AnyColor | Colord, options?: ReadabilityOptions): boolean;
}
}
/**
* A plugin adding accessibility and color contrast utilities.
* Follows Web Content Accessibility Guidelines 2.0.
* https://www.w3.org/TR/WCAG20/
*/
declare const a11yPlugin: Plugin;
export default a11yPlugin;
import { AnyColor } from "../types";
import { Plugin } from "../extend";
interface ReadabilityOptions {
level?: "AA" | "AAA";
size?: "normal" | "large";
}
declare module "../colord" {
interface Colord {
/**
* Returns the relative luminance of a color,
* normalized to 0 for darkest black and 1 for lightest white.
* https://www.w3.org/TR/WCAG20/#relativeluminancedef
* https://developer.mozilla.org/en-US/docs/Web/Accessibility/Understanding_Colors_and_Luminance
*/
luminance(): number;
/**
* Calculates a contrast ratio for a color pair.
* This luminance difference is expressed as a ratio ranging
* from 1 (e.g. white on white) to 21 (e.g., black on a white).
* WCAG requires a ratio of at least 4.5 for normal text and 3 for large text.
* https://www.w3.org/TR/UNDERSTANDING-WCAG20/visual-audio-contrast-contrast.html
* https://webaim.org/articles/contrast/
*/
contrast(color2?: AnyColor | Colord): number;
/**
* Checks that a background and text color pair conforms to WCAG 2.0 requirements.
* https://www.w3.org/TR/UNDERSTANDING-WCAG20/visual-audio-contrast-contrast.html
*/
isReadable(color2?: AnyColor | Colord, options?: ReadabilityOptions): boolean;
}
}
/**
* A plugin adding accessibility and color contrast utilities.
* Follows Web Content Accessibility Guidelines 2.0.
* https://www.w3.org/TR/WCAG20/
*/
declare const a11yPlugin: Plugin;
export default a11yPlugin;
+24 -24
View File
@@ -1,24 +1,24 @@
import { CmykaColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Converts a color to CMYK color space and returns an object.
* https://drafts.csswg.org/css-color/#cmyk-colors
* https://lea.verou.me/2009/03/cmyk-colors-in-css-useful-or-useless/
*/
toCmyk(): CmykaColor;
/**
* Converts a color to CMYK color space and returns a string.
* https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/device-cmyk()
*/
toCmykString(): string;
}
}
/**
* A plugin adding support for CMYK color space.
* https://lea.verou.me/2009/03/cmyk-colors-in-css-useful-or-useless/
* https://en.wikipedia.org/wiki/CMYK_color_model
*/
declare const cmykPlugin: Plugin;
export default cmykPlugin;
import { CmykaColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Converts a color to CMYK color space and returns an object.
* https://drafts.csswg.org/css-color/#cmyk-colors
* https://lea.verou.me/2009/03/cmyk-colors-in-css-useful-or-useless/
*/
toCmyk(): CmykaColor;
/**
* Converts a color to CMYK color space and returns a string.
* https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/device-cmyk()
*/
toCmykString(): string;
}
}
/**
* A plugin adding support for CMYK color space.
* https://lea.verou.me/2009/03/cmyk-colors-in-css-useful-or-useless/
* https://en.wikipedia.org/wiki/CMYK_color_model
*/
declare const cmykPlugin: Plugin;
export default cmykPlugin;
+16 -16
View File
@@ -1,16 +1,16 @@
import { Plugin } from "../extend";
export declare type HarmonyType = "analogous" | "complementary" | "double-split-complementary" | "rectangle" | "split-complementary" | "tetradic" | "triadic";
declare module "../colord" {
interface Colord {
/**
* Returns an array of harmony colors as `Colord` instances.
*/
harmonies(type?: HarmonyType): Colord[];
}
}
/**
* A plugin adding functionality to generate harmony colors.
* https://en.wikipedia.org/wiki/Harmony_(color)
*/
declare const harmoniesPlugin: Plugin;
export default harmoniesPlugin;
import { Plugin } from "../extend";
export declare type HarmonyType = "analogous" | "complementary" | "double-split-complementary" | "rectangle" | "split-complementary" | "tetradic" | "triadic";
declare module "../colord" {
interface Colord {
/**
* Returns an array of harmony colors as `Colord` instances.
*/
harmonies(type?: HarmonyType): Colord[];
}
}
/**
* A plugin adding functionality to generate harmony colors.
* https://en.wikipedia.org/wiki/Harmony_(color)
*/
declare const harmoniesPlugin: Plugin;
export default harmoniesPlugin;
+23 -23
View File
@@ -1,23 +1,23 @@
import { HwbaColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Converts a color to HWB (Hue-Whiteness-Blackness) color space and returns an object.
* https://en.wikipedia.org/wiki/HWB_color_model
*/
toHwb(): HwbaColor;
/**
* Converts a color to HWB (Hue-Whiteness-Blackness) color space and returns a string.
* https://www.w3.org/TR/css-color-4/#the-hwb-notation
*/
toHwbString(): string;
}
}
/**
* A plugin adding support for HWB (Hue-Whiteness-Blackness) color model.
* https://en.wikipedia.org/wiki/HWB_color_model
* https://www.w3.org/TR/css-color-4/#the-hwb-notation
*/
declare const hwbPlugin: Plugin;
export default hwbPlugin;
import { HwbaColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Converts a color to HWB (Hue-Whiteness-Blackness) color space and returns an object.
* https://en.wikipedia.org/wiki/HWB_color_model
*/
toHwb(): HwbaColor;
/**
* Converts a color to HWB (Hue-Whiteness-Blackness) color space and returns a string.
* https://www.w3.org/TR/css-color-4/#the-hwb-notation
*/
toHwbString(): string;
}
}
/**
* A plugin adding support for HWB (Hue-Whiteness-Blackness) color model.
* https://en.wikipedia.org/wiki/HWB_color_model
* https://www.w3.org/TR/css-color-4/#the-hwb-notation
*/
declare const hwbPlugin: Plugin;
export default hwbPlugin;
+23 -23
View File
@@ -1,23 +1,23 @@
import { LabaColor, AnyColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Converts a color to CIELAB color space and returns an object.
* The object always includes `alpha` value [0, 1].
*/
toLab(): LabaColor;
/**
* Calculates the perceived color difference for two colors according to
* [Delta E2000](https://en.wikipedia.org/wiki/Color_difference#CIEDE2000).
* Returns a value in [0, 1] range.
*/
delta(color?: AnyColor | Colord): number;
}
}
/**
* A plugin adding support for CIELAB color space.
* https://en.wikipedia.org/wiki/CIELAB_color_space
*/
declare const labPlugin: Plugin;
export default labPlugin;
import { LabaColor, AnyColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Converts a color to CIELAB color space and returns an object.
* The object always includes `alpha` value [0, 1].
*/
toLab(): LabaColor;
/**
* Calculates the perceived color difference for two colors according to
* [Delta E2000](https://en.wikipedia.org/wiki/Color_difference#CIEDE2000).
* Returns a value in [0, 1] range.
*/
delta(color?: AnyColor | Colord): number;
}
}
/**
* A plugin adding support for CIELAB color space.
* https://en.wikipedia.org/wiki/CIELAB_color_space
*/
declare const labPlugin: Plugin;
export default labPlugin;
+24 -24
View File
@@ -1,24 +1,24 @@
import { LchaColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Converts a color to CIELCH (Lightness-Chroma-Hue) color space and returns an object.
* https://lea.verou.me/2020/04/lch-colors-in-css-what-why-and-how/
* https://en.wikipedia.org/wiki/CIELAB_color_space#Cylindrical_model
*/
toLch(): LchaColor;
/**
* Converts a color to CIELCH (Lightness-Chroma-Hue) color space and returns a string.
* https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/lch()
*/
toLchString(): string;
}
}
/**
* A plugin adding support for CIELCH color space.
* https://lea.verou.me/2020/04/lch-colors-in-css-what-why-and-how/
* https://en.wikipedia.org/wiki/CIELAB_color_space#Cylindrical_model
*/
declare const lchPlugin: Plugin;
export default lchPlugin;
import { LchaColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Converts a color to CIELCH (Lightness-Chroma-Hue) color space and returns an object.
* https://lea.verou.me/2020/04/lch-colors-in-css-what-why-and-how/
* https://en.wikipedia.org/wiki/CIELAB_color_space#Cylindrical_model
*/
toLch(): LchaColor;
/**
* Converts a color to CIELCH (Lightness-Chroma-Hue) color space and returns a string.
* https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/lch()
*/
toLchString(): string;
}
}
/**
* A plugin adding support for CIELCH color space.
* https://lea.verou.me/2020/04/lch-colors-in-css-what-why-and-how/
* https://en.wikipedia.org/wiki/CIELAB_color_space#Cylindrical_model
*/
declare const lchPlugin: Plugin;
export default lchPlugin;
+20 -20
View File
@@ -1,20 +1,20 @@
import { Plugin } from "../extend";
interface MinificationOptions {
hex?: boolean;
alphaHex?: boolean;
rgb?: boolean;
hsl?: boolean;
name?: boolean;
transparent?: boolean;
}
declare module "../colord" {
interface Colord {
/** Returns the shortest string representation of the color */
minify(options?: MinificationOptions): string;
}
}
/**
* A plugin adding a color minification utilities.
*/
declare const minifyPlugin: Plugin;
export default minifyPlugin;
import { Plugin } from "../extend";
interface MinificationOptions {
hex?: boolean;
alphaHex?: boolean;
rgb?: boolean;
hsl?: boolean;
name?: boolean;
transparent?: boolean;
}
declare module "../colord" {
interface Colord {
/** Returns the shortest string representation of the color */
minify(options?: MinificationOptions): string;
}
}
/**
* A plugin adding a color minification utilities.
*/
declare const minifyPlugin: Plugin;
export default minifyPlugin;
+27 -27
View File
@@ -1,27 +1,27 @@
import { AnyColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Produces a mixture of two colors through CIE LAB color space and returns a new Colord instance.
*/
mix(color2: AnyColor | Colord, ratio?: number): Colord;
/**
* Generates a tints palette based on original color.
*/
tints(count?: number): Colord[];
/**
* Generates a shades palette based on original color.
*/
shades(count?: number): Colord[];
/**
* Generates a tones palette based on original color.
*/
tones(count?: number): Colord[];
}
}
/**
* A plugin adding a color mixing utilities.
*/
declare const mixPlugin: Plugin;
export default mixPlugin;
import { AnyColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
/**
* Produces a mixture of two colors through CIE LAB color space and returns a new Colord instance.
*/
mix(color2: AnyColor | Colord, ratio?: number): Colord;
/**
* Generates a tints palette based on original color.
*/
tints(count?: number): Colord[];
/**
* Generates a shades palette based on original color.
*/
shades(count?: number): Colord[];
/**
* Generates a tones palette based on original color.
*/
tones(count?: number): Colord[];
}
}
/**
* A plugin adding a color mixing utilities.
*/
declare const mixPlugin: Plugin;
export default mixPlugin;
+19 -19
View File
@@ -1,19 +1,19 @@
import { Plugin } from "../extend";
interface ConvertOptions {
closest?: boolean;
}
declare module "../colord" {
interface Colord {
/** Finds CSS color keyword that matches with the color value */
toName(options?: ConvertOptions): string | undefined;
}
}
/**
* Plugin to work with named colors.
* Adds a parser to read CSS color names and `toName` method.
* See https://www.w3.org/TR/css-color-4/#named-colors
* Supports 'transparent' string as defined in
* https://drafts.csswg.org/css-color/#transparent-color
*/
declare const namesPlugin: Plugin;
export default namesPlugin;
import { Plugin } from "../extend";
interface ConvertOptions {
closest?: boolean;
}
declare module "../colord" {
interface Colord {
/** Finds CSS color keyword that matches with the color value */
toName(options?: ConvertOptions): string | undefined;
}
}
/**
* Plugin to work with named colors.
* Adds a parser to read CSS color names and `toName` method.
* See https://www.w3.org/TR/css-color-4/#named-colors
* Supports 'transparent' string as defined in
* https://drafts.csswg.org/css-color/#transparent-color
*/
declare const namesPlugin: Plugin;
export default namesPlugin;
+14 -14
View File
@@ -1,14 +1,14 @@
import { XyzaColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
toXyz(): XyzaColor;
}
}
/**
* A plugin adding support for CIE XYZ colorspace.
* Wikipedia: https://en.wikipedia.org/wiki/CIE_1931_color_space
* Helpful article: https://www.sttmedia.com/colormodel-xyz
*/
declare const xyzPlugin: Plugin;
export default xyzPlugin;
import { XyzaColor } from "../types";
import { Plugin } from "../extend";
declare module "../colord" {
interface Colord {
toXyz(): XyzaColor;
}
}
/**
* A plugin adding support for CIE XYZ colorspace.
* Wikipedia: https://en.wikipedia.org/wiki/CIE_1931_color_space
* Helpful article: https://www.sttmedia.com/colormodel-xyz
*/
declare const xyzPlugin: Plugin;
export default xyzPlugin;