> For the complete documentation index, see [llms.txt](https://help.sdocs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.sdocs.com/sdocs/enhanced-template-editor/enhanced-template-editor-overview.md).

# Enhanced Template Editor Overview

The S-Docs Enhanced Template Editor provides a true WYSIWYG experience designed for process optimization and operational workflow efficiency. This interface displays an exact document view with visible page boundaries, allowing you to simplify and automate processes directly within your Salesforce org. By utilizing these declarative design features, your organization can increase productivity and remove friction in day-to-day processes.

#### Interface & Styling Tools

The workspace includes a basic styling ribbon that provides standard formatting capabilities found in traditional document editing software. This ribbon includes the following tools:

* Core editing commands such as the Undo<img src="/files/h7FAZ0zSaNlAE270Gyx9" alt="" data-size="line">and Redo<img src="/files/KGIfHyTq79urDG7vwua4" alt="" data-size="line"> buttons.
* Standard text adjustments including bold<img src="/files/RYZg0RyXVRsbtffgJFh2" alt="" data-size="line"> , italic<img src="/files/Y1GvXmjZ31E6erzGLRBb" alt="" data-size="line">, underline<img src="/files/Cngw5Xyh5KwIhWcYQAn1" alt="" data-size="line">, strikethrough<img src="/files/KLKeQ5PA1fybACqPf0ZD" alt="" data-size="line">, subscript<img src="/files/AM2WHnKqDEfCVVyuaJEy" alt="" data-size="line">, and superscript<img src="/files/wzsJHqN1cHc5VIIJEazC" alt="" data-size="line">options.
* Color customization options for both font color <img src="/files/XCIHcxbRvbWUV6jS1i9X" alt="" data-size="line"> and background color <img src="/files/hZfd3QW1vimBEJXRbP74" alt="" data-size="line">.
* Paragraph layout adjustments for font size <img src="/files/8cY355bCMLbtecaZkwqo" alt="" data-size="line">and text alignment <img src="/files/bxDrzFIFLWcrwS6wl7yw" alt="" data-size="line"> — including left, right, center, and justified options.
* List structures such as unordered lists <img src="/files/JhtRoDQL8R157VU3gOiO" alt="" data-size="line">, ordered lists <img src="/files/WDyuBfO2VOcfaADgD4xI" alt="" data-size="line">, and text indentation <img src="/files/nRd8jPGrwq961JLiVcPe" alt="" data-size="line"> controls.
* Custom configuration tools to insert images<img src="/files/E3c1lO7VjF1mV7djEfPV" alt="" data-size="line">, related lists<img src="/files/1XBOCanPQxHGzedQD1hQ" alt="" data-size="line">, and conditional logic<img src="/files/XJ5FBgoSnXY4ZUe0iwMn" alt="" data-size="line"> directly into the template body.

#### Variables Panel

Incorporate dynamic merge field data into your document by using the *Variables panel* — also referred to as the *Merge field panel*. This panel automatically displays the standard and custom fields configured for your specific Salesforce base object, such as an Opportunity or Account. When an end user generates a document, S-Docs automatically replaces these placeholders with live values from the target generation record.

To quickly navigate your dynamic data options, the panel includes several filtering and navigation tools:

* **Field type filters:** You can sort fields using four distinct tabs, which isolate *text* ![](/files/BxXe0pT3yjrzF8gUj5Xp), *number* ![](/files/X3QZAUaHiB01GOXIfwQJ), *Boolean/checkbox* ![](/files/IQ4TmrX7KN9oQl2frKnA), or *date* ![](/files/c79yMKJuowrxZKMskiJr) fields. By default, you can view all available fields simultaneously.
* **Search functionality:** Use the *Search field* to enter a specific term — such as "contact" — to instantly filter the list down to only relevant field values.
* **Special merge fields:** This default section contains system-driven runtime variables that populate during document generation, capturing real-time details like the running user and the operational timestamp.
* **Advanced variables:** Incorporate advanced data into S-Docs templates by configuring SOQL queries or real-time User Inputs that expand further and deeper into data flexibility.

{% hint style="info" %}
Explore the links below for more detailed information on Advanced Data variable configuration:

[**Advanced Data: Using SOQL to Add Variables**](/sdocs/enhanced-template-editor/advanced-data-using-soql-to-add-variables.md)

[**Advanced Data: User Input Variables**](/sdocs/enhanced-template-editor/advanced-data-user-input-variables.md)
{% endhint %}

#### Headers & Footers

S-Docs makes it easy to customize your document templates with consistent headers and footers. You can quickly add, edit, and update these sections directly within the enhanced template workspace.

To add or modify a header or footer, follow these steps:

1. Navigate to the template body workspace inside the Enhanced Editor.
2. Hover your cursor over the top margin (to create a header) or the bottom margin (to create a footer) of the template.
3. Double-click the margin area to activate edit mode for that specific section.
4. Enter your desired text, layout, and content.
5. Click anywhere inside the main template body to deactivate edit mode.

{% hint style="success" %}
The header and footer sections will retain the information entered, automatically applying it whenever the document is generated.
{% endhint %}

#### General Navigation & Template Management

The editor header provides essential tracking details and control options to streamline your template configuration workflow:

* **Template tracking:** The top header displays the template name, file type, and the active template status — which tracks whether the file is **Draft**, **Published**, or contains **Unpublished Changes**.
* **Data source relationship:** A navigation breadcrumb located directly below the template title identifies the specific base Salesforce database object, such as an Opportunity or Account.
* **Template activation:** Activating a template requires an explicit step. You must click the Publish button to make the template available for general document generation.
* **Live previewing:** Use the new preview functionality to designate a specific testing record and click the Preview button. This opens a live data rendering window, which is covered in detail in a separate reference guide.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://help.sdocs.com/sdocs/enhanced-template-editor/enhanced-template-editor-overview.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
