@pretextbook/web-editor 0.4.3 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ declare function BareHostHarness(): import("react").JSX.Element;
2
+ export default BareHostHarness;
@@ -2,9 +2,11 @@ import { type EditDraft } from "./types";
2
2
  interface SectionEditFormProps {
3
3
  draft: EditDraft;
4
4
  isLatex: boolean;
5
+ /** The root division's type (book/article/slideshow) is structural and not user-editable. */
6
+ isRoot?: boolean;
5
7
  onDraftChange: (draft: EditDraft) => void;
6
8
  onCommit: () => void;
7
9
  onCancel: () => void;
8
10
  }
9
- declare const SectionEditForm: ({ draft, isLatex, onDraftChange, onCommit, onCancel, }: SectionEditFormProps) => import("react").JSX.Element;
11
+ declare const SectionEditForm: ({ draft, isLatex, isRoot, onDraftChange, onCommit, onCancel, }: SectionEditFormProps) => import("react").JSX.Element;
10
12
  export default SectionEditForm;
@@ -15,6 +15,7 @@ interface SectionItemProps {
15
15
  onEditCancel: () => void;
16
16
  menuItems: DivisionMenuItem[];
17
17
  isLatex: boolean;
18
+ isRoot?: boolean;
18
19
  }
19
- declare const SectionItem: ({ division, depth, isActive, hasChildren, isExpanded, onToggleExpand, editDraft, onSelect, onDraftChange, onEditCommit, onEditCancel, menuItems, isLatex, }: SectionItemProps) => import("react").JSX.Element;
20
+ declare const SectionItem: ({ division, depth, isActive, hasChildren, isExpanded, onToggleExpand, editDraft, onSelect, onDraftChange, onEditCommit, onEditCancel, menuItems, isLatex, isRoot, }: SectionItemProps) => import("react").JSX.Element;
20
21
  export default SectionItem;
package/dist/index.d.ts CHANGED
@@ -12,7 +12,7 @@ DocumentSection,
12
12
  /** @deprecated Chapters are now plain `Division` records with type `"chapter"`. */
13
13
  DocumentChapter, } from "./types/sections";
14
14
  export type { DivisionTreeNode } from "./sectionUtils";
15
- export { assembleProjectSource, parseDivisionRefs, insertDivisionRef, removeDivisionRef, moveDivisionRef, reorderDivisionRefs, normalizeSelfClosingRefs, getOrphanedDivisions, getOrphanRoots, buildDivisionTree, wrapDivisionForPreview, updateDivisionTitle, createNewSection, createIntroduction, createConclusion, stripSectionWrapper, rewrapSection, ensureSectionWrapper, mergeTwoSections, getSectionAttributes, updateSectionMetadata, stripLatexSectionWrapper, rewrapLatexSection, ensureLatexSectionWrapper, updateLatexSectionTitle, createNewLatexSection, createLatexIntroduction, createLatexConclusion, } from "./sectionUtils";
15
+ export { assembleProjectSource, parseDivisionRefs, insertDivisionRef, removeDivisionRef, moveDivisionRef, renameDivisionRef, findDivisionParent, reorderDivisionRefs, normalizeSelfClosingRefs, getOrphanedDivisions, getOrphanRoots, buildDivisionTree, wrapDivisionForPreview, updateDivisionTitle, createNewSection, createIntroduction, createConclusion, stripSectionWrapper, rewrapSection, ensureSectionWrapper, mergeTwoSections, getSectionAttributes, updateSectionMetadata, extractDivisionMetadata, stripLatexSectionWrapper, rewrapLatexSection, ensureLatexSectionWrapper, updateLatexSectionTitle, extractLatexDivisionTitle, createNewLatexSection, createLatexIntroduction, createLatexConclusion, } from "./sectionUtils";
16
16
  export { default as CodeEditor } from "./components/CodeEditor";
17
17
  export { VisualEditor } from "@pretextbook/visual-editor";
18
18
  export { default as FullPreview } from "./components/FullPreview";