Module Style.DisplaySource

CSS display property controlling box generation and child layout algorithm.

The display property determines how an element generates boxes and which layout algorithm applies to its children.

Sourcetype t =
  1. | Block
    (*

    Children follow the block layout algorithm.

    *)
  2. | Flex
    (*

    Children follow the flexbox layout algorithm.

    *)
  3. | Grid
    (*

    Children follow the CSS grid layout algorithm.

    *)
  4. | None
    (*

    Node is hidden and generates no boxes.

    *)
Sourceval default : t

default returns Flex.

Sourceval to_string : t -> string

to_string display converts display to its CSS string representation.

Sourceval is_none : t -> bool

is_none display returns true if display is None.

Sourceval equal : t -> t -> bool

equal a b returns true if a and b represent the same display mode.

Sourceval compare : t -> t -> int

compare a b returns a comparison result for use in ordered containers.

The ordering is Block < Flex < Grid < None.

Sourceval pp : Format.formatter -> t -> unit

pp fmt display prints display to the formatter fmt.