# encoding: cinje

: def render_text_block context, block, content
: classes = set(block.properties.get('cls', '').split())

: if 'width' in block.properties
	: classes.add('col-md-' + str(block.properties.width))
: end

<section&{id=block.properties.get('id', block.id), class_=classes, data_block=block.id, data_format=block.format, data_editable="yes"}>
	#{content}
</section>

@@ -354,19 +354,149 @@
 %22%7D%3E%0A
-%09#%7Bcontent%7D
+: if getattr(context, 'replacements', None)%0A%09: _buffer.append(content.format(**context.replacements))%0A: else%0A%09: _buffer.append(content)%0A: end
 %0A%3C/s

Support programmatic text replacements.