Skip to main content

Definition

Assembly: Mintlify.Core.dll Namespace: Mintlify.Core.Converters Inheritance: System.Text.Json.Serialization.JsonConverter<Mintlify.Core.Models.BackgroundImageConfig>

Syntax

Summary

Handles JSON conversion for background image properties that can be either strings or objects.

Remarks

Background image configurations in Mintlify can be specified as:
  • String: Single image URL (e.g., “https://example.com/image.png”)
  • Object: Light/dark mode specific images with “light” and “dark” properties

Constructors

.ctor

Syntax

Methods

CanConvert Override

Determines whether the specified type can be converted by this converter.

Syntax

Parameters

Returns

Type: bool True if the type is BackgroundImageConfig; otherwise, false.

Read Override

Reads and converts the JSON to a BackgroundImageConfig object.

Syntax

Parameters

Returns

Type: Mintlify.Core.Models.BackgroundImageConfig? A BackgroundImageConfig for both simple URLs and theme-specific configurations.

Exceptions

Write Override

Writes the BackgroundImageConfig object to JSON.

Syntax

Parameters