diff --git a/apps/operate/components/Agents.tsx b/apps/operate/components/Agents.tsx new file mode 100644 index 00000000..29a6101d --- /dev/null +++ b/apps/operate/components/Agents.tsx @@ -0,0 +1,183 @@ +import { + BulbFilled, + DownOutlined, + PlayCircleOutlined, + RightOutlined, + RobotOutlined, +} from '@ant-design/icons'; +import { Button, Card, Col, Row, Typography } from 'antd'; +import Image from 'next/image'; +import styled from 'styled-components'; + +import { BREAK_POINT, COLOR } from 'libs/ui-theme/src'; + +const { Title, Paragraph, Text } = Typography; + +const StyledMain = styled.main` + display: flex; + flex-direction: column; + max-width: ${BREAK_POINT.md}; + margin: 0 auto; +`; + +const StyledCard = styled(Card)` + border-color: ${COLOR.BORDER_GREY}; + width: 100%; + .ant-card-body { + padding: 0; + } +`; + +const CardBody = styled.div` + padding: 16px; +`; + +const StyledImage = styled(Image)` + border-bottom: 1px solid ${COLOR.BORDER_GREY}; + border-top-left-radius: 5px; + border-top-right-radius: 5px; + display: block; + object-fit: cover; +`; + +const StyledAddImage = styled(StyledImage)` + border-top-right-radius: 0px; + border-bottom-left-radius: 5px; + border-bottom: 0; + border-right: 1px solid ${COLOR.BORDER_GREY}; +`; + +type Agent = { + id: string; + name: string; + description: string; + comingSoon: boolean; + urls: Record; + imageFilename: string; +}; + +const agents: Agent[] = [ + { + id: '582c485c-a2ba-4c53-8c58-8eb7b34ef87c', + name: 'Prediction Agent', + description: 'Participates in prediction markets according to your strategy.', + comingSoon: false, + urls: { + run: 'https://github.com/valory-xyz/trader-quickstart?tab=readme-ov-file#trader-quickstart', + learnMore: 'https://olas.network/services/prediction-agents', + gpt: 'https://chat.openai.com/g/g-6y88mEBzS-olas-trader-agent-guide', + }, + imageFilename: 'prediction-agent.png', + }, +]; + +const AgentCard = ({ agent }: { agent: Agent }) => { + const { id, name, description, imageFilename, urls, comingSoon } = agent; + + const { run, learnMore, gpt } = urls; + + return ( + + + + + + {name} + +
+ {description} +
+ {comingSoon ? ( + + ) : ( + <> + {run && ( + + )} +
+ {learnMore && ( + + )} + {gpt && ( + + )} + + )} +
+
+ + ); +}; + +export const AgentsPage = () => { + return ( + + + {agents.map((agent) => ( + + ))} + + + + + + + + + Want people to run <b>your</b> agent? + + + Build an autonomous service using Open Autonomy. Then, simply submit a pull + request including the quickstart. + + + + + + + + + ); +}; diff --git a/apps/operate/pages/agents.tsx b/apps/operate/pages/agents.tsx new file mode 100644 index 00000000..66271d07 --- /dev/null +++ b/apps/operate/pages/agents.tsx @@ -0,0 +1,3 @@ +import { AgentsPage } from 'components/Agents'; + +export default AgentsPage; diff --git a/apps/operate/public/images/add-your-own.png b/apps/operate/public/images/add-your-own.png new file mode 100644 index 00000000..2e170ae1 Binary files /dev/null and b/apps/operate/public/images/add-your-own.png differ diff --git a/apps/operate/public/images/prediction-agent.png b/apps/operate/public/images/prediction-agent.png new file mode 100644 index 00000000..ef7f38bf Binary files /dev/null and b/apps/operate/public/images/prediction-agent.png differ diff --git a/libs/ui-theme/src/lib/GlobalStyles.tsx b/libs/ui-theme/src/lib/GlobalStyles.tsx index 6ffccf6b..b31a8aef 100644 --- a/libs/ui-theme/src/lib/GlobalStyles.tsx +++ b/libs/ui-theme/src/lib/GlobalStyles.tsx @@ -96,6 +96,9 @@ export const GlobalStyles = createGlobalStyle` .p-0 { padding: 0 !important; } + .p-16 { + padding: 16px !important; + } .pl-0 { padding-left: 0px !important; }