mirror of https://github.com/ospab/ostp.git
fix(ui): resolve TypeScript compilation errors in ostp-control
This commit is contained in:
parent
c075979c62
commit
da2dbe03cd
|
|
@ -1,3 +1,5 @@
|
||||||
|
import type { AuditLogEntry } from './audit';
|
||||||
|
|
||||||
export interface UserStatsSnapshot {
|
export interface UserStatsSnapshot {
|
||||||
access_key: string;
|
access_key: string;
|
||||||
bytes_up: number;
|
bytes_up: number;
|
||||||
|
|
|
||||||
|
|
@ -376,7 +376,8 @@ export default function Clients() {
|
||||||
{/* Share Connection Modal */}
|
{/* Share Connection Modal */}
|
||||||
{showShareModal && sharingUser && (
|
{showShareModal && sharingUser && (
|
||||||
<ShareClientModal
|
<ShareClientModal
|
||||||
user={sharingUser}
|
show={showShareModal}
|
||||||
|
sharingUser={sharingUser}
|
||||||
shareLink={shareLink}
|
shareLink={shareLink}
|
||||||
isFetchingLink={isFetchingLink}
|
isFetchingLink={isFetchingLink}
|
||||||
qrCanvasRef={qrCanvasRef}
|
qrCanvasRef={qrCanvasRef}
|
||||||
|
|
|
||||||
|
|
@ -1,12 +1,10 @@
|
||||||
import React, { useState, useEffect } from 'react';
|
import { useState, useEffect } from 'react';
|
||||||
import { Route, Plus, Trash2, Save, Activity, ShieldAlert, ShieldCheck, HelpCircle } from 'lucide-react';
|
import { Route, Plus, Trash2, Save, Activity, ShieldAlert, ShieldCheck, HelpCircle } from 'lucide-react';
|
||||||
import { api } from '../lib/api';
|
import { api } from '../lib/api';
|
||||||
import type { OutboundRule, OutboundAction } from '../lib/api';
|
import type { OutboundRule, OutboundAction } from '../lib/api';
|
||||||
import { useLanguage } from '../lib/LanguageContext';
|
|
||||||
import { addAuditLog } from '../lib/audit';
|
import { addAuditLog } from '../lib/audit';
|
||||||
|
|
||||||
export default function Routing() {
|
export default function Routing() {
|
||||||
const { t } = useLanguage();
|
|
||||||
const [rules, setRules] = useState<OutboundRule[]>([]);
|
const [rules, setRules] = useState<OutboundRule[]>([]);
|
||||||
const [isLoading, setIsLoading] = useState(true);
|
const [isLoading, setIsLoading] = useState(true);
|
||||||
const [isSaving, setIsSaving] = useState(false);
|
const [isSaving, setIsSaving] = useState(false);
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,5 @@
|
||||||
import React, { useState } from 'react';
|
import React, { useState } from 'react';
|
||||||
import { X, Copy, CheckCircle2, Zap } from 'lucide-react';
|
import { X, Copy, CheckCircle2, Zap } from 'lucide-react';
|
||||||
import { useLanguage } from '../../lib/LanguageContext';
|
|
||||||
|
|
||||||
interface BulkKeysModalProps {
|
interface BulkKeysModalProps {
|
||||||
onClose: () => void;
|
onClose: () => void;
|
||||||
|
|
@ -8,7 +7,7 @@ interface BulkKeysModalProps {
|
||||||
}
|
}
|
||||||
|
|
||||||
export function BulkKeysModal({ onClose, onGenerate }: BulkKeysModalProps) {
|
export function BulkKeysModal({ onClose, onGenerate }: BulkKeysModalProps) {
|
||||||
const { t } = useLanguage();
|
|
||||||
const [count, setCount] = useState<number>(10);
|
const [count, setCount] = useState<number>(10);
|
||||||
const [limitGB, setLimitGB] = useState<string>('');
|
const [limitGB, setLimitGB] = useState<string>('');
|
||||||
const [loading, setLoading] = useState(false);
|
const [loading, setLoading] = useState(false);
|
||||||
|
|
@ -83,7 +82,7 @@ export function BulkKeysModal({ onClose, onGenerate }: BulkKeysModalProps) {
|
||||||
onClick={onClose}
|
onClick={onClose}
|
||||||
className="flex-1 px-4 py-3 rounded-xl font-medium text-white hover:bg-white/5 transition-colors border border-white/10"
|
className="flex-1 px-4 py-3 rounded-xl font-medium text-white hover:bg-white/5 transition-colors border border-white/10"
|
||||||
>
|
>
|
||||||
{t('cancel')}
|
Cancel
|
||||||
</button>
|
</button>
|
||||||
<button
|
<button
|
||||||
type="submit"
|
type="submit"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue