MCPcopy Index your code
hub / github.com/simstudioai/sim / isDisplayOnlySubBlock

Function isDisplayOnlySubBlock

apps/sim/triggers/index.ts:17–29  ·  view source on GitHub ↗

* Checks if a subBlock is display-only (not user-editable). * Display-only subBlocks should be namespaced to avoid conflicts when * multiple triggers show different content for the same conceptual field.

(subBlock: SubBlockConfig)

Source from the content-addressed store, hash-verified

15 * multiple triggers show different content for the same conceptual field.
16 */
17function isDisplayOnlySubBlock(subBlock: SubBlockConfig): boolean {
18 // Text type is always display-only
19 if (subBlock.type === 'text') {
20 return true
21 }
22
23 // ReadOnly inputs are display-only
24 if (subBlock.readOnly === true) {
25 return true
26 }
27
28 return false
29}
30
31/**
32 * Namespaces a subBlock ID with the trigger ID to avoid conflicts when

Callers 1

namespaceSubBlockIdFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected