UNPKG

@logic-pad/core

Version:
30 lines (29 loc) 1.03 kB
import { AnyConfig } from '../config.js'; import GridData from '../grid.js'; import { RuleState } from '../primitives.js'; import { Shape } from '../shapes.js'; import Rule, { SearchVariant } from './rule.js'; export default class BanPatternRule extends Rule { private static readonly EXAMPLE_GRID; private static readonly CONFIGS; private static readonly SEARCH_VARIANTS; readonly pattern: GridData; readonly cache: Shape[]; /** * **Don't make this pattern** * * @param pattern - GridData representing the banned pattern. Only non-gray tiles are considered. */ constructor(pattern: GridData); get id(): string; get explanation(): string; get configs(): readonly AnyConfig[] | null; createExampleGrid(): GridData; get searchVariants(): SearchVariant[]; validateGrid(grid: GridData): RuleState; copyWith({ pattern }: { pattern?: GridData; }): this; withPattern(pattern: GridData): this; } export declare const instance: BanPatternRule;