feat(teacher-portal): 完整实现 teacher-portal 微前端

包含 settings/students/api、graphql、mocks、ui-tokens 设计令牌等
This commit is contained in:
SpecialX
2026-07-10 19:10:20 +08:00
parent 14d836beb0
commit 1eacd1ed87
48 changed files with 3897 additions and 1056 deletions

View File

@@ -29,13 +29,13 @@ export class ErrorBoundary extends Component<
ErrorBoundaryProps,
ErrorBoundaryState
> {
state: ErrorBoundaryState = { error: null };
override state: ErrorBoundaryState = { error: null };
static getDerivedStateFromError(error: Error): ErrorBoundaryState {
return { error };
}
componentDidCatch(error: Error, info: ErrorInfo): void {
override componentDidCatch(error: Error, info: ErrorInfo): void {
this.props.onError?.(error, info);
}
@@ -44,7 +44,7 @@ export class ErrorBoundary extends Component<
this.setState({ error: null });
};
render(): ReactNode {
override render(): ReactNode {
const { error } = this.state;
const { children, fallback } = this.props;

View File

@@ -79,5 +79,5 @@ function getTailwindPrefix(token: string): string | null {
const match = token.match(
/^(bg|text|p|m|px|py|mx|my|w|h|min-h|min-w|border|rounded|shadow|font|leading|tracking|gap|space|flex|grid|col|row|inset|top|right|bottom|left|z|opacity|transition|duration|delay|animate|hover|focus|sm|md|lg|xl|2xl)-/,
);
return match ? match[1] : null;
return match?.[1] ?? null;
}