import 'package:flutter/material.dart';
import 'package:flutter_hooks/flutter_hooks.dart';
import 'package:marking_app/common/model/marking/marking_text_question_tab.dart';

class UseTab {
  ValueNotifier<List<MarkingTextQuestionTab>> tabs; // tab列表
  ValueNotifier<MarkingTextQuestionTab?> currentTab; // 当前tab

  UseTab._({required this.tabs, required this.currentTab});

  // 工厂构造函数
  factory UseTab.use() {
    final tabs = useState<List<MarkingTextQuestionTab>>([]);
    final tab = useState(null);
    return UseTab._(tabs: tabs, currentTab: tab);
  }
}
