Notes
Notes
- This component does not use a datasource item. It reads context from the current route (page) and the
?id=query string parameter. - On load, a JavaScript IIFE posts a JSON payload to
/api/docs/document/createcontaining the route name astemplateSuiteId, the resolved topic ascategory, and ajsonTemplateIdthat differs between dev and non-dev hosts. - On success the browser is redirected to the one-time link URL returned from the API. On failure an error heading replaces the loading spinner.
- The
?id=query parameter should be a GUID in "N" format (no hyphens). If provided, a GraphQL call resolves the item name for use as the document category. If absent, it falls back to the firstRelevantTopicsfield value from the current route item. - Access control is enforced server-side via
DynamicDocUtil.CanAccessDocumentTemplateId, which checks topic entitlements. - The iframe starts with
src="about:blank"and is populated after the API redirect completes.
Control Properties
Dynamic Doc Iframe
An embedded document viewer that loads documents in an iframe for inline viewing. Supports PDF, Office documents, and other viewable formats without requiring file download. Includes fullscreen toggle.
Control Properties
| Property | Type | Description |
|---|---|---|
| Small | Droplink | Bootstrap column width at the small breakpoint. |
| Medium | Droplink | Bootstrap column width at the medium breakpoint. |
| Large | Droplink | Bootstrap column width at the large breakpoint. |
| OffsetSmall | Droplink | Column offset at the small breakpoint. |
| OffsetMedium | Droplink | Column offset at the medium breakpoint. |
| OffsetLarge | Droplink | Column offset at the large breakpoint. |
| AddClass | Single-Line Text | Additional CSS classes appended to the component wrapper. |
Template Properties
Template Properties
This component does not use a datasource template. It derives all data from the current route item context and query string parameters.
| Source | Field / Parameter | Description |
|---|---|---|
| Route item | Name | Used as the templateSuiteId in the document creation API call. |
| Route item | RelevantTopics | Multilist field providing the default topic/category when no ?id= query parameter is present. |
| Query string | id | Optional GUID (N format) identifying a Sitecore item whose name becomes the document category. |