Skip to content

Commit

Permalink
Merge pull request #595 from valory-xyz/mohan/X-account-automated-copy
Browse files Browse the repository at this point in the history
fix: x account automated text in setup form
  • Loading branch information
mohandast52 authored Dec 16, 2024
2 parents 3171e03 + c967f28 commit 34d0c74
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
11 changes: 9 additions & 2 deletions frontend/components/Alert/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,21 @@ const icons = {
error: <ExclamationCircleOutlined />,
};

type CustomAlertProps = {
type: AlertType;
fullWidth?: boolean;
className?: string;
} & Omit<AlertProps, 'type'>;

export const CustomAlert = ({
type,
fullWidth,
className,
...rest
}: { type: AlertType; fullWidth?: boolean } & Omit<AlertProps, 'type'>) => (
}: CustomAlertProps) => (
<AlertAntd
type={type === 'primary' ? undefined : type}
className={`custom-alert custom-alert--${type} ${fullWidth ? 'custom-alert--full-width' : ''}`}
className={`custom-alert custom-alert--${type} ${fullWidth ? 'custom-alert--full-width' : ''} ${className}`}
icon={rest.showIcon ? icons[type] : undefined}
{...rest}
/>
Expand Down
14 changes: 14 additions & 0 deletions frontend/components/SetupPage/SetupYourAgent/SetupYourAgent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,20 @@ const XAccountCredentials = () => (
and enter the login details. This enables your agent to view X and
interact with other agents.
</Text>
<CustomAlert
type="warning"
showIcon
message={
<Flex justify="space-between" gap={4} vertical>
<Text>
Make sure to set the account as `Automated`. When logged in on X, go
to Settings &gt; Your account &gt; Account information &gt;
Automation.
</Text>
</Flex>
}
className="mb-16"
/>
</Flex>
);

Expand Down

0 comments on commit 34d0c74

Please sign in to comment.