';
echo '
' . esc_html( $title );
if ( defined( 'AISITEARK_VERSION' ) ) {
echo ' v' . esc_html( AISITEARK_VERSION ) . '';
}
echo '
';
if ( '' !== $subtitle ) {
echo '
' . esc_html( $subtitle ) . '
';
}
echo '
';
echo '
';
echo wp_kses_post( $this->plan_badge() );
if ( '' !== $actions ) {
echo wp_kses_post( $actions );
}
echo '
';
}
/**
* Render a "locked" card shown in place of a Pro-only settings section on the
* Free plan — a clear description + Upgrade button, and NO working controls, so
* the feature is inaccessible in the UI (the server also enforces the gate).
*
* @param string $icon Dashicon class for the heading.
* @param string $title Section title.
* @param string $desc What the Pro feature does.
* @param string $checkout Upgrade/checkout URL.
* @return void
*/
public function pro_lock_card( $icon, $title, $desc, $checkout ) {
// The WordPress.org (free) build ships only the free features and never advertises Pro,
// so a locked/upgrade card must not appear there at all.
if ( defined( 'AISITEARK_DOTORG' ) && AISITEARK_DOTORG ) {
return;
}
echo '';
}
/**
* Free/Pro plan badge (with an Upgrade link on Free), returned as pre-escaped
* HTML so it can be dropped into the page header.
*
* @return string
*/
private function plan_badge() {
// No Free/Pro badge or upgrade link in the WordPress.org build — it is simply "the plugin".
if ( defined( 'AISITEARK_DOTORG' ) && AISITEARK_DOTORG ) {
return '';
}
if ( Plan::is_pro() ) {
return '