Browse Source

chore(web): update label for webhook

pull/48/head
isra el 1 year ago
parent
commit
1dcde4b345
  1. 2
      web/app/(app)/dashboard/(components)/messaging.tsx
  2. 33
      web/app/(app)/dashboard/(components)/webhooks/webhooks-section.tsx

2
web/app/(app)/dashboard/(components)/messaging.tsx

@ -30,7 +30,7 @@ export default function Messaging() {
Bulk Send{' '} Bulk Send{' '}
<Badge <Badge
variant='outline' variant='outline'
className='ml-2 bg-blue-500 text-white dark:bg-blue-600 dark:text-white'
className='ml-2 bg-yellow-100 dark:bg-yellow-900 text-yellow-800 dark:text-yellow-200'
> >
new new
</Badge> </Badge>

33
web/app/(app)/dashboard/(components)/webhooks/webhooks-section.tsx

@ -17,7 +17,8 @@ import {
TooltipContent, TooltipContent,
TooltipProvider, TooltipProvider,
TooltipTrigger, TooltipTrigger,
} from "@/components/ui/tooltip"
} from '@/components/ui/tooltip'
import { Badge } from '@/components/ui/badge'
function WebhookCardSkeleton() { function WebhookCardSkeleton() {
return ( return (
@ -90,18 +91,12 @@ export default function WebhooksSection() {
<h1 className='text-xl sm:text-2xl font-bold flex flex-wrap items-center gap-2'> <h1 className='text-xl sm:text-2xl font-bold flex flex-wrap items-center gap-2'>
<Webhook className='h-5 w-5 sm:h-6 sm:w-6' /> <Webhook className='h-5 w-5 sm:h-6 sm:w-6' />
Webhooks Webhooks
<TooltipProvider>
<Tooltip>
<TooltipTrigger>
<span className='text-xs font-medium px-2 py-1 rounded-full bg-yellow-100 dark:bg-yellow-900 text-yellow-800 dark:text-yellow-200'>
BETA
</span>
</TooltipTrigger>
<TooltipContent>
<p>This feature is in beta and may undergo changes. Use with caution in production environments.</p>
</TooltipContent>
</Tooltip>
</TooltipProvider>
<Badge
variant='outline'
className='text-xs font-medium px-2 py-1 rounded-full bg-yellow-100 dark:bg-yellow-900 text-yellow-800 dark:text-yellow-200'
>
new
</Badge>
</h1> </h1>
<p className='text-sm text-muted-foreground mt-2'> <p className='text-sm text-muted-foreground mt-2'>
Manage webhook notifications for your SMS events Manage webhook notifications for your SMS events
@ -124,7 +119,10 @@ export default function WebhooksSection() {
</TooltipTrigger> </TooltipTrigger>
{webhooks?.data?.length > 0 && ( {webhooks?.data?.length > 0 && (
<TooltipContent> <TooltipContent>
<p>You already have an active webhook subscription. You can edit or manage the existing webhook instead.</p>
<p>
You already have an active webhook subscription. You can edit
or manage the existing webhook instead.
</p>
</TooltipContent> </TooltipContent>
)} )}
</Tooltip> </Tooltip>
@ -154,9 +152,12 @@ export default function WebhooksSection() {
</div> </div>
) : ( ) : (
<div className='bg-muted/50 rounded-lg p-8 text-center'> <div className='bg-muted/50 rounded-lg p-8 text-center'>
<h3 className='text-lg font-medium mb-2'>No webhook configured</h3>
<h3 className='text-lg font-medium mb-2'>
No webhook configured
</h3>
<p className='text-muted-foreground mb-4'> <p className='text-muted-foreground mb-4'>
Create a webhook to receive real-time notifications for SMS events
Create a webhook to receive real-time notifications for SMS
events
</p> </p>
<Button onClick={handleCreateClick} variant='default'> <Button onClick={handleCreateClick} variant='default'>
<PlusCircle className='mr-2 h-4 w-4' /> <PlusCircle className='mr-2 h-4 w-4' />

Loading…
Cancel
Save