remove redundant code

This commit is contained in:
Alphons Joseph
2024-09-05 20:45:52 +08:00
parent e001078808
commit 4a8ed32d3e
6 changed files with 4 additions and 93 deletions
@@ -1,5 +1,8 @@
<script lang="ts">
function formatUrl(inputUrl: string) {
const protocolRegex = /^(http:\/\/|https:\/\/|ftp:\/\/)/;
return protocolRegex.test(inputUrl) ? inputUrl : `https://${inputUrl}`;
}
</script>
<div class="text-xl">shortcuts tab</div>
-64
View File
@@ -1,64 +0,0 @@
export interface SettingsState {
notificationCollector: boolean;
theme: string;
lessonAlerts: boolean;
telemetry: boolean;
animatedBackground: boolean;
animatedBackgroundSpeed: string;
customThemeColor: string;
betterSEQTAPlus: boolean;
shortcuts: Shortcut[];
customshortcuts: CustomShortcut[];
transparencyEffects: boolean;
}
interface ToggleItem {
toggle: boolean;
}
interface Shortcut {
enabled: boolean;
name: string;
}
export interface CustomShortcut {
name: string;
url: string;
icon: string;
}
export interface MainConfig {
DarkMode: boolean;
animatedbk: boolean;
bksliderinput: string;
customshortcuts: CustomShortcut[];
defaultmenuorder: any[];
lessonalert: boolean;
menuitems: {
assessments: ToggleItem;
courses: ToggleItem;
dashboard: ToggleItem;
documents: ToggleItem;
forums: ToggleItem;
goals: ToggleItem;
home: ToggleItem;
messages: ToggleItem;
myed: ToggleItem;
news: ToggleItem;
notices: ToggleItem;
portals: ToggleItem;
reports: ToggleItem;
settings: ToggleItem;
timetable: ToggleItem;
welcome: ToggleItem;
};
menuorder: any[];
notificationcollector: boolean;
telemetry: boolean;
onoff: boolean;
selectedColor: string;
shortcuts: Shortcut[];
subjectfilters: Record<string, any>;
transparencyEffects: boolean;
theme: string;
}
@@ -1,5 +0,0 @@
export interface ColorPickerProps {
color: string;
onChange: (color: string) => void;
id: string;
}
@@ -1,7 +0,0 @@
import React from 'react';
import "./Slider.css";
export interface Slider {
onValueChange: (value: number) => void;
}
declare const Slider: React.FC<Slider>;
export default Slider;
@@ -1,6 +0,0 @@
import "./Switch.css";
export interface SwitchProps {
onChange: (isOn: boolean) => void;
state: boolean;
}
@@ -1,10 +0,0 @@
import React, { JSX } from 'react';
export interface Tab {
title: string;
content: JSX.Element;
}
export interface TabbedContainerProps {
tabs: Tab[];
}
declare const TabbedContainer: React.FC<TabbedContainerProps>;
export default TabbedContainer;