(.require
 [library
  [lux (.except)
   ["$" documentation]
   [data
    ["[0]" text (.only \n)
     ["%" \\format (.only format)]]]]]
 [\\library
  ["[0]" /]])

(def .public documentation
  (List $.Documentation)
  (list ($.module /._
                  "")

        ($.definition /.value)
        ($.definition /.predicate)

        ($.definition (/.Refined it)
          "A refined version of another type, using a predicate to select valid instances.")

        ($.definition (/.Refiner it)
          "A selection mechanism for refined instances of a type.")

        ($.definition /.refiner
          ""
          [(refiner predicate)])

        ($.definition /.lifted
          (format "Yields a function that can work on refined values."
                  \n "Respects the constraints of the refinement.")
          [(lifted transform)])

        ($.definition /.only
          ""
          [(only refiner values)])

        ($.definition /.partition
          "Separates refined values from the un-refined ones."
          [(partition refiner values)])

        ($.definition /.type
          "The Refined type associated with a Refiner type."
          [(def even
             (refiner even?))

           (def Even
             Type
             (type even))

           (is (Maybe Even)
               (even 123))])
        ))
