Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: remove ai template #10515

Merged
merged 4 commits into from
Nov 27, 2024
Merged
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
1 change: 0 additions & 1 deletion codegen.json
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@
"GenerateGroupsSuccess": "./types/GenerateGroupsSuccess#GenerateGroupsSuccessSource",
"GenerateInsightSuccess": "./types/GenerateInsightSuccess#GenerateInsightSuccessSource",
"GenerateRetroSummariesSuccess": "./types/GenerateRetroSummariesSuccess#GenerateRetroSummariesSuccessSource",
"GetTemplateSuggestionSuccess": "./types/GetTemplateSuggestionSuccess#GetTemplateSuggestionSuccessSource",
"GitHubIntegration": "../../postgres/queries/getGitHubAuthByUserIdTeamId#GitHubAuth",
"GitLabIntegration": "./types/GitLabIntegration#GitLabIntegrationSource",
"IntegrationProviderOAuth1": "../../postgres/queries/getIntegrationProvidersByIds#TIntegrationProvider",
Expand Down
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,7 @@
"git-url-parse": "12.0.0",
"fbjs": "^3.0.0",
"parse-url": "^8.1.0",
"recursive-readdir": "^2.2.3",
"json5": "^2.2.3"
"recursive-readdir": "^2.2.3"
},
"devDependencies": {
"@babel/core": "^7.20.12",
Expand Down
97 changes: 0 additions & 97 deletions packages/client/components/ActivityLibrary/AISearch.tsx

This file was deleted.

33 changes: 11 additions & 22 deletions packages/client/components/ActivityLibrary/ActivityLibrary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import logoMarkPurple from '../../styles/theme/images/brand/mark-color.svg'
import SendClientSideEvent from '../../utils/SendClientSideEvent'
import IconLabel from '../IconLabel'
import LoadingComponent from '../LoadingComponent/LoadingComponent'
import AISearch from './AISearch'
import ActivityGrid from './ActivityGrid'
import ActivityLibraryEmptyState from './ActivityLibraryEmptyState'
import {
Expand Down Expand Up @@ -117,9 +116,6 @@ const query = graphql`
}
}
}
organizations {
hasAITemplateFlag: featureFlag(featureName: "aiTemplate")
}
}
}
`
Expand Down Expand Up @@ -226,8 +222,7 @@ export const ActivityLibrary = (props: Props) => {
const {queryRef} = props
const data = usePreloadedQuery<ActivityLibraryQuery>(query, queryRef)
const {viewer} = data
const {availableTemplates, organizations} = viewer
const hasAITemplateFeatureFlag = organizations.some((org) => org.hasAITemplateFlag)
const {availableTemplates} = viewer

const [isSearching, setIsSearching] = useState(true)
const [templateSearch, refetchTemplateSearch] = useRefetchableFragment<
Expand Down Expand Up @@ -361,17 +356,16 @@ export const ActivityLibrary = (props: Props) => {
Start Activity
</div>
</div>
{!hasAITemplateFeatureFlag && (
<div className='hidden grow md:block'>
<SearchBar
searchQuery={searchQuery}
onChange={(e) => {
onQueryChange(e)
setSearch(e.target.value)
}}
/>
</div>
)}
<div className='hidden grow md:block'>
<SearchBar
searchQuery={searchQuery}
onChange={(e) => {
onQueryChange(e)
setSearch(e.target.value)
}}
/>
</div>

<Link
className='rounded-full bg-sky-500 px-4 py-2 text-sm font-medium text-white hover:bg-sky-600'
to={`/activity-library/new-activity/${categoryId}`}
Expand Down Expand Up @@ -429,11 +423,6 @@ export const ActivityLibrary = (props: Props) => {

<ScrollArea.Root className='h-full w-full overflow-hidden'>
<ScrollArea.Viewport className='flex h-full flex-col lg:mx-[15%]'>
{hasAITemplateFeatureFlag && (
<div className='mx-auto mt-4 pt-2'>
<AISearch />
</div>
)}
{templatesToRender.length === 0 && !showLoading ? (
<ActivityLibraryEmptyState
searchQuery={searchQuery}
Expand Down
41 changes: 0 additions & 41 deletions packages/client/mutations/GetTemplateSuggestionMutation.ts

This file was deleted.

65 changes: 0 additions & 65 deletions packages/server/graphql/public/mutations/getTemplateSuggestion.ts

This file was deleted.

This file was deleted.

This file was deleted.

10 changes: 0 additions & 10 deletions packages/server/graphql/public/typeDefs/Mutation.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -1460,16 +1460,6 @@ type Mutation {
"""
createStripeSubscription(orgId: ID!, paymentMethodId: ID!): CreateStripeSubscriptionPayload!

"""
Ask the AI for a template suggestion
"""
getTemplateSuggestion(
"""
The question the user has for the AI
"""
prompt: String!
): GetTemplateSuggestionPayload!

"""
Sign up or login using Google
"""
Expand Down

This file was deleted.

Loading