intrepidshape/elm-web3-ui/3.0.0

NOTE: the latest version is 4.0.0

Web3.Ui.ProgressRing

Circular progress ring (SVG) for "X% toward Y" displays -- graduation progress, vesting unlock, vault deposit cap. The circular variant of Web3.Ui.SupplyBar.

Web3.Ui.ProgressRing.view
    { current = curve.curvePls
    , target = graduationThreshold
    , size = 64
    , label = Just "graduation"
    }

current / target is divided in BigInt space and the arc geometry is carried as hundredths of a pixel, so nothing is routed through Float.

CSS classes: web3-progressring, web3-progressring__track, web3-progressring__fill, web3-progressring__label. Stroke width and color come from CSS -- set stroke and stroke-width on the __track and __fill elements; geometry is inline for SVG.

{ current : BigInt
, target : BigInt
, size : Int
, label : Maybe String
}
-> Html msg

Render the ring.