mirror of
https://github.com/rubickCenter/rubick
synced 2025-12-18 08:44:16 +08:00
✨ 适配超级面板
This commit is contained in:
@@ -21,6 +21,7 @@
|
||||
|
||||
<script setup>
|
||||
import { reactive, ref } from "vue";
|
||||
import { message } from "ant-design-vue";
|
||||
|
||||
const formRef = ref();
|
||||
const formState = reactive({
|
||||
@@ -45,6 +46,7 @@ const downloadPlugin = async (pluginName) => {
|
||||
name: pluginName,
|
||||
isDev: true,
|
||||
});
|
||||
message.success(`${pluginName}安装成功!`);
|
||||
loading.value = false;
|
||||
};
|
||||
|
||||
|
||||
@@ -6,8 +6,9 @@
|
||||
<div class="container" v-else>
|
||||
<div class="installed-list">
|
||||
<div
|
||||
:class="currentSelect === index ? 'item active' : 'item'"
|
||||
:class="currentSelect[0] === index ? 'item active' : 'item'"
|
||||
:key="index"
|
||||
@click="currentSelect = [index]"
|
||||
v-for="(plugin, index) in localPlugins"
|
||||
>
|
||||
<img :src="plugin.logo" />
|
||||
@@ -101,7 +102,7 @@ const localPlugins = computed(() =>
|
||||
);
|
||||
const updateLocalPlugin = () => store.dispatch("updateLocalPlugin");
|
||||
|
||||
const currentSelect = ref(0);
|
||||
const currentSelect = ref([0]);
|
||||
|
||||
const pluginDetail = computed(() => {
|
||||
return localPlugins.value[currentSelect.value] || {};
|
||||
|
||||
@@ -81,10 +81,12 @@ const newList = computed(() => {
|
||||
<style lang="less">
|
||||
.finder {
|
||||
width: 100%;
|
||||
height: 100vh;
|
||||
height: 100%;
|
||||
overflow-x: hidden;
|
||||
box-sizing: border-box;
|
||||
|
||||
&::-webkit-scrollbar {
|
||||
width: 0;
|
||||
}
|
||||
.ant-carousel .slick-slide {
|
||||
text-align: center;
|
||||
height: 235px;
|
||||
|
||||
@@ -78,6 +78,7 @@ import {
|
||||
|
||||
import { defineProps, ref } from "vue";
|
||||
import { useStore } from "vuex";
|
||||
import { message } from "ant-design-vue";
|
||||
|
||||
const store = useStore();
|
||||
|
||||
@@ -95,6 +96,7 @@ defineProps({
|
||||
const downloadPlugin = async (plugin) => {
|
||||
startDownload(plugin.name);
|
||||
await window.market.downloadPlugin(plugin);
|
||||
message.success(`${plugin.name}安装成功!`);
|
||||
successDownload(plugin.name);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user