[{"name":"Web3.Ui.Address","comment":" Address display and input components.\n\n    -- Display with optional explorer link:\n    Web3.Ui.Address.view []\n        { explorerUrl = Just \"https://etherscan.io/address/\" }\n        addr\n\n    -- Truncated address string (pure, no Html):\n    Web3.Ui.Address.short addr  --> \"0x1234…abcd\"\n\n    -- Truncated with custom lengths (e.g. token detail page):\n    Web3.Ui.Address.shortWith { prefixChars = 8, suffixChars = 6 } addr\n    --> \"0x123456…789abc\"\n\n    -- Address text input:\n    Web3.Ui.Address.input []\n        { value = model.addressInput\n        , onInput = AddressInputChanged\n        , valid = True\n        }\n\n@docs view, short, shortWith, input\n\n","unions":[],"aliases":[],"values":[{"name":"input","comment":" A text input for address entry. Adds `web3-input-address--invalid` class\nwhen `valid` is `False`.\n\nThe host app is responsible for validating with `T.address`.\n\nCSS class: `web3-input-address` (plus `web3-input-address--invalid` when invalid)\n\n","type":"List.List (Html.Attribute msg) -> { value : String.String, onInput : String.String -> msg, valid : Basics.Bool } -> Html.Html msg"},{"name":"short","comment":" Truncate an address to \"0x\" + first 4 hex chars + \"…\" + last 4 hex chars.\n\n    short addr  --> \"0x1234…abcd\"\n\n","type":"Web3.Types.Address -> String.String"},{"name":"shortWith","comment":" Truncate an address with configurable prefix and suffix lengths.\n\n`prefixChars` is the total number of leading characters including `\"0x\"`.\n`suffixChars` is the number of trailing hex characters.\n\n    shortWith { prefixChars = 6, suffixChars = 4 } addr\n    --> \"0x1234…abcd\"   (same as short)\n\n    shortWith { prefixChars = 8, suffixChars = 6 } addr\n    --> \"0x123456…789abc\"\n\n","type":"{ prefixChars : Basics.Int, suffixChars : Basics.Int } -> Web3.Types.Address -> String.String"},{"name":"view","comment":" Display an address as \"0x1234…abcd\". Optionally wraps in an `<a>` tag\nwhen `explorerUrl` is `Just url`.\n\nCSS class: `web3-address`\n\n","type":"List.List (Html.Attribute msg) -> { explorerUrl : Maybe.Maybe String.String } -> Web3.Types.Address -> Html.Html msg"}],"binops":[]},{"name":"Web3.Ui.Amount","comment":" Token amount input and display with SI suffix formatting.\n\n    -- Amount input with inline symbol label:\n    Web3.Ui.Amount.amountInput []\n        { value = model.amountStr\n        , onInput = AmountChanged\n        , decimals = 18\n        , symbol = \"PLS\"\n        , valid = True\n        }\n\n    -- Format a Wei value as human-readable (caller appends symbol):\n    Web3.Ui.Amount.formatWei 18 weiAmount ++ \" PLS\"\n    --> \"1.23M PLS\"\n\n@docs amountInput, formatWei\n\n","unions":[],"aliases":[],"values":[{"name":"amountInput","comment":" Numeric text input for a token amount. `value` is a plain decimal string\n(e.g. `\"1000.5\"`). No parsing is done here — call `Web3.Units.parseUnits` in\nyour `update` to convert to Wei.\n\nAdds `web3-amount-input--invalid` when `valid` is `False`.\n\nCSS classes: `web3-amount-wrapper` (outer div), `web3-amount-input` (input),\n`web3-amount-symbol` (symbol label)\n\n","type":"List.List (Html.Attribute msg) -> { value : String.String, onInput : String.String -> msg, decimals : Basics.Int, symbol : String.String, valid : Basics.Bool } -> Html.Html msg"},{"name":"formatWei","comment":" Format a Wei BigInt as a human-readable string with SI suffix.\n\nThe symbol is not appended — concatenate it yourself so the caller controls\nspacing and placement.\n\n    formatWei 18 onePls   --> \"1\"\n    formatWei 18 largePls --> \"1.23M\"\n    formatWei 6  oneUsdc  --> \"1\"\n\nSI suffixes: K (10³), M (10⁶), B (10⁹), T (10¹²).\nValues below 1000 are shown with up to 2 decimal places, trailing zeros trimmed.\n\n","type":"Basics.Int -> Web3.BigInt.BigInt -> String.String"}],"binops":[]},{"name":"Web3.Ui.Balance","comment":" Balance display components.\n\nUses `Web3.Units.formatUnits` / `Web3.Units.formatEther` internally.\n\n    -- ERC-20 token with 6 decimals:\n    Web3.Ui.Balance.view []\n        { decimals = 6, symbol = \"USDC\" }\n        amount\n\n    -- Native ETH/PLS balance:\n    Web3.Ui.Balance.viewEther []\n        { symbol = \"ETH\" }\n        weiAmount\n\n    -- Balance that may not have loaded yet:\n    Web3.Ui.Balance.viewMaybe []\n        { decimals = 6, symbol = \"USDC\", loading = \"…\" }\n        model.balance\n\n    -- Ether balance that may not have loaded yet:\n    Web3.Ui.Balance.viewEtherMaybe []\n        { symbol = \"ETH\", loading = \"…\" }\n        model.ethBalance\n\n@docs view, viewEther, viewMaybe, viewEtherMaybe\n\n","unions":[],"aliases":[],"values":[{"name":"view","comment":" Display a token balance formatted with the given decimal count and symbol.\n\n    view [] { decimals = 6, symbol = \"USDC\" } amount\n    --> <span class=\"web3-balance\">1.5 USDC</span>\n\nCSS class: `web3-balance`\n\n","type":"List.List (Html.Attribute msg) -> { decimals : Basics.Int, symbol : String.String } -> Web3.BigInt.BigInt -> Html.Html msg"},{"name":"viewEther","comment":" Display a Wei amount as ether (18 decimals) with the given symbol.\n\n    viewEther [] { symbol = \"ETH\" } weiAmount\n    --> <span class=\"web3-balance\">1.5 ETH</span>\n\nCSS class: `web3-balance`\n\n","type":"List.List (Html.Attribute msg) -> { symbol : String.String } -> Web3.BigInt.BigInt -> Html.Html msg"},{"name":"viewEtherMaybe","comment":" Display a Wei balance that may not have loaded yet (18 decimals).\n\nDelegates to `viewMaybe` with `decimals = 18`.\n\nCSS classes: `web3-balance`, `web3-balance--loading` (loading state only)\n\n","type":"List.List (Html.Attribute msg) -> { symbol : String.String, loading : String.String } -> Maybe.Maybe Web3.BigInt.BigInt -> Html.Html msg"},{"name":"viewMaybe","comment":" Display a token balance that may not have loaded yet.\n\nShows `opts.loading` with class `web3-balance--loading` while `Nothing`.\nRenders the same as `view` once the balance arrives.\n\nCSS classes: `web3-balance`, `web3-balance--loading` (loading state only)\n\n","type":"List.List (Html.Attribute msg) -> { decimals : Basics.Int, symbol : String.String, loading : String.String } -> Maybe.Maybe Web3.BigInt.BigInt -> Html.Html msg"}],"binops":[]},{"name":"Web3.Ui.ChainGate","comment":" Render content only when the wallet is on the expected chain.\n\nA common pattern in every dapp: show the actual UI when connected to the right\nnetwork, show a prompt to switch otherwise. This wraps that pattern so it does\nnot have to be repeated in every view.\n\n    Web3.Ui.ChainGate.chainGate model.wallet\n        (Chain.chainId Chain.pulsechain)\n        (Html.text \"Please switch to PulseChain\")\n        actualContent\n\n@docs chainGate\n\n","unions":[],"aliases":[],"values":[{"name":"chainGate","comment":" Render `contentView` when the wallet is `Connected` on `expectedChain`.\nRender `wrongChainView` for every other state (disconnected, wrong chain,\nread-only, connecting, error).\n\n","type":"Web3.Wallet.State -> Web3.Types.ChainId -> Html.Html msg -> Html.Html msg -> Html.Html msg"}],"binops":[]},{"name":"Web3.Ui.GasEstimate","comment":" Gas cost estimate display.\n\nPair with `Web3.Contract.Send.estimateGas` and `Web3.Fee.getGasPrice` to show\nthe expected cost of a transaction before the user confirms.\n\n    Web3.Ui.GasEstimate.view []\n        { gasUnits = model.gasEstimate\n        , gasPrice = model.gasPrice\n        , decimals = 18\n        , symbol = \"PLS\"\n        }\n\n@docs view\n\n","unions":[],"aliases":[],"values":[{"name":"view","comment":" Display an estimated transaction cost in the native token.\n\n`gasUnits` — gas limit returned by `estimateGas` (decoded from port)\n`gasPrice` — current gas price in wei, from `Web3.Fee.getGasPrice`\n\nShows `\"Estimating…\"` while either value is `Nothing`.\n\nCost = gasUnits × gasPrice (in wei), displayed via `formatUnits`.\n\nCSS class: `web3-gas-estimate`\n\n","type":"List.List (Html.Attribute msg) -> { gasUnits : Maybe.Maybe Web3.BigInt.BigInt, gasPrice : Maybe.Maybe Web3.BigInt.BigInt, decimals : Basics.Int, symbol : String.String } -> Html.Html msg"}],"binops":[]},{"name":"Web3.Ui.Input","comment":" Typed input primitives for EVM data entry.\n\nThin wrappers around `Html.input` with semantic class names and appropriate\n`type` / `inputmode` attributes. No validation — the host app calls\n`T.address`, `BigInt.fromString`, etc. on the string value.\n\nThe `address`, `bigInt`, and `bytes` inputs accept a `valid : Bool` field.\nPass `False` to add the `--invalid` modifier class (e.g. after a failed parse).\n\n    Web3.Ui.Input.address []\n        { value = model.toAddress, onInput = ToAddressChanged, valid = True }\n\n    Web3.Ui.Input.bigInt []\n        { value = model.amount, onInput = AmountChanged, valid = True }\n\n    Web3.Ui.Input.bool []\n        { value = model.approve, onToggle = ApproveToggled }\n\n@docs address, bigInt, bool, text, bytes\n\n","unions":[],"aliases":[],"values":[{"name":"address","comment":" Text input for Ethereum address entry (`0x…`).\n\nAdds `web3-input-address--invalid` when `valid` is `False`.\n\nCSS class: `web3-input-address`\n\n","type":"List.List (Html.Attribute msg) -> { value : String.String, onInput : String.String -> msg, valid : Basics.Bool } -> Html.Html msg"},{"name":"bigInt","comment":" Text input for a BigInt / uint256 value.\n\nUses `inputmode=\"numeric\"` to show the numeric keyboard on mobile.\nAdds `web3-input-bigint--invalid` when `valid` is `False`.\n\nCSS class: `web3-input-bigint`\n\n","type":"List.List (Html.Attribute msg) -> { value : String.String, onInput : String.String -> msg, valid : Basics.Bool } -> Html.Html msg"},{"name":"bool","comment":" Checkbox input for a boolean value.\n\nCSS class: `web3-input-bool`\n\n","type":"List.List (Html.Attribute msg) -> { value : Basics.Bool, onToggle : Basics.Bool -> msg } -> Html.Html msg"},{"name":"bytes","comment":" Text input for hex bytes (`0x…`).\n\nAdds `web3-input-bytes--invalid` when `valid` is `False`.\n\nCSS class: `web3-input-bytes`\n\n","type":"List.List (Html.Attribute msg) -> { value : String.String, onInput : String.String -> msg, valid : Basics.Bool } -> Html.Html msg"},{"name":"text","comment":" Plain text input.\n\nCSS class: `web3-input-text`\n\n","type":"List.List (Html.Attribute msg) -> { value : String.String, onInput : String.String -> msg } -> Html.Html msg"}],"binops":[]},{"name":"Web3.Ui.PendingOverlay","comment":" Overlay shown while waiting for wallet signature.\n\nEvery dapp needs a \"check your wallet\" prompt when a transaction is\n`AwaitingSignature`. This module provides a consistent overlay so each\nproject does not hand-roll the same spinner and copy.\n\n    -- Always rendered (you control visibility via CSS or parent logic):\n    Web3.Ui.PendingOverlay.view []\n        { message = \"Check your wallet\" }\n\n    -- Only renders during AwaitingSignature, empty otherwise:\n    Web3.Ui.PendingOverlay.conditionalView []\n        { message = \"Check your wallet\" }\n        model.tx\n\n@docs view, conditionalView\n\n","unions":[],"aliases":[],"values":[{"name":"conditionalView","comment":" Render the overlay only when `status` is `Tx.AwaitingSignature`.\n\nReturns `Html.text \"\"` for all other states — safe to always include in your\nview tree.\n\n","type":"List.List (Html.Attribute msg) -> { message : String.String } -> Web3.Transaction.Status -> Html.Html msg"},{"name":"view","comment":" Render the overlay unconditionally.\n\nCSS classes: `web3-pending-overlay` (root), `web3-pending-overlay-inner`,\n`web3-pending-spinner`, `web3-pending-message`\n\n","type":"List.List (Html.Attribute msg) -> { message : String.String } -> Html.Html msg"}],"binops":[]},{"name":"Web3.Ui.PriceDisplay","comment":" Token price display with automatic notation selection.\n\nBonding curve prices span many orders of magnitude. This module picks the most\nreadable notation automatically so each project does not reimplement the same\nrange-checking logic.\n\n    Web3.Ui.PriceDisplay.view []\n        { decimals = 18, symbol = \"PLS\" }\n        priceWei\n\n    Web3.Ui.PriceDisplay.format 18 priceWei\n    --> \"0.00042\"   (fixed for normal range)\n    --> \"1.23M\"     (SI suffix for large)\n    --> \"4.56e-10\"  (scientific for tiny)\n\n@docs view, format\n\n","unions":[],"aliases":[],"values":[{"name":"format","comment":" Format a price BigInt as a human-readable string. No symbol appended.\n\nSee `view` for notation selection rules.\n\n","type":"Basics.Int -> Web3.BigInt.BigInt -> String.String"},{"name":"view","comment":" Display a token price, automatically selecting notation.\n\nNotation rules:\n\n- ≥ 1 000: SI suffix (`1.23M`, `45.6K`)\n- 0.001 – 999.99: fixed decimal (`1.23`, `0.456`, `0.00123`)\n- < 0.001: scientific (`4.56e-10`)\n\nCSS class: `web3-price`\n\n","type":"List.List (Html.Attribute msg) -> { decimals : Basics.Int, symbol : String.String } -> Web3.BigInt.BigInt -> Html.Html msg"}],"binops":[]},{"name":"Web3.Ui.Sign","comment":" Signing lifecycle UI components.\n\nPattern-match on `Sign.SignState` to render sign request status without missing\nany state.\n\n    -- Display current sign state:\n    Web3.Ui.Sign.stateView [] model.signState\n\n    -- Sign button disabled while pending:\n    Web3.Ui.Sign.signButton []\n        { label = \"Sign Permit\", onSign = RequestSign }\n        model.signState\n\n    -- Display the signature once signed:\n    Web3.Ui.Sign.signatureView [] model.signState\n\n@docs stateView, signButton, signatureView\n\n","unions":[],"aliases":[],"values":[{"name":"signButton","comment":" A sign button that is active in `SignIdle` and terminal states, and disabled\nwhile `SignPending`.\n\nCSS class: `web3-sign-btn`\n\n","type":"List.List (Html.Attribute msg) -> { label : String.String, onSign : msg } -> Web3.Sign.SignState -> Html.Html msg"},{"name":"signatureView","comment":" Displays the signature value when in the `Signed` state.\n\nReturns an empty text node for all other states — safe to always render.\n\nCSS classes: `web3-signature` (wrapper div), `web3-signature-value` (code element)\n\n","type":"List.List (Html.Attribute msg) -> Web3.Sign.SignState -> Html.Html msg"},{"name":"stateView","comment":" Displays the sign lifecycle state as a labelled span.\n\nLabels: \"Idle\" / \"Waiting for signature…\" / \"Signed\" / \"Failed: <err>\" / \"Rejected\"\n\nCSS class: `web3-sign-state`\n\n","type":"List.List (Html.Attribute msg) -> Web3.Sign.SignState -> Html.Html msg"}],"binops":[]},{"name":"Web3.Ui.Transaction","comment":" Transaction lifecycle UI components.\n\nPattern-match on `Tx.Status` to render appropriate UI without missing any state.\n\n    -- Status badge with modifier class:\n    Web3.Ui.Transaction.statusBadge [] tx.status\n\n    -- Action button disabled while in-flight:\n    Web3.Ui.Transaction.actionButton []\n        { label = \"Buy\", pendingLabel = \"Buying…\", onPress = SubmitBuy }\n        tx.status\n\n    -- Clickable tx hash link:\n    Web3.Ui.Transaction.txHashLink []\n        { explorerUrl = \"https://etherscan.io/tx/\" }\n        hash\n\n    -- Hash link extracted from status (Nothing when no hash available):\n    -- Pass Nothing for explorerUrl in local dev — renders a plain span instead of a dead link.\n    Web3.Ui.Transaction.statusHashLink []\n        { explorerUrl = Just \"https://etherscan.io/tx/\" }\n        tx.status\n\n    -- Confirmed receipt display:\n    Web3.Ui.Transaction.receiptView []\n        { explorerUrl = \"https://etherscan.io/tx/\" }\n        receipt\n\n@docs statusBadge, actionButton, txHashLink, statusHashLink, receiptView\n\n","unions":[],"aliases":[],"values":[{"name":"actionButton","comment":" An action button that is active in `Idle` and terminal states, and disabled\nwhile in-flight (`AwaitingSignature`, `Submitted`, `Confirming`).\n\nShows `pendingLabel` while the transaction is in-flight.\n\nCSS classes: `web3-action-btn`, `web3-action-btn--pending` (added when disabled)\n\n","type":"List.List (Html.Attribute msg) -> { label : String.String, pendingLabel : String.String, onPress : msg } -> Web3.Transaction.Status -> Html.Html msg"},{"name":"receiptView","comment":" Display a confirmed transaction receipt.\n\nRoot element: `<div class=\"web3-receipt web3-receipt--success|failed\">`\n\nEach field is wrapped in `<div class=\"web3-receipt-field\">`.\n\nCSS classes: `web3-receipt`, `web3-receipt--success`, `web3-receipt--failed`, `web3-receipt-field`\n\n","type":"List.List (Html.Attribute msg) -> { explorerUrl : String.String } -> Web3.Transaction.Receipt -> Html.Html msg"},{"name":"statusBadge","comment":" A status badge for the current transaction state.\n\nLabels: \"Idle\" / \"Awaiting Signature\" / \"Pending\" / \"Confirming\" / \"Confirmed\" / \"Failed\" / \"Rejected\"\n\nCSS classes: `web3-tx-badge` plus one of:\n`web3-tx-badge--idle`, `web3-tx-badge--pending`, `web3-tx-badge--confirmed`,\n`web3-tx-badge--failed`, `web3-tx-badge--rejected`\n\n","type":"List.List (Html.Attribute msg) -> Web3.Transaction.Status -> Html.Html msg"},{"name":"statusHashLink","comment":" Extract a hash display from a `Tx.Status`. Returns `Nothing` when there is\nno hash (Idle, AwaitingSignature, Failed, Rejected).\n\nWhen `explorerUrl` is `Just url`, renders a clickable `<a>` link.\nWhen `explorerUrl` is `Nothing` (e.g. local Anvil dev), renders a plain\n`<span class=\"web3-tx-hash\">` with the truncated hash instead of a dead link.\n\n","type":"List.List (Html.Attribute msg) -> { explorerUrl : Maybe.Maybe String.String } -> Web3.Transaction.Status -> Maybe.Maybe (Html.Html msg)"},{"name":"txHashLink","comment":" A clickable link displaying a truncated tx hash.\n\nThe `explorerUrl` is prepended to the full hash to build the href.\nExample: `{ explorerUrl = \"https://etherscan.io/tx/\" }`\n\nCSS class: `web3-tx-link`\n\n","type":"List.List (Html.Attribute msg) -> { explorerUrl : String.String } -> Web3.Types.TxHash -> Html.Html msg"}],"binops":[]},{"name":"Web3.Ui.Wallet","comment":" Wallet connection UI components.\n\nAll functions accept `List (Html.Attribute msg)` as the first argument — merged\nonto the root element. Pass `[]` for no extra attributes.\n\nNo default styles — every element has a semantic class name. Supply your own CSS.\n\n    -- Basic connect/disconnect button:\n    Web3.Ui.Wallet.connectButton []\n        { onConnect = ConnectWallet, onDisconnect = DisconnectWallet }\n        model.wallet\n\n    -- Full wallet UI handling all states:\n    Web3.Ui.Wallet.viewState []\n        { onConnect = ConnectWallet\n        , onSwitchChain = SwitchChain\n        , onDisconnect = DisconnectWallet\n        , knownChains = [ Chain.pulsechain, Chain.ethereum ]\n        }\n        model.wallet\n\n@docs connectButton, walletPicker, viewState, chainBadge\n\n","unions":[],"aliases":[],"values":[{"name":"chainBadge","comment":" Displays the connected chain name, looked up from the supplied chain list.\nFalls back to \"Unknown Chain\" if not found.\n\nShows \"Wrong Chain\" when in `WrongChain` state.\nShows \"Read-only\" when in `ReadOnly` state.\nShows \"—\" when connecting, disconnected, or in error state.\n\nCSS class: `web3-chain-badge`\n\n","type":"List.List (Html.Attribute msg) -> List.List Web3.Chain.Chain -> Web3.Wallet.State -> Html.Html msg"},{"name":"connectButton","comment":" A connect/disconnect button. Shows \"Connect\" in disconnected/error states\nand \"Disconnect\" in connected states.\n\nCSS classes: `web3-connect-btn`, `web3-disconnect-btn`\n\n","type":"List.List (Html.Attribute msg) -> { onConnect : msg, onDisconnect : msg } -> Web3.Wallet.State -> Html.Html msg"},{"name":"viewState","comment":" Full wallet UI — handles all `Wallet.State` variants with appropriate labels\nand actions.\n\nPass `knownChains` so the `WrongChain` branch can display the target network name.\n\nCSS class: `web3-wallet-state`\n\n","type":"List.List (Html.Attribute msg) -> { onConnect : msg, onSwitchChain : msg, onDisconnect : msg, knownChains : List.List Web3.Chain.Chain } -> Web3.Wallet.State -> Html.Html msg"},{"name":"walletPicker","comment":" A list of EIP-6963 discovered wallets for the user to pick from.\n\nEach wallet renders as a button with the wallet icon and name. Pass the RDNS of\nthe currently active wallet as `selected` to highlight it.\n\nCSS classes: `web3-wallet-picker` (container), `web3-wallet-option` (each item),\n`web3-wallet-option--selected` (active wallet)\n\n","type":"List.List (Html.Attribute msg) -> { onSelect : String.String -> msg, selected : Maybe.Maybe String.String } -> List.List Web3.Wallet.WalletProvider -> Html.Html msg"}],"binops":[]}]