Table of Contents

Class TwEncodedSymbolTheme

Namespace
TwBlazor.Configuration.Components
Assembly
TwBlazor.dll

The theme settings every scannable symbol shares (TwQrCode and TwBarcode).

[ExcludeFromCodeCoverage]
public abstract class TwEncodedSymbolTheme
Inheritance
TwEncodedSymbolTheme
Derived
Inherited Members

Remarks

The modules and any printed text are drawn in currentColor, so Foreground takes text color classes and Background takes background classes, each with its own dark: variants. Scanners need strong contrast. Dark modules on a light background read everywhere; light modules on a dark background (an inverted symbol) read in most phone camera apps but not in some dedicated scanners.

Constructors

TwEncodedSymbolTheme()

protected TwEncodedSymbolTheme()

Properties

Background

Gets or sets the background classes behind the modules and quiet zone, for example bg-white dark:bg-transparent.

public required string Background { get; set; }

Property Value

string

Base

Gets or sets the structural classes for the symbol's root element. Include forced-color-adjust-none so high contrast modes do not recolor the symbol into something a scanner cannot read.

public required string Base { get; set; }

Property Value

string

Foreground

Gets or sets the text color classes for the dark modules and printed text, for example text-black dark:text-white.

public required string Foreground { get; set; }

Property Value

string