@univerjs-pro/docs-sdt
Structured document tag (SDT) commands for Docs content controls. Register the Docs core and license plugins first, then add this plugin and the optional @univerjs-pro/docs-sdt-ui editor controls.
import { UniverDocsSdtPlugin } from '@univerjs-pro/docs-sdt'univer.registerPlugin(UniverDocsSdtPlugin)Commands and locks
The root exports UpdateSdtValueCommand, UpdateSdtPropertiesCommand, RemoveSdtCommand, DuplicateRepeatingSdtItemCommand, DeleteRepeatingSdtItemCommand, and their parameter types. Run them through the command service or univerAPI.executeCommand() so edits participate in undo/redo.
Content controls live in IDocumentBody.customRanges, with their properties in ISdtCustomRange.properties. Content locks prevent value edits; control locks prevent removing the wrapper. Repeating sections can also disallow item insertion and deletion. The root exports isSdtContentLocked, isSdtWrapperLocked, and findSdtAtOffset for integrations.
This package has no stylesheet, locales, or Facade entry. DOCX conversion belongs to Exchange; editor support does not guarantee lossless support for every Word property or custom XML binding. See the content-controls guide.
How is this guide?