miso
Copyright(C) 2016-2026 David M. Johnson
LicenseBSD3-style (see the file LICENSE)
MaintainerDavid M. Johnson <code@dmj.io>
Stabilityexperimental
Portabilitynon-portable
Safe HaskellNone
LanguageHaskell2010

Miso.Mathml.Element

Description

Overview

Miso.Mathml.Element provides smart constructors for every element in the MathML Core vocabulary. Each constructor produces a View node in the MATHML namespace:

tagName_ :: [Attribute action] -> [View model action] -> View model action

All names are suffixed with _. The module is re-exported by Miso.Mathml.

Quick start

Embed a fraction inside a paragraph using p_ and math_:

import Miso
import Miso.Mathml.Element
import Miso.Mathml.Property (display_)

formula :: View model action
formula =
  p_ []
    [ math_ [ display_ "block" ]
        [ mfrac_ []
            [ mn_ [] [ text "1" ]
            , msqrt_ [] [ mn_ [] [ text "2" ] ]
            ]
        ]
    ]

Element groups

See also

Synopsis

Combinator

nodeMathml :: MisoString -> [Attribute action] -> [View model action] -> View model action Source #

Low-level helper used to construct MATHML node in View. Most View helpers in this module are defined in terms of it.

Elements

math_ :: [Attribute action] -> [View model action] -> View model action Source #

<math>

Since: 1.9.0.0

annotationXml_ :: [Attribute action] -> [View model action] -> View model action Source #

<annotation-xml>

Since: 1.9.0.0

annotation_ :: [Attribute action] -> [View model action] -> View model action Source #

<annotation>

Since: 1.9.0.0

merror_ :: [Attribute action] -> [View model action] -> View model action Source #

<merror>

Since: 1.9.0.0

mfrac_ :: [Attribute action] -> [View model action] -> View model action Source #

<mfrac>

Since: 1.9.0.0

mi_ :: [Attribute action] -> [View model action] -> View model action Source #

<mi>

Since: 1.9.0.0

mmultiscripts_ :: [Attribute action] -> [View model action] -> View model action Source #

<mmultiscripts>

Since: 1.9.0.0

mn_ :: [Attribute action] -> [View model action] -> View model action Source #

<mn>

Since: 1.9.0.0

mo_ :: [Attribute action] -> [View model action] -> View model action Source #

<mo>

Since: 1.9.0.0

mover_ :: [Attribute action] -> [View model action] -> View model action Source #

<mover>

Since: 1.9.0.0

mpadded_ :: [Attribute action] -> [View model action] -> View model action Source #

<mpadded>

Since: 1.9.0.0

mphantom_ :: [Attribute action] -> [View model action] -> View model action Source #

<mphantom>

Since: 1.9.0.0

mprescripts_ :: [Attribute action] -> [View model action] -> View model action Source #

<mprescripts>

Since: 1.9.0.0

mroot_ :: [Attribute action] -> [View model action] -> View model action Source #

<mroot>

Since: 1.9.0.0

mrow_ :: [Attribute action] -> [View model action] -> View model action Source #

<mrow>

Since: 1.9.0.0

ms_ :: [Attribute action] -> [View model action] -> View model action Source #

<ms>

Since: 1.9.0.0

mspace_ :: [Attribute action] -> [View model action] -> View model action Source #

<mspace>

Since: 1.9.0.0

msqrt_ :: [Attribute action] -> [View model action] -> View model action Source #

<msqrt>

Since: 1.9.0.0

mstyle_ :: [Attribute action] -> [View model action] -> View model action Source #

<mstyle>

Since: 1.9.0.0

msub_ :: [Attribute action] -> [View model action] -> View model action Source #

<msub>

Since: 1.9.0.0

msubsup_ :: [Attribute action] -> [View model action] -> View model action Source #

<msubsup>

Since: 1.9.0.0

msup_ :: [Attribute action] -> [View model action] -> View model action Source #

<msup>

Since: 1.9.0.0

mtable_ :: [Attribute action] -> [View model action] -> View model action Source #

<mtable>

Since: 1.9.0.0

mtd_ :: [Attribute action] -> [View model action] -> View model action Source #

<mtd>

Since: 1.9.0.0

mtext_ :: [Attribute action] -> [View model action] -> View model action Source #

<mtext>

Since: 1.9.0.0

mtr_ :: [Attribute action] -> [View model action] -> View model action Source #

<mtr>

Since: 1.9.0.0

munder_ :: [Attribute action] -> [View model action] -> View model action Source #

<munder>

Since: 1.9.0.0

munderover_ :: [Attribute action] -> [View model action] -> View model action Source #

<munderover>

Since: 1.9.0.0

semantics_ :: [Attribute action] -> [View model action] -> View model action Source #

<semantics>

Since: 1.9.0.0

mfenced_ :: [Attribute action] -> [View model action] -> View model action Source #

<semantics>

Since: 1.9.0.0