mirror of
https://github.com/EthanMarti/infio-copilot.git
synced 2026-05-08 08:00:10 +00:00
add chat view & edit line local lang
This commit is contained in:
@@ -2,6 +2,7 @@ import { ImageIcon } from 'lucide-react'
|
||||
import { TFile } from 'obsidian'
|
||||
|
||||
import { useApp } from '../../../contexts/AppContext'
|
||||
import { t } from '../../../lang/helpers'
|
||||
import { ImageSelectorModal } from '../../modals/ImageSelectorModal'
|
||||
|
||||
export function ImageUploadButton({
|
||||
@@ -34,7 +35,7 @@ export function ImageUploadButton({
|
||||
<div className="infio-chat-user-input-submit-button-icons">
|
||||
<ImageIcon size={12} />
|
||||
</div>
|
||||
<div>Image</div>
|
||||
<div>{t('chat.input.image')}</div>
|
||||
</button>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@ import { ChevronDown, ChevronUp, Star, StarOff } from 'lucide-react'
|
||||
import { useEffect, useMemo, useRef, useState } from 'react'
|
||||
|
||||
import { useSettings } from '../../../contexts/SettingsContext'
|
||||
import { t } from '../../../lang/helpers'
|
||||
import { ApiProvider } from '../../../types/llm/model'
|
||||
import { GetAllProviders, GetProviderModelIds } from "../../../utils/api"
|
||||
|
||||
@@ -256,7 +257,7 @@ export function ModelSelect() {
|
||||
{settings.collectedChatModels?.length > 0 && (
|
||||
<div className="infio-model-section">
|
||||
<div className="infio-model-section-title">
|
||||
<Star size={12} className="infio-star-active" /> collected models
|
||||
<Star size={12} className="infio-star-active" /> {t('chat.input.collectedModels')}
|
||||
</div>
|
||||
<ul className="infio-collected-models-list">
|
||||
{settings.collectedChatModels.map((collectedModel, index) => (
|
||||
@@ -415,7 +416,7 @@ export function ModelSelect() {
|
||||
)}
|
||||
</div>
|
||||
{isLoading ? (
|
||||
<div className="infio-loading">loading...</div>
|
||||
<div className="infio-loading">{t('chat.input.loading')}</div>
|
||||
) : (
|
||||
<div className="infio-model-section">
|
||||
<ul>
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
import { CornerDownLeftIcon } from 'lucide-react'
|
||||
|
||||
import { t } from '../../../lang/helpers'
|
||||
|
||||
export function SubmitButton({ onClick }: { onClick: () => void }) {
|
||||
return (
|
||||
<button className="infio-chat-user-input-submit-button" onClick={onClick}>
|
||||
<div>submit</div>
|
||||
{t('chat.input.submit')}
|
||||
<div className="infio-chat-user-input-submit-button-icons">
|
||||
<CornerDownLeftIcon size={12} />
|
||||
</div>
|
||||
|
||||
@@ -8,6 +8,8 @@ import {
|
||||
} from 'lexical'
|
||||
import { CSSProperties, useCallback, useEffect, useRef, useState } from 'react'
|
||||
|
||||
import { t } from '../../../../../lang/helpers'
|
||||
|
||||
export default function CreateCommandPopoverPlugin({
|
||||
anchorElement,
|
||||
contentEditableElement,
|
||||
@@ -121,7 +123,7 @@ export default function CreateCommandPopoverPlugin({
|
||||
setIsPopoverOpen(false)
|
||||
}}
|
||||
>
|
||||
create command
|
||||
{t('chat.input.createCommand')}
|
||||
</button>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user