Skip to content

Commit

Permalink
修复多处路径错误
Browse files Browse the repository at this point in the history
  • Loading branch information
siuze committed Jan 20, 2024
1 parent 193019c commit d24de9d
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
"build": {
"beforeBuildCommand": "yarn build",
"beforeDevCommand": "yarn run dev",
"devPath": "http://localhost:3000",
"devPath": "http://localhost:3000/ShanRenMaLTS-Typing",
"distDir": "../build"
},
"package": {
"productName": "qwerty-learner",
"productName": "ShanRenMaLTS-Typing",
"version": "0.1.0"
},
"tauri": {
Expand Down Expand Up @@ -51,7 +51,7 @@
"fullscreen": false,
"height": 600,
"resizable": true,
"title": "qwerty-learner",
"title": "ShanRenMaLTS-Typing",
"width": 800
}
]
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Typing/components/ShareButton/SharePicDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ export default function SharePicDialog({ showState, setShowState, randomChoose }
const { saveAs } = await import('file-saver')

if (imageURL) {
saveAs(imageURL, 'Qwerty-learner.png')
saveAs(imageURL, 'ShanRenMaLTS-Typing.png')
recordShareAction('download')
}
}, [imageURL])
Expand Down
2 changes: 1 addition & 1 deletion src/resources/soundResource.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { LanguagePronunciationMap, SoundResource } from '@/typings'

export const SOUND_URL_PREFIX = REACT_APP_DEPLOY_ENV === 'pages' ? '/qwerty-learner/sounds/' : './sounds/'
export const SOUND_URL_PREFIX = REACT_APP_DEPLOY_ENV === 'pages' ? '/ShanRenMaLTS-Typing/sounds/' : './sounds/'
export const KEY_SOUND_URL_PREFIX = SOUND_URL_PREFIX + 'key-sound/'

// will add more sound resource and add config ui in the future
Expand Down
2 changes: 1 addition & 1 deletion src/utils/db/data-export.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export async function exportDatabase(callback: (exportProgress: ExportProgress)
const compressed = pako.gzip(json)
const compressedBlob = new Blob([compressed])
const currentDate = getCurrentDate()
saveAs(compressedBlob, `Qwerty-Learner-User-Data-${currentDate}.gz`)
saveAs(compressedBlob, `ShanRenMaLTS-Typing-User-Data-${currentDate}.gz`)
recordDataAction({ type: 'export', size: compressedBlob.size, wordCount, chapterCount })
}

Expand Down
2 changes: 1 addition & 1 deletion src/utils/wordListFetcher.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { Word } from '@/typings'

export async function wordListFetcher(url: string): Promise<Word[]> {
const URL_PREFIX: string = REACT_APP_DEPLOY_ENV === 'pages' ? '/qwerty-learner' : ''
const URL_PREFIX: string = REACT_APP_DEPLOY_ENV === 'pages' ? '/ShanRenMaLTS-Typing' : ''

const response = await fetch(URL_PREFIX + url)
const words: Word[] = await response.json()
Expand Down

0 comments on commit d24de9d

Please sign in to comment.