///
/// BrowserPresentationStyle.swift
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
/// https://github.com/mrousavy/nitro
/// Copyright © Marc Rousavy @ Margelo
///

/**
 * Represents the JS union `BrowserPresentationStyle`, backed by a C++ enum.
 */
public typealias BrowserPresentationStyle = margelo.nitro.one.BrowserPresentationStyle

public extension BrowserPresentationStyle {
  /**
   * Get a BrowserPresentationStyle for the given String value, or
   * return `nil` if the given value was invalid/unknown.
   */
  init?(fromString string: String) {
    switch string {
      case "automatic":
        self = .automatic
      case "currentContext":
        self = .currentcontext
      case "formSheet":
        self = .formsheet
      case "fullScreen":
        self = .fullscreen
      case "overCurrentContext":
        self = .overcurrentcontext
      case "overFullScreen":
        self = .overfullscreen
      case "pageSheet":
        self = .pagesheet
      default:
        return nil
    }
  }

  /**
   * Get the String value this BrowserPresentationStyle represents.
   */
  var stringValue: String {
    switch self {
      case .automatic:
        return "automatic"
      case .currentcontext:
        return "currentContext"
      case .formsheet:
        return "formSheet"
      case .fullscreen:
        return "fullScreen"
      case .overcurrentcontext:
        return "overCurrentContext"
      case .overfullscreen:
        return "overFullScreen"
      case .pagesheet:
        return "pageSheet"
    }
  }
}
