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
24 changes: 24 additions & 0 deletions crates/agent-mobile/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
dist
dist-ssr
*.local

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
7 changes: 7 additions & 0 deletions crates/agent-mobile/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Tauri + Vue + TypeScript

This template should help get you started developing with Vue 3 and TypeScript in Vite. The template uses Vue 3 `<script setup>` SFCs, check out the [script setup docs](https://v3.vuejs.org/api/sfc-script-setup.html#sfc-script-setup) to learn more.

## Recommended IDE Setup

- [VS Code](https://code.visualstudio.com/) + [Vue - Official](https://marketplace.visualstudio.com/items?itemName=Vue.volar) + [Tauri](https://marketplace.visualstudio.com/items?itemName=tauri-apps.tauri-vscode) + [rust-analyzer](https://marketplace.visualstudio.com/items?itemName=rust-lang.rust-analyzer)
81 changes: 81 additions & 0 deletions crates/agent-mobile/biome.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
{
"$schema": "https://biomejs.dev/schemas/2.4.15/schema.json",
"vcs": {
"enabled": true,
"clientKind": "git",
"useIgnoreFile": false
},
"files": {
"includes": [
"src/**",
"!!**/dist",
"!!**/node_modules",
"!src/lib/proto/gen/**",
"!src/lib/models/catalog.generated.ts"
]
},
"formatter": {
"enabled": true,
"indentStyle": "space",
"indentWidth": 2,
"lineWidth": 100
},
"linter": {
"enabled": true,
"rules": {
"recommended": true,
"a11y": {
"useKeyWithClickEvents": "warn",
"noStaticElementInteractions": "warn",
"noLabelWithoutControl": "warn",
"useSemanticElements": "warn",
"useAriaPropsSupportedByRole": "warn",
"useAriaPropsForRole": "warn",
"useFocusableInteractive": "warn",
"noAutofocus": "off",
"noSvgWithoutTitle": "warn"
},
"correctness": {
"useExhaustiveDependencies": "warn",
"noUnusedImports": "error"
},
"suspicious": {
"noArrayIndexKey": "warn"
}
}
},
"javascript": {
"formatter": {
"quoteStyle": "double",
"trailingCommas": "all",
"semicolons": "always"
}
},
"css": {
"parser": {
"tailwindDirectives": true
}
},
"assist": {
"enabled": true,
"actions": {
"source": {
"organizeImports": "on"
}
}
},
"overrides": [
{
"includes": [
"**/*.css"
],
"linter": {
"rules": {
"suspicious": {
"noDuplicateProperties": "off"
}
}
}
}
]
}
14 changes: 14 additions & 0 deletions crates/agent-mobile/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<!doctype html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>LiveAgent Mobile</title>
</head>

<body>
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>
65 changes: 65 additions & 0 deletions crates/agent-mobile/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
{
"name": "@liveagent/mobile",
"private": true,
"version": "0.1.0",
"type": "module",
"scripts": {
"dev": "vite --host",
"build": "tsc && vite build",
"preview": "vite preview",
"lint": "biome check src/",
"tauri": "tauri",
"format": "biome format --write src/",
"lint:fix": "biome check --write src/"
},
"dependencies": {
"@base-ui/react": "^1.7.0",
"@bufbuild/protobuf": "^2.14.0",
"@earendil-works/pi-ai": "^0.80.10",
"@git-diff-view/file": "^0.1.7",
"@git-diff-view/react": "^0.1.7",
"@iconify-json/gravity-ui": "^1.2.14",
"@liveagent/ui": "workspace:*",
"@sinclair/typebox": "^0.34.52",
"@streamdown/cjk": "^1.0.3",
"@streamdown/code": "^1.1.1",
"@streamdown/math": "^1.0.2",
"@streamdown/mermaid": "^1.0.2",
"@tanstack/react-virtual": "^3.14.9",
"@tauri-apps/api": "^2.11.1",
"@tauri-apps/plugin-opener": "^2.5.4",
"@xterm/addon-fit": "^0.11.0",
"@xterm/xterm": "^6.0.0",
"class-variance-authority": "^0.7.1",
"clsx": "^2.1.1",
"katex": "^0.17.0",
"monaco-editor": "^0.55.1",
"react": "^19.2.8",
"react-complex-tree": "^2.6.2",
"react-dom": "^19.2.8",
"remark-breaks": "^4.0.0",
"streamdown": "^2.5.0",
"tailwind-merge": "^3.6.0",
"yet-another-react-lightbox": "^3.32.2"
},
"devDependencies": {
"@biomejs/biome": "^2.5.8",
"@bufbuild/protoc-gen-es": "2.12.1",
"@iconify-json/logos": "^1.2.12",
"@iconify-json/lucide": "^1.2.123",
"@iconify-json/material-icon-theme": "1.2.67",
"@svgr/core": "^8.1.0",
"@svgr/plugin-jsx": "^8.1.0",
"@tailwindcss/postcss": "4.2.2",
"@tailwindcss/typography": "^0.5.20",
"@tauri-apps/cli": "^2.11.4",
"@types/react": "^19.2.18",
"@types/react-dom": "^19.2.4",
"@vitejs/plugin-react": "^6.0.5",
"postcss": "^8.5.26",
"tailwindcss": "4.2.2",
"typescript": "6.0.2",
"unplugin-icons": "^23.0.1",
"vite": "^8.2.1"
}
}
5 changes: 5 additions & 0 deletions crates/agent-mobile/postcss.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
export default {
plugins: {
"@tailwindcss/postcss": {},
},
};
107 changes: 107 additions & 0 deletions crates/agent-mobile/public/favicon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added crates/agent-mobile/public/icon-simple.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added crates/agent-mobile/public/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions crates/agent-mobile/src-tauri/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Generated by Cargo
# will have compiled files and executables
/target/

# Generated by Tauri
# will have schema files for capabilities auto-completion
/gen/schemas
25 changes: 25 additions & 0 deletions crates/agent-mobile/src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
[package]
name = "liveagent_mobile"
version = "0.1.0"
description = "A Tauri App"
authors = ["you"]
edition = "2021"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[lib]
# The `_lib` suffix may seem redundant but it is necessary
# to make the lib name unique and wouldn't conflict with the bin name.
# This seems to be only an issue on Windows, see https://github.com/rust-lang/cargo/issues/8519
name = "liveagent_mobile_lib"
crate-type = ["staticlib", "cdylib", "rlib"]

[build-dependencies]
tauri-build = { version = "2", features = [] }

[dependencies]
tauri = { version = "2", features = [] }
tauri-plugin-opener = "2"
serde = { version = "1", features = ["derive"] }
serde_json = "1"

3 changes: 3 additions & 0 deletions crates/agent-mobile/src-tauri/build.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fn main() {
tauri_build::build()
}
10 changes: 10 additions & 0 deletions crates/agent-mobile/src-tauri/capabilities/default.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"$schema": "../gen/schemas/desktop-schema.json",
"identifier": "default",
"description": "Capability for the main window",
"windows": ["main"],
"permissions": [
"core:default",
"opener:default"
]
}
12 changes: 12 additions & 0 deletions crates/agent-mobile/src-tauri/gen/android/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# EditorConfig is awesome: https://EditorConfig.org

# top-most EditorConfig file
root = true

[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = false
insert_final_newline = false
20 changes: 20 additions & 0 deletions crates/agent-mobile/src-tauri/gen/android/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
*.iml
.gradle
/local.properties
/.idea/caches
/.idea/libraries
/.idea/modules.xml
/.idea/workspace.xml
/.idea/navEditor.xml
/.idea/assetWizardSettings.xml
.DS_Store
build
/captures
.externalNativeBuild
.cxx
local.properties
key.properties
keystore.properties

/.tauri
/tauri.settings.gradle
Loading
Loading