Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 0 additions & 31 deletions web/packages/teleport/src/Bots/Add/AddBotsPicker.story.tsx

This file was deleted.

52 changes: 1 addition & 51 deletions web/packages/teleport/src/Bots/Add/AddBotsPicker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,9 @@
import { ReactNode } from 'react';
import styled from 'styled-components';

import { Box, Flex, Text } from 'design';
import { Flex, Text } from 'design';
import { ResourceIconName } from 'design/ResourceIcon';
import { P } from 'design/Text/Text';
import { InfoGuideButton } from 'shared/components/SlidingSidePanel/InfoGuide';

import { FeatureHeader, FeatureHeaderTitle } from 'teleport/components/Layout';
import { ToolTipNoPermBadge } from 'teleport/components/ToolTipNoPermBadge';
import cfg from 'teleport/config';
import { IntegrationTile } from 'teleport/Integrations';
Expand All @@ -34,9 +31,7 @@ import {
IntegrationEnrollKind,
userEventService,
} from 'teleport/services/userEvent';
import useTeleport from 'teleport/useTeleport';

import { InfoGuide } from '../InfoGuide';
import { BotFlowType } from '../types';

export type BotIntegration = {
Expand Down Expand Up @@ -202,51 +197,6 @@ export const integrations: BotIntegration[] = [
},
];

// TODO(alexhemard): delete in a follow up PR
export function AddBotsPicker() {
const ctx = useTeleport();
return (
<>
<FeatureHeader justifyContent="space-between">
<FeatureHeaderTitle>Select Bot Type</FeatureHeaderTitle>
<InfoGuideButton config={{ guide: <InfoGuide /> }} />
</FeatureHeader>

<P mb="5">
Set up Teleport Machine ID to allow CI/CD workflows and other machines
to access resources protected by Teleport.
</P>

<BotTiles hasCreateBotPermission={ctx.getFeatureFlags().addBots} />
</>
);
}

export function BotTiles({
hasCreateBotPermission,
}: {
hasCreateBotPermission: boolean;
}) {
return (
<div
css={`
display: grid;
grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
gap: 16px;
`}
>
{integrations.map(i => (
<Box key={i.title}>
<BotTile
integration={i}
hasCreateBotPermission={hasCreateBotPermission}
/>
</Box>
))}
</div>
);
}

export function BotTile({
integration,
hasCreateBotPermission,
Expand Down

This file was deleted.

Loading