Skip to content

Commit

Permalink
chore: SurgeMac 说明文案
Browse files Browse the repository at this point in the history
  • Loading branch information
xream committed Jan 17, 2024
1 parent 77892bd commit 1ff0f0e
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 1 deletion.
3 changes: 3 additions & 0 deletions src/assets/styles/global.scss
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,9 @@ img {
// .nut-icon-find:before {
// content: "\e661";
// }
.nut-icon-tips:before {
content: "\e671";
}
.nut-icon-category:before {
content: "\e662";
}
Expand Down
14 changes: 14 additions & 0 deletions src/components/PreviewPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<img :src="platform.icon" class="auto-reverse" />
</div>
<p>{{ platform.name }}</p>
<nut-icon name="tips" v-if="platform.name === 'Surge'" @click="surgeTips"></nut-icon>
</div>

<div class="actions">
Expand Down Expand Up @@ -34,6 +35,7 @@
</template>

<script lang="ts" setup>
import { Toast } from '@nutui/nutui';
import surfboard from '@/assets/icons/surfboard.png';
import surge from '@/assets/icons/surge.png';
import clash from '@/assets/icons/clash.png';
Expand All @@ -50,6 +52,7 @@
import { useAppNotifyStore } from '@/store/appNotify';
import SvgIcon from '@/components/SvgIcon.vue';
import { useHostAPI } from '@/hooks/useHostAPI';
const { copy, isSupported } = useClipboard();
const { toClipboard: copyFallback } = useV3Clipboard();
const { showNotify } = useAppNotifyStore();
Expand Down Expand Up @@ -131,6 +134,17 @@
icon: v2ray,
},
];
const surgeTips = () => {
Toast.text('"target=SurgeMac" - supports SSR external', {
title: 'Surge Tips',
duration: 0,
cover: true,
'close-on-click-overlay': true,
'bg-color': 'rgba(0, 0, 0, 0.8)',
'cover-color': 'rgba(0, 0, 0, 0.2)',
'text-align-center': false,
});
};
</script>

<style lang="scss" scoped>
Expand Down
2 changes: 1 addition & 1 deletion src/locales/zh.ts
Original file line number Diff line number Diff line change
Expand Up @@ -565,7 +565,7 @@ export default {
download: {
content: '⚠️ 只会获取不在同步配置中的 gist 文件\n你需要手动设置来源',
confirm: '从 gist 恢复',
},
}
},
themeSettingPage: {
themeSettingTitle: '外观设置',
Expand Down

0 comments on commit 1ff0f0e

Please sign in to comment.