<commit_before>import * as React from "react";
import { useState } from "react";
import { Listable } from "../../../common/Listable";
import { PersistentCharacter } from "../../../common/PersistentCharacter";
import { SavedEncounter } from "../../../common/SavedEncounter";
import { Spell } from "../../../common/Spell";
import { StatBlock } from "../../../common/StatBlock";
import { LibrariesCommander } from "../../Commands/LibrariesCommander";
import { Button } from "../../Components/Button";
import { Tabs } from "../../Components/Tabs";
import { VerticalResizer } from "../../Layout/VerticalResizer";
import { BuildListingTree } from "../Components/BuildListingTree";
import { LibraryFilter } from "../Components/LibraryFilter";
import { FilterCache } from "../FilterCache";
import { Libraries, LibraryFriendlyNames, LibraryType } from "../Libraries";
import { Listing } from "../Listing";
import { ActiveLibrary } from "./ActiveLibrary";
import { EditorView } from "./EditorView";
import { LibraryManagerRow } from "./LibraryManagerRow";
import { SelectedItemsManager } from "./SelectedItemsManager";
import { Selection, SelectionContext, useSelection } from "./SelectionContext";

export type LibraryManagerProps = {
  librariesCommander: LibrariesCommander;
  libraries: Libraries;
  closeManager: () => void;
  initialPane?: LibraryType;
};

export function LibraryManager(props: LibraryManagerProps) {
  const [activeTab, setActiveTab] = useState<LibraryType>(
    props.initialPane || "StatBlocks"
  );
  const [leftColumnWidth, setLeftColumnWidth] = useState(500);
  const [centerColumnWidth, setCenterColumnWidth] = useState(500);
  const selectionsByTab: Record<LibraryType, Selection<Listing<Listable>>> = {
    StatBlocks: useSelection<Listing<StatBlock>>(),
    PersistentCharacters: useSelection<Listing<PersistentCharacter>>(),
    Encounters: useSelection<Listing<SavedEncounter>>(),
    Spells: useSelection<Listing<Spell>>()
  };<commit_msg>larger default center column<commit_after>import * as React from "react";
import { useState } from "react";
import { Listable } from "../../../common/Listable";
import { PersistentCharacter } from "../../../common/PersistentCharacter";
import { SavedEncounter } from "../../../common/SavedEncounter";
import { Spell } from "../../../common/Spell";
import { StatBlock } from "../../../common/StatBlock";
import { LibrariesCommander } from "../../Commands/LibrariesCommander";
import { Button } from "../../Components/Button";
import { Tabs } from "../../Components/Tabs";
import { VerticalResizer } from "../../Layout/VerticalResizer";
import { BuildListingTree } from "../Components/BuildListingTree";
import { LibraryFilter } from "../Components/LibraryFilter";
import { FilterCache } from "../FilterCache";
import { Libraries, LibraryFriendlyNames, LibraryType } from "../Libraries";
import { Listing } from "../Listing";
import { ActiveLibrary } from "./ActiveLibrary";
import { EditorView } from "./EditorView";
import { LibraryManagerRow } from "./LibraryManagerRow";
import { SelectedItemsManager } from "./SelectedItemsManager";
import { Selection, SelectionContext, useSelection } from "./SelectionContext";

export type LibraryManagerProps = {
  librariesCommander: LibrariesCommander;
  libraries: Libraries;
  closeManager: () => void;
  initialPane?: LibraryType;
};

export function LibraryManager(props: LibraryManagerProps) {
  const [activeTab, setActiveTab] = useState<LibraryType>(
    props.initialPane || "StatBlocks"
  );
  const [leftColumnWidth, setLeftColumnWidth] = useState(500);
  const [centerColumnWidth, setCenterColumnWidth] = useState(600);
  const selectionsByTab: Record<LibraryType, Selection<Listing<Listable>>> = {
    StatBlocks: useSelection<Listing<StatBlock>>(),
    PersistentCharacters: useSelection<Listing<PersistentCharacter>>(),
    Encounters: useSelection<Listing<SavedEncounter>>(),
    Spells: useSelection<Listing<Spell>>()
  };
{'fraction_non_alphanumeric': 0.1561470215462611, 'fraction_numerical': 0.003041825095057034, 'mean_word_length': 4.907185628742515, 'pattern_counts': {'":': 0, '<': 27, '<?xml version=': 0, '>': 29, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '811237', 'n_tokens_mistral': 1033, 'n_tokens_neox': 1056, 'n_words': 263}