aboutsummaryrefslogtreecommitdiff
path: root/src-vue/src/views/DeveloperView.vue
diff options
context:
space:
mode:
authorRémy Raes <contact@remyraes.com>2022-11-30 18:48:45 +0100
committerGitHub <noreply@github.com>2022-11-30 18:48:45 +0100
commitd61f3fe1b0c9f4461d33f289b3100465d77999ad (patch)
tree80d03616cc2475a242ce315f7007d4152cfd3bfe /src-vue/src/views/DeveloperView.vue
parente301086cbb26fcb1d9e520c016b00233aba0f315 (diff)
downloadFlightCore-d61f3fe1b0c9f4461d33f289b3100465d77999ad.tar.gz
FlightCore-d61f3fe1b0c9f4461d33f289b3100465d77999ad.zip
feat: Release channel selector (#86)
* refactor: Move release channel button to settings * chore: Revert single newline removal * feat: add basic selector * feat: add basic selector style (to match button style) * fix: remove box-shadow on selector * feat: selector displays release canal from UI store * refactor: export toggleReleaseCandidate to store, for it to be used by release canal selector * feat: selector effectively changes release canal * fix: selector members typing issue * refactor: adjust selector labels * refactor: remove channel switching button Since the channel selector on the play view allows users to switch channels, this button is now useless. * feat: add a switch to toggle releases switching * feat: switch only appears if corresponding flag is enabled * feat: adjust button corners regarding releases switching state * feat: switch value is saved in persistent store * refactor: update release candidate label * fix: set release canal to RELEASE when switch is toggled off
Diffstat (limited to 'src-vue/src/views/DeveloperView.vue')
-rw-r--r--src-vue/src/views/DeveloperView.vue27
1 files changed, 0 insertions, 27 deletions
diff --git a/src-vue/src/views/DeveloperView.vue b/src-vue/src/views/DeveloperView.vue
index f2e097b0..e15f2ad0 100644
--- a/src-vue/src/views/DeveloperView.vue
+++ b/src-vue/src/views/DeveloperView.vue
@@ -19,10 +19,6 @@
<h3>Testing:</h3>
- <el-button type="primary" @click="toggleReleaseCandidate">
- Toggle Release Candidate
- </el-button>
-
<el-button type="primary" @click="launchGameWithoutChecks">
Launch Northstar (bypass all checks)
</el-button>
@@ -60,7 +56,6 @@
import { defineComponent } from "vue";
import { invoke } from "@tauri-apps/api";
import { ElNotification } from "element-plus";
-import { ReleaseCanal } from "../utils/ReleaseCanal";
import { GameInstall } from "../utils/GameInstall";
import { Store } from 'tauri-plugin-store-api';
const persistentStore = new Store('flight-core-settings.json');
@@ -105,28 +100,6 @@ export default defineComponent({
console.error(error);
});
},
- async toggleReleaseCandidate() {
- // Flip between RELEASE and RELEASE_CANDIDATE
- this.$store.state.northstar_release_canal = this.$store.state.northstar_release_canal === ReleaseCanal.RELEASE
- ? ReleaseCanal.RELEASE_CANDIDATE
- : ReleaseCanal.RELEASE;
-
- // Save change in persistent store
- await persistentStore.set('northstar-release-canal', { value: this.$store.state.northstar_release_canal });
-
- // Update current state so that update check etc can be performed
- this.$store.commit("checkNorthstarUpdates");
-
- console.log(this.$store.state)
-
- // Display notification to highlight change
- ElNotification({
- title: `${this.$store.state.northstar_release_canal}`,
- message: `Switched release channel to: "${this.$store.state.northstar_release_canal}"`,
- type: 'success',
- position: 'bottom-right'
- });
- },
async launchGameWithoutChecks() {
this.$store.commit('launchGame', true);
},