mirror of
https://github.com/opentffoundation/opentf.git
synced 2026-01-07 01:00:44 -05:00
We have a special treatment for multi-line strings that are being updated in-place where we show them across multiple lines in the plan output, but we didn't use that same treatment for rendering multi-line strings in isolation such as when they are being added for the first time. Here we detect when we're rendering a multi-line string in a no-change situation and render it using the diff renderer instead, using the same value for old and new and thus producing a multi-line result without any diff markers at all. This improves consistency between the change and no-change cases, and makes multi-line strings (such as YAML in block mode) readable in all cases.