Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TypeScript] miss some export in index.ts #137

Open
XHanL opened this issue Jan 8, 2024 · 1 comment
Open

[TypeScript] miss some export in index.ts #137

XHanL opened this issue Jan 8, 2024 · 1 comment
Labels
quick (Label used internally)

Comments

@XHanL
Copy link

XHanL commented Jan 8, 2024

Typescript library missing some export.

The scheme SchemeRainbow, SchemeFruitSalad are missing.
The enum Variant is also important when we try to create a DynamicScheme.

Example

import { type Variant, SchemeRainbow, SchemeFruitSalad } from "@material/material-color-utilities";

Example Error

Module '"@material/material-color-utilities"' has no exported member 'Variant'.ts(2305)
Module '"@material/material-color-utilities"' has no exported member 'SchemeRainbow'.ts(2305)
Module '"@material/material-color-utilities"' has no exported member 'SchemeFruitSalad'.ts(2305)

index.ts missing export

export * from "./scheme/variant.js";
export * from "./scheme/scheme_rainbow.js";
export * from "./scheme/scheme_fruit_salad.js";
@pennzht pennzht added the quick (Label used internally) label Feb 1, 2024
@ShelbyJenkins
Copy link

In the meantime:

// Copies from @material/material-color-utilities instead of importing
// `import Variant from '@material/material-color-utilities/scheme/variant';
// Because it's not exported from the package
export enum Variant {
	MONOCHROME,
	NEUTRAL,
	TONAL_SPOT,
	VIBRANT,
	EXPRESSIVE,
	FIDELITY,
	CONTENT,
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
quick (Label used internally)
Projects
None yet
Development

No branches or pull requests

3 participants