GeoLeaf Core API - v3.19.0
    Preparing search index...
    • Validates the label block of a style, in either of its two accepted forms.

      label may be a string — the name of the style, as a legend titles it, which needs no further checking — or a configuration object for the text drawn on the features, whose font size, colour, opacity, buffer and offset are then validated. A key of that object the renderer does not read is ignored here; refusing it is the job of the profile schema. An absent label is not a defect. Anything else (a number, an array) is an error.

      Accumulator contract: findings are pushed into errors and warnings, nothing is returned.

      Parameters

      • styleData: Record<string, unknown>

        The style object to inspect; a missing label returns immediately.

      • errors: ValidationErrorItem[]

        Accumulator for blocking failures. Mutated in place.

      • warnings: ValidationWarningItem[]

        Accumulator for non-blocking remarks. Mutated in place.

      • context: Record<string, unknown>

        Diagnostic data merged into every finding.

      Returns void