Skip to content

Commit

Permalink
2.2.2
Browse files Browse the repository at this point in the history
  • Loading branch information
ppillot committed Jan 9, 2024
1 parent ddea04f commit d242234
Show file tree
Hide file tree
Showing 10 changed files with 23 additions and 24 deletions.
22 changes: 10 additions & 12 deletions dist/declarations/color/colormaker-registry.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,31 @@
* @author Alexander Rose <alexander.rose@weirdbyte.de>
* @private
*/
import Colormaker, { ColormakerParameters } from './colormaker';
import Colormaker, { ColormakerConstructor, ColormakerParameters } from './colormaker';
import { SelectionSchemeData } from './selection-colormaker';
declare type ColormakerDefinitionFunction = ((this: Colormaker, param?: ColormakerParameters) => void);
/**
* Class for registering {@link Colormaker}s. Generally use the
* global {@link src/globals.js~ColormakerRegistry} instance.
*/
declare class ColormakerRegistry {
schemes: {
[k: string]: any;
[k: string]: ColormakerConstructor;
};
userSchemes: {
[k: string]: any;
[k: string]: ColormakerConstructor;
};
constructor();
getScheme(params: Partial<{
scheme: string;
} & ColormakerParameters>): any;
} & ColormakerParameters>): Colormaker;
/**
* Get an description of available schemes as an
* object with id-label as key-value pairs
* @return {Object} available schemes
*/
getSchemes(): {
[k: string]: any;
[k: string]: string;
};
/**
* Get an description of available scales as an
Expand Down Expand Up @@ -89,7 +90,7 @@ declare class ColormakerRegistry {
* @param {Colormaker} scheme - the colormaker
* @return {undefined}
*/
add(id: string, scheme: typeof Colormaker): void;
add(id: string, scheme: ColormakerConstructor): void;
/**
* Register a custom scheme
*
Expand All @@ -116,24 +117,21 @@ declare class ColormakerRegistry {
* @param {String} label - scheme label
* @return {String} id to refer to the registered scheme
*/
addScheme(scheme: any, label?: string): string;
addScheme(scheme: ColormakerConstructor | ColormakerDefinitionFunction, label?: string): string;
/**
* Add a user-defined scheme
* @param {Colormaker} scheme - the user-defined scheme
* @param {String} [label] - scheme label
* @return {String} id to refer to the registered scheme
*/
_addUserScheme(scheme: any, label?: string): string;
_addUserScheme(scheme: ColormakerConstructor, label?: string): string;
/**
* Remove the scheme with the given id
* @param {String} id - scheme to remove
* @return {undefined}
*/
removeScheme(id: string): void;
_createScheme(constructor: any): {
(this: any, params: ColormakerParameters): void;
prototype: Colormaker;
};
_createScheme(constructor: ColormakerDefinitionFunction): ColormakerConstructor;
/**
* Create and a selection-based coloring scheme. Supply a list with pairs
* of colorname and selection for coloring by selections. Use the last
Expand Down
1 change: 1 addition & 0 deletions dist/declarations/color/colormaker.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ export declare type VolumeColormakerParams = {
volume: Volume;
} & Partial<ColormakerParameters>;
export declare type ColormakerScale = (v: number) => number;
export declare type ColormakerConstructor = new (...p: ConstructorParameters<typeof Colormaker>) => Colormaker;
/** Decorator for optionally linearizing a numeric color */
declare type colorFuncType = (value: any, fromTo?: boolean) => number;
export declare function manageColor<T extends {
Expand Down
4 changes: 2 additions & 2 deletions dist/ngl.esm.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/ngl.esm.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/ngl.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/ngl.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/ngl.umd.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/ngl.umd.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ngl",
"version": "2.2.1",
"version": "2.2.2",
"description": "Scalable molecular graphics for the web",
"main": "dist/ngl.umd.js",
"module": "dist/ngl.esm.js",
Expand Down

0 comments on commit d242234

Please sign in to comment.