View Categories

Shortcode Reference

1 min read

Table of Contents

CardanoPress includes shortcodes for components, templates, and data. Use them in pages, posts, or blocks via the Shortcode block.

#

Outputs a stored CardanoPress option value.

AttributeDefaultDescription
key (required)''The option key to fetch.
sub (optional)''Return a subkey if the option value is an array.

Examples

[cardanopress_option key="payment_recipient"]
[cardanopress_option key="pool_config" sub="ticker"]

#

Loads a CardanoPress template by name. You can pass variables and render conditionally.

AttributeDefaultDescription
name (required)''Relative to templates/, e.g. part/payment-button or page/Dashboard.
variables (optional)''Query-string variables, e.g. a=1&b=test.
if (optional)''Expression for conditional output using <template x-if>.

Examples

[cardanopress_template name="payment-form"]

[cardanopress_template name="part/payment-button" variables="label=Pay Now&amp;style=primary"]

[cardanopress_template_if]</h2>
Wraps content with <code>&lt;template x-if="..."&gt;</code> when a condition is set.
<table>
<thead>
<tr>
<th>Attribute</th>
<th>Default</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><code>condition</code> (optional)</td>
<td><code>''</code></td>
<td>Alpine expression to evaluate.</td>
</tr>
</tbody>
</table>
<strong>Example</strong>
<pre><code>[cardanopress_template_if condition="isConnected"]
&lt;p&gt;Welcome back.&lt;/p&gt;
[/cardanopress_template_if]

#

Renders the wallet-connected user profile.

AttributeDefaultDescription
No attributes.

Example

[cardanopress_userprofile]

#

Displays a configured stake pool with delegation controls.

AttributeDefaultDescription
key (required)''Pool key as set in CardanoPress settings.

Example

[cardanopress_delegationpool key="main_pool"]

#

Shows a wallet balance for an address or the connected wallet.

AttributeDefaultDescription
address (optional)''Bech32 address. If empty, uses the connected wallet when available.
unit (optional)lovelacelovelace or ada. Converts to ADA when set to ada.

Examples

[cardanopress_wallet_balance]

Mounts the main CardanoPress component. You can prefill data.

AttributeDefaultDescription
amount (optional)nullInitial amount for payments.
address (optional)nullInitial payment address.

Example

[cardanopress_component_cardanopress amount="12.5" address="addr1..."]

#

Renders the pool delegation component.

AttributeDefaultDescription
No attributes.

Example

[cardanopress_component_pooldelegation]

#

Renders the payment form component.

AttributeDefaultDescription
No attributes.

Example

[cardanopress_component_paymentform]

Wraps inner content in a split-form container.

Attribute Default Description
method (optional) '' Optional method hint for custom logic.
sub (optional) '' Optional variant hint.

Example


<!-- your split form rows here -->

Powered by BetterDocs