Skip to content

Conversation

@hbrunn
Copy link
Member

@hbrunn hbrunn commented Jan 28, 2026

this finally lets us deal with text in upstream views that's not accessible to standard inheritance. When you have xml like

       <some>
           <node>
               plain text 1
               <other_node />
               plain text2
           </node>
       </some>

you're pretty much out of luck when you want to change either of the texts, you have to replace the whole node.

This PR allows to say

      <wraptext expr="//some/node" position="text" element="span" />
      <wraptext expr="//some/node/other_node" position="tail" element="div" />

in inherited views, which transforms the above to

       <some>
           <node>
               <span>plain text 1</span>
               <other_node />
               <div>plain text2</div>
           </node>
       </some>

that you can further modify with the inheritance machinery

Copy link
Member

@StefanRijnhart StefanRijnhart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice one!

Copy link
Contributor

@NL66278 NL66278 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 LGTM and tests are comprehensive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants