feat: Optimize international document addresses (#7372)

pull/7377/head
2024-12-16 17:38:09 +08:00 committed by GitHub
parent fa86c4f39a
commit 40604c7880
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
23 changed files with 69 additions and 30 deletions

View File

@ -13,6 +13,7 @@ const message = {
colon: ': ',
example: 'For example, ',
fit2cloud: 'FIT2CLOUD',
lingxia: 'Lingxia',
button: {
create: 'Create ',
add: 'Add ',

View File

@ -12,6 +12,7 @@ const message = {
colon: '',
example: '',
fit2cloud: '',
lingxia: '',
button: {
create: '',
add: '',

View File

@ -12,6 +12,7 @@ const message = {
colon: '',
example: '',
fit2cloud: '',
lingxia: '',
button: {
create: '',
add: '',

View File

@ -2,7 +2,12 @@
<div class="footer" :style="{ height: mobile ? '108px' : '48px' }">
<div class="flex w-full flex-col gap-4 md:justify-between md:flex-row">
<div class="flex flex-wrap gap-4">
<a href="https://fit2cloud.com/" target="_blank">Copyright © 2014-2024 {{ $t('commons.fit2cloud') }}</a>
<a v-if="!globalStore.isIntl" href="https://fit2cloud.com/" target="_blank">
Copyright © 2014-2024 {{ $t('commons.fit2cloud') }}
</a>
<a v-if="globalStore.isIntl" href="https://1panel.hk/" target="_blank">
Copyright © 2024 {{ $t('commons.lingxia') }}
</a>
</div>
<div class="flex flex-row gap-2 md:flex-col lg:flex-row">
<SystemUpgrade :footer="true" />

View File

@ -123,7 +123,7 @@ html {
.input-help {
font-size: 12px;
word-break: keep-all;
word-break: keep-all;
color: #adb0bc;
width: 100%;
display: inline-block;

View File

@ -469,5 +469,4 @@ html.dark {
background-color: var(--panel-main-bg-color-9) !important;
color: var(--el-color-primary) !important;
}
}

View File

@ -269,4 +269,3 @@ html {
background-color: var(--el-color-primary-light-9) !important;
border-color: var(--el-button-border-color) !important;
}

View File

@ -436,7 +436,7 @@ const save = async (key: string, value: string) => {
};
const toDoc = () => {
window.open('https://1panel.cn/docs/user_manual/containers/setting/', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/containers/setting/', '_blank', 'noopener,noreferrer');
};
const onOperator = async (operation: string) => {

View File

@ -71,7 +71,9 @@ import { FormInstance } from 'element-plus';
import { updateIpv6Option } from '@/api/modules/container';
import DrawerHeader from '@/components/drawer-header/index.vue';
import { checkIpV6 } from '@/utils/util';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const loading = ref();
const drawerVisible = ref();
const confirmDialogRef = ref();
@ -108,7 +110,7 @@ function checkFixedCidrV6(rule: any, value: any, callback: any) {
}
const toDoc = () => {
window.open('https://1panel.cn/docs/user_manual/containers/setting/', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/containers/setting/', '_blank', 'noopener,noreferrer');
};
const emit = defineEmits<{ (e: 'search'): void }>();

View File

@ -90,6 +90,9 @@ import { onMounted, reactive, ref } from 'vue';
import { operateForwardRule, searchFireRule } from '@/api/modules/host';
import { Host } from '@/api/interface/host';
import i18n from '@/lang';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const loading = ref();
const activeTag = ref('forward');
@ -157,7 +160,7 @@ const onOpenDialog = async (
dialogRef.value!.acceptParams(params);
};
const toDoc = () => {
window.open('https://1panel.cn/docs/user_manual/hosts/firewall/', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/hosts/firewall/', '_blank', 'noopener,noreferrer');
};
const onDelete = async (row: Host.RuleForward | null) => {
let names = [];

View File

@ -131,6 +131,9 @@ import { ElMessageBox } from 'element-plus';
import i18n from '@/lang';
import { MsgSuccess } from '@/utils/message';
import { Position } from '@element-plus/icons-vue';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const loading = ref();
const activeTag = ref('address');
@ -195,7 +198,7 @@ const onOpenDialog = async (
};
const toDoc = () => {
window.open('https://1panel.cn/docs/user_manual/hosts/firewall/', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/hosts/firewall/', '_blank', 'noopener,noreferrer');
};
const onChange = async (info: any) => {

View File

@ -181,6 +181,9 @@ import i18n from '@/lang';
import { MsgSuccess } from '@/utils/message';
import { ElMessageBox } from 'element-plus';
import router from '@/routers';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const loading = ref();
const activeTag = ref('port');
@ -254,7 +257,7 @@ const quickJump = () => {
router.push({ name: 'AppInstalled' });
};
const toDoc = () => {
window.open('https://1panel.cn/docs/user_manual/hosts/firewall/', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/hosts/firewall/', '_blank', 'noopener,noreferrer');
};
const onChangeStatus = async (row: Host.RuleInfo, status: string) => {

View File

@ -39,7 +39,7 @@
class="ml-1 text-xs"
type="primary"
target="_blank"
href="https://1panel.cn/docs/user_manual/settings/#3"
:href="globalStore.docsUrl + '/user_manual/settings/#3'"
>
{{ $t('commons.button.helpDoc') }}
</el-link>
@ -486,6 +486,9 @@ import { Backup } from '@/api/interface/backup';
import { ElForm } from 'element-plus';
import i18n from '@/lang';
import { MsgSuccess } from '@/utils/message';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const data = ref();
const opRef = ref();

View File

@ -114,6 +114,9 @@ import { Backup } from '@/api/interface/backup';
import DrawerHeader from '@/components/drawer-header/index.vue';
import { addBackup, editBackup, getOneDriveInfo } from '@/api/modules/setting';
import { MsgSuccess } from '@/utils/message';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const loading = ref(false);
type FormInstance = InstanceType<typeof ElForm>;
@ -214,7 +217,7 @@ function callback(error: any) {
const toDoc = (isConf: boolean) => {
let item = isConf ? '#onedrive' : '#onedrive_1';
window.open('https://1panel.cn/docs/user_manual/settings/' + item, '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/settings/' + item, '_blank', 'noopener,noreferrer');
};
const onSubmit = async (formEl: FormInstance | undefined) => {

View File

@ -82,6 +82,9 @@ import { Backup } from '@/api/interface/backup';
import DrawerHeader from '@/components/drawer-header/index.vue';
import { addBackup, editBackup } from '@/api/modules/setting';
import { MsgSuccess } from '@/utils/message';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const loading = ref(false);
type FormInstance = InstanceType<typeof ElForm>;
@ -111,7 +114,7 @@ const handleClose = () => {
};
const toDoc = () => {
window.open('https://1panel.cn/docs/user_manual/settings/#webdav-alist', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/settings/#34-webdav-alist', '_blank', 'noopener,noreferrer');
};
const onSubmit = async (formEl: FormInstance | undefined) => {

View File

@ -6,7 +6,7 @@
:close-on-click-modal="false"
:close-on-press-escape="false"
@close="handleClose"
size="40%"
size="45%"
>
<template #header>
<DrawerHeader :header="$t('setting.apiInterface')" :back="handleClose" />
@ -88,14 +88,16 @@ import { MsgSuccess } from '@/utils/message';
import { ElMessageBox, FormInstance } from 'element-plus';
import DrawerHeader from '@/components/drawer-header/index.vue';
import { checkCidr, checkIp } from '@/utils/util';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const loading = ref();
const drawerVisible = ref();
const formRef = ref();
const apiURL = `${window.location.protocol}//${window.location.hostname}${
window.location.port ? `:${window.location.port}` : ''
}/1panel/swagger/index.html`;
const panelURL = `https://1panel.cn/docs/dev_manual/api_manual/`;
const panelURL = `${globalStore.docsUrl}/dev_manual/api_manual/`;
const form = reactive({
apiKey: '',

View File

@ -195,7 +195,7 @@ const loading = ref();
const selects = ref<any>([]);
const globalStore = GlobalStore();
const { isProductPro } = storeToRefs(globalStore);
const { isProductPro, docsUrl } = storeToRefs(globalStore);
const data = ref();
const paginationConfig = reactive({
cacheSizeKey: 'clam-page-size',
@ -257,7 +257,7 @@ const toFolder = (folder: string) => {
router.push({ path: '/hosts/files', query: { path: folder } });
};
const toDoc = async () => {
window.open('https://1panel.cn/docs/user_manual/toolbox/clam/', '_blank', 'noopener,noreferrer');
window.open(docsUrl + '/user_manual/toolbox/clam/', '_blank', 'noopener,noreferrer');
};
const onChange = async (row: any) => {

View File

@ -97,6 +97,9 @@ import { onMounted, ref } from 'vue';
import { ElMessageBox } from 'element-plus';
import i18n from '@/lang';
import { MsgSuccess } from '@/utils/message';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const data = ref({
isExist: false,
@ -117,7 +120,7 @@ const setting = () => {
};
const toDoc = async () => {
window.open('https://1panel.cn/docs/user_manual/toolbox/clam/', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/toolbox/clam/', '_blank', 'noopener,noreferrer');
};
const changeShow = (val: boolean) => {

View File

@ -192,6 +192,9 @@ import { MsgSuccess } from '@/utils/message';
import { getFail2banConf, getFail2banBase, operateFail2ban, updateFail2banByFile } from '@/api/modules/toolbox';
import { ElMessageBox } from 'element-plus';
import { transTimeUnit } from '@/utils/util';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const loading = ref(false);
const formRef = ref();
@ -230,7 +233,7 @@ const onLoadList = async (type: string) => {
};
const toDoc = () => {
window.open('https://1panel.cn/docs/user_manual/toolbox/fail2ban/', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/toolbox/fail2ban/', '_blank', 'noopener,noreferrer');
};
const onSaveFile = async () => {

View File

@ -178,6 +178,9 @@ import OperateDialog from '@/views/toolbox/ftp/operate/index.vue';
import LogDialog from '@/views/toolbox/ftp/log/index.vue';
import { Toolbox } from '@/api/interface/toolbox';
import router from '@/routers';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const loading = ref();
const selects = ref<any>([]);
@ -232,7 +235,7 @@ const search = async (column?: any) => {
};
const toDoc = () => {
window.open('https://1panel.cn/docs/user_manual/toolbox/ftp/', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/toolbox/ftp/', '_blank', 'noopener,noreferrer');
};
const toFolder = (folder: string) => {

View File

@ -71,7 +71,9 @@ import i18n from '@/lang';
import { MsgSuccess } from '@/utils/message';
import { HostTool } from '@/api/interface/host-tool';
import InitPage from './init/index.vue';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
let operateReq = reactive({
installId: 0,
operate: '',
@ -95,7 +97,7 @@ const setting = () => {
};
const toDoc = async () => {
window.open('https://1panel.cn/docs/user_manual/toolbox/supervisor/', '_blank', 'noopener,noreferrer');
window.open(globalStore.docsUrl + '/user_manual/toolbox/supervisor/', '_blank', 'noopener,noreferrer');
};
const init = async () => {

View File

@ -109,11 +109,7 @@
<el-alert :title="$t('runtime.buildHelper')" type="warning" :closable="false" />
<span class="input-help">
<span>{{ $t('runtime.extendHelper') }}</span>
<el-link
target="_blank"
type="primary"
href="https://1panel.cn/docs/user_manual/websites/php/#php_1"
>
<el-link target="_blank" type="primary" :href="globalStore.docsUrl + phpDocURL">
{{ $t('php.toExtensionsList') }}
</el-link>
<br />
@ -165,6 +161,10 @@ import { reactive, ref } from 'vue';
import Params from '../param/index.vue';
import EditParams from '../edit/index.vue';
import DrawerHeader from '@/components/drawer-header/index.vue';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const phpDocURL = globalStore.isIntl ? `/user_manual/websites/runtime_php/` : '/user_manual/websites/php/#php_1';
interface OperateProps {
id?: number;

View File

@ -20,11 +20,7 @@
v-model="extensions.extensions"
/>
</el-form-item>
<el-link
target="_blank"
type="primary"
href="https://1panel.cn/docs/user_manual/websites/php/#php_1"
>
<el-link target="_blank" type="primary" :href="globalStore.docsUrl + phpDocURL">
{{ $t('php.toExtensionsList') }}
</el-link>
</el-form>
@ -51,6 +47,10 @@ import { MsgSuccess } from '@/utils/message';
import { CreatePHPExtensions, UpdatePHPExtensions } from '@/api/modules/runtime';
import i18n from '@/lang';
import { Runtime } from '@/api/interface/runtime';
import { GlobalStore } from '@/store';
const globalStore = GlobalStore();
const phpDocURL = globalStore.isIntl ? `/user_manual/websites/runtime_php/` : '/user_manual/websites/php/#php_1';
const open = ref(false);
const operate = ref('create');