Skip to content

Commit

Permalink
Merge pull request #434 from janhq/fix/update-version
Browse files Browse the repository at this point in the history
fix: app version and cleanup unused code
  • Loading branch information
urmauur authored Oct 24, 2023
2 parents 245eaa7 + 2cf9c0f commit e0dd07c
Show file tree
Hide file tree
Showing 6 changed files with 2 additions and 140 deletions.
14 changes: 0 additions & 14 deletions web/app/_hooks/useCreateBot.ts

This file was deleted.

24 changes: 0 additions & 24 deletions web/app/_hooks/useDeleteBot.ts

This file was deleted.

27 changes: 0 additions & 27 deletions web/app/_hooks/useGetBots.ts

This file was deleted.

36 changes: 0 additions & 36 deletions web/app/_hooks/useUpdateBot.ts

This file was deleted.

32 changes: 0 additions & 32 deletions web/app/_models/Bot.ts

This file was deleted.

9 changes: 2 additions & 7 deletions web/containers/BottomBar/index.tsx
Original file line number Diff line number Diff line change
@@ -1,18 +1,15 @@
import React from 'react'
import SystemItem from '@containers/SystemItem'
import { useAtomValue } from 'jotai'
import useGetAppVersion from '@hooks/useGetAppVersion'
import useGetSystemResources from '@hooks/useGetSystemResources'
import { useAtomValue } from 'jotai'
import { modelDownloadStateAtom } from '@helpers/atoms/DownloadState.atom'
import { formatDownloadPercentage } from '@utils/converter'
import { activeAssistantModelAtom } from '@helpers/atoms/Model.atom'

const BottomBar = () => {
const activeModel = useAtomValue(activeAssistantModelAtom)
const { version } = useGetAppVersion()
const { ram, cpu } = useGetSystemResources()
const modelDownloadStates = useAtomValue(modelDownloadStateAtom)
const getCurrentYear = new Date().getFullYear()

const downloadStates: DownloadState[] = []
for (const [, value] of Object.entries(modelDownloadStates)) {
Expand All @@ -35,9 +32,7 @@ const BottomBar = () => {
<div className="flex gap-x-2">
<SystemItem name="CPU:" value={`${cpu}%`} />
<SystemItem name="Mem:" value={`${ram}%`} />
<p className="text-xs text-muted-foreground">
&copy;{getCurrentYear}&nbsp;Jan AI Pte Ltd. v{version}
</p>
<p className="text-xs font-semibold">Jan v0.2.0</p>
</div>
</div>
)
Expand Down

0 comments on commit e0dd07c

Please sign in to comment.