import type { CompositionType } from '../composition'; import type { ElementSymbol } from '../element'; import type { Vec3 } from '../math'; import * as math from '../math'; import type { ComponentProps } from 'svelte'; import type LatticeComponent from './Lattice.svelte'; import type { Pbc } from './pbc'; import type StructureSceneComponent from './StructureScene.svelte'; export { default as Arrow } from './Arrow.svelte'; export * from './atom-properties'; export { default as AtomLegend } from './AtomLegend.svelte'; export { default as Bond } from './Bond.svelte'; export * as bonding_strategies from './bonding'; export { default as CanvasTooltip } from './CanvasTooltip.svelte'; export { default as Cylinder } from './Cylinder.svelte'; export { default as Lattice } from './Lattice.svelte'; export * from './pbc'; export * from './polyhedra'; export * from './site'; export { default as Structure } from './Structure.svelte'; export { default as StructureControls } from './StructureControls.svelte'; export { default as StructureExportPane } from './StructureExportPane.svelte'; export { default as StructureInfoPane } from './StructureInfoPane.svelte'; export { default as StructureScene } from './StructureScene.svelte'; export * from './supercell'; export type MeasureMode = `distance` | `angle` | `edit-bonds` | `edit-atoms`; export type BondEditMode = `add` | `delete`; export type Species = { element: ElementSymbol; occu: number; oxidation_state: number; }; export type Site = { species: Species[]; abc: Vec3; xyz: Vec3; label: string; properties: Record; }; export declare const LATTICE_PARAM_KEYS: readonly ["a", "b", "c", "alpha", "beta", "gamma"]; export type LatticeParams = Record<(typeof LATTICE_PARAM_KEYS)[number], number>; export type LatticeType = { matrix: math.Matrix3x3; pbc: Pbc; volume: number; } & LatticeParams; export type Molecule = { sites: Site[]; charge?: number; id?: string; properties?: StructureProperties; }; export type Crystal = Molecule & { lattice: LatticeType; }; export type AnyStructure = Crystal | Molecule; export type BondOrder = 1 | 1.5 | 2 | 3 | `aromatic`; export type StructureBond = { site_idx_1: number; site_idx_2: number; order: BondOrder; cell_shift?: Vec3; }; export type StructureProperties = Record & { bonds?: StructureBond[]; }; export type BondPair = { pos_1: Vec3; pos_2: Vec3; site_idx_1: number; site_idx_2: number; bond_length: number; strength: number; bond_order?: BondOrder; cell_shift?: Vec3; transform_matrix: Float32Array; }; export type { PerceivedBond, PerceptionOptions } from './bond-order-perception'; export { compose_perceived_bonds, perceive_bond_orders, } from './bond-order-perception'; export declare function get_element_counts(structure: AnyStructure): Partial>; export declare function format_chemical_formula(structure: AnyStructure, sort_fn: (symbols: ElementSymbol[]) => ElementSymbol[]): string; export declare function format_formula_by_electronegativity(structure: AnyStructure): string; export declare const atomic_radii: CompositionType; export declare function get_density(structure: Crystal): number; export declare function get_center_of_mass(structure: AnyStructure): Vec3; export declare const VECTOR_KEY_PREFIXES: readonly ["force", "forces", "magmom", "magmoms", "spin", "spins"]; export declare const is_vector_key: (key: string) => boolean; export declare const VECTOR_PALETTE: readonly ["#e74c3c", "#3498db", "#2ecc71", "#f39c12", "#9b59b6", "#1abc9c"]; export declare const default_vector_configs: (keys: string[]) => { [k: string]: { visible: boolean; color: "#e74c3c" | "#3498db" | "#2ecc71" | "#f39c12" | "#9b59b6" | "#1abc9c" | null; scale: null; }; }; export declare function get_all_site_vectors(site: Site): { vec: Vec3; key: string; }[]; export declare function get_structure_vector_keys(structure: AnyStructure): string[]; export interface StructureHandlerData { structure?: AnyStructure; filename?: string; file_size?: number; total_atoms?: number; error_msg?: string; fullscreen?: boolean; camera_position?: Vec3; camera_target?: Vec3; camera_has_moved?: boolean; color_scheme?: string; performance_mode?: `quality` | `speed`; scene_props?: ComponentProps; lattice_props?: ComponentProps; } export interface BondInstance { matrix: Float32Array; color_start: string; color_end: string; } export interface BondGroupWithGradients { thickness: number; instances: BondInstance[]; ambient_light?: number; directional_light?: number; }