示例#1
0
        public IXamlAstNode Transform(AstTransformationContext context, IXamlAstNode node)
        {
            if (node is XamlAstXamlPropertyValueNode propertyNode)
            {
                var childNodes = propertyNode.Values;
                WhitespaceNormalization.Apply(
                    childNodes,
                    context.Configuration
                    );

                var property = propertyNode.Property.GetClrProperty();
                if (!WantsWhitespaceOnlyElements(context.Configuration, property))
                {
                    WhitespaceNormalization.RemoveWhitespaceNodes(childNodes);
                }
            }

            return(node);
        }