--- import type { __experimental_SubscriptionDetailsButtonProps } from '@clerk/shared/types'; import type { ButtonProps } from '../../types'; import { addUnstyledAttributeToFirstTag } from './utils'; type Props = ButtonProps & Omit<__experimental_SubscriptionDetailsButtonProps, 'onSubscriptionCancel'> & { clickIdentifier?: string }; import { generateSafeId } from '@clerk/astro/internal'; const safeId = generateSafeId(); const { asChild, for: _for, clickIdentifier, subscriptionDetailsProps, ...props } = Astro.props; const subscriptionDetailsOptions = { for: _for, clickIdentifier, ...subscriptionDetailsProps, }; let htmlElement = ''; if (asChild) { htmlElement = await Astro.slots.render('default'); htmlElement = addUnstyledAttributeToFirstTag(htmlElement, safeId); } --- { asChild ? ( ) : ( ) }