Fix search + linux build (#179)

This commit is contained in:
Geometrically 2023-06-20 22:04:17 -07:00 committed by GitHub
parent 8e5a0b8ae2
commit 4f9ec0e02b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 21 additions and 14 deletions

View File

@ -1,6 +1,6 @@
[package] [package]
name = "theseus" name = "theseus"
version = "0.2.0" version = "0.2.1"
authors = ["Jai A <jaiagr+gpg@pm.me>"] authors = ["Jai A <jaiagr+gpg@pm.me>"]
edition = "2018" edition = "2018"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "theseus_cli" name = "theseus_cli"
version = "0.2.0" version = "0.2.1"
authors = ["Jai A <jaiagr+gpg@pm.me>"] authors = ["Jai A <jaiagr+gpg@pm.me>"]
edition = "2018" edition = "2018"

View File

@ -39,6 +39,7 @@ tracing-error = "0.1"
sentry = "0.30" sentry = "0.30"
sentry-rust-minidump = "0.5" sentry-rust-minidump = "0.5"
[target.'cfg(not(target_os = "linux"))'.dependencies]
window-shadows = "0.2.1" window-shadows = "0.2.1"
[target.'cfg(target_os = "macos")'.dependencies] [target.'cfg(target_os = "macos")'.dependencies]

View File

@ -7,8 +7,6 @@ use theseus::prelude::*;
use tauri::Manager; use tauri::Manager;
use window_shadows::set_shadow;
use tracing_error::ErrorLayer; use tracing_error::ErrorLayer;
use tracing_subscriber::EnvFilter; use tracing_subscriber::EnvFilter;
@ -86,11 +84,16 @@ fn main() {
}) })
} }
builder = builder.setup(|app| { #[cfg(not(target_os = "linux"))]
let win = app.get_window("main").unwrap(); {
set_shadow(&win, true).unwrap(); use window_shadows::set_shadow;
Ok(())
}); builder = builder.setup(|app| {
let win = app.get_window("main").unwrap();
set_shadow(&win, true).unwrap();
Ok(())
});
}
#[cfg(target_os = "macos")] #[cfg(target_os = "macos")]
{ {

View File

@ -8,7 +8,7 @@
}, },
"package": { "package": {
"productName": "Modrinth App", "productName": "Modrinth App",
"version": "0.2.0" "version": "0.2.1"
}, },
"tauri": { "tauri": {
"allowlist": { "allowlist": {

View File

@ -77,7 +77,7 @@ import {
import dayjs from 'dayjs' import dayjs from 'dayjs'
import relativeTime from 'dayjs/plugin/relativeTime' import relativeTime from 'dayjs/plugin/relativeTime'
import { ref } from 'vue' import { ref } from 'vue'
import { add_project_from_version as installMod, check_installed, list } from '@/helpers/profile.js' import { add_project_from_version as installMod, list } from '@/helpers/profile.js'
import { install as packInstall } from '@/helpers/pack.js' import { install as packInstall } from '@/helpers/pack.js'
import { installVersionDependencies } from '@/helpers/utils.js' import { installVersionDependencies } from '@/helpers/utils.js'
import { useFetch } from '@/helpers/fetch.js' import { useFetch } from '@/helpers/fetch.js'
@ -118,12 +118,14 @@ const props = defineProps({
type: Boolean, type: Boolean,
default: false, default: false,
}, },
installed: {
type: Boolean,
default: false,
},
}) })
const installing = ref(false) const installing = ref(false)
const installed = ref( const installed = ref(props.installed)
props.instance ? await check_installed(props.instance.path, props.project.project_id) : false
)
async function install() { async function install() {
installing.value = true installing.value = true

View File

@ -688,6 +688,7 @@ const showLoaders = computed(
:confirm-modal="confirmModal" :confirm-modal="confirmModal"
:mod-install-modal="modInstallModal" :mod-install-modal="modInstallModal"
:incompatibility-warning-modal="incompatibilityWarningModal" :incompatibility-warning-modal="incompatibilityWarningModal"
:installed="result.installed"
/> />
</section> </section>
<pagination <pagination