mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-07-11 15:16:07 +00:00
feat(sub): per-client external links and remote subscriptions
Add a Links tab to the client form for attaching third-party share links and remote subscription URLs per client. They are merged into the client's raw/JSON/Clash subscription output: links are emitted verbatim and parsed for JSON/Clash; subscription URLs are fetched (cached, with a short timeout) and their configs merged in. i18n keys added across all 13 locales.
This commit is contained in:
@@ -1,27 +1,23 @@
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { Button } from 'antd';
|
||||
|
||||
interface Option {
|
||||
value: number;
|
||||
}
|
||||
|
||||
interface SelectAllClearButtonsProps {
|
||||
options: Option[];
|
||||
value: number[];
|
||||
onChange: (value: number[]) => void;
|
||||
interface SelectAllClearButtonsProps<T extends string | number = number> {
|
||||
options: Array<{ value: T }>;
|
||||
value: T[];
|
||||
onChange: (value: T[]) => void;
|
||||
/** Override the default "Select all" label (defaults to the inbound copy). */
|
||||
selectAllLabel?: string;
|
||||
/** Override the default "Clear all" label (defaults to the inbound copy). */
|
||||
clearLabel?: string;
|
||||
}
|
||||
|
||||
export default function SelectAllClearButtons({
|
||||
export default function SelectAllClearButtons<T extends string | number = number>({
|
||||
options,
|
||||
value,
|
||||
onChange,
|
||||
selectAllLabel,
|
||||
clearLabel,
|
||||
}: SelectAllClearButtonsProps) {
|
||||
}: SelectAllClearButtonsProps<T>) {
|
||||
const { t } = useTranslation();
|
||||
|
||||
const optionValues = options.map((o) => o.value);
|
||||
|
||||
Reference in New Issue
Block a user