# PagePreviewMode.fromJson constructor

PagePreviewMode.fromJson(

1. Map<String, dynamic> json

)

## Implementation

    factory PagePreviewMode.fromJson(Map<String, dynamic> json) =>
        PagePreviewMode(
          accessibilityDescription: json.containsKey("accessibilityDescription")
              ? json["accessibilityDescription"] as String
              : "?accessibilityDescriptionCameraPreviewButton",
          imagePlaceholderColor: json.containsKey("imagePlaceholderColor")
              ? ScanbotColor(json["imagePlaceholderColor"] as String)
              : ScanbotColor("?sbColorOnSurfaceVariant"),
          pageCounter: json.containsKey("pageCounter")
              ? BadgeStyle.fromJson(json["pageCounter"] as Map<String, dynamic>)
              : BadgeStyle(
                  visible: true,
                  background: BackgroundStyle(
                      strokeColor: ScanbotColor("?sbColorSurface"),
                      fillColor: ScanbotColor("?sbColorSurface")),
                  foregroundColor: ScanbotColor("?sbColorPrimary")),
        );