Giter VIP home page Giter VIP logo

Comments (6)

RyanKing77 avatar RyanKing77 commented on May 12, 2024

Thanks for reporting this issue. If you would like to contribute a fix, please do so via a pull request. Otherwise, we will evaluate and prioritize the fix as appropriate.

from xliff2-object-model.

RyanKing77 avatar RyanKing77 commented on May 12, 2024

Upon further examination of the issue, this is by design. If you declare xml:space="preserve" then you will get the expected output. Perhaps you are expecting the default "processing mode" of the OM to be to preserve whitespace? In which case, this is not a bug but a design change.

from xliff2-object-model.

RyanKing77 avatar RyanKing77 commented on May 12, 2024

To clarify a bit more: this is the default behavior of the OM because it is based on .Net XmlReader/Writer which does not preserve by default.

from xliff2-object-model.

ysavourel avatar ysavourel commented on May 12, 2024

Looking more closely at the XML specification, I have to agree: default means the reader does whatever it wants. I had read it as: "The reader can normalize or preserve". But it seems that complete deletion is valid too.

So it's not a bug.

But I would change this as a request for a change in behavior. While remove spaces on outer content is fine, it seems that completely removing spaces in elements that are content like <source> and <target> is probably unwise. I would expect to either normalize or preserve whitespace there.

I'll also post a not to answer your email in the XLIFF list.

from xliff2-object-model.

RyanKing77 avatar RyanKing77 commented on May 12, 2024

Thanks for reporting this issue. If you would like to contribute a fix, please do so via a pull request. Otherwise, we will evaluate and prioritize the design change request appropriately.

from xliff2-object-model.

RyanKing77 avatar RyanKing77 commented on May 12, 2024

Fixed with the following commits
b0dadfe
08178a6

from xliff2-object-model.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.