Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support completion with xs:any #559

Merged
merged 1 commit into from
Aug 22, 2019
Merged

Support completion with xs:any #559

merged 1 commit into from
Aug 22, 2019

Conversation

angelozerr
Copy link
Contributor

@angelozerr
Copy link
Contributor Author

To test this PR, create

  • a XML Schema any.xsd with xs:any like this:
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
	targetNamespace="http://ui">
	<xs:element name="textbox"></xs:element>
	<xs:element name="page">
		<xs:complexType>
			<xs:sequence>				
				<xs:element name="title" />
				<xs:any processContents="strict" />
			</xs:sequence>			
		</xs:complexType>
	</xs:element>
</xs:schema>
  • XML file like this:
<ui:page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ui="http://ui" xsi:schemaLocation="http://ui any.xsd" >
    <title></title>
    |
    <a />
</ui:page>

Open completion after title, you should see:

  • ui:textbox
  • ui:page

In the xsd file, change to lax:

<xs:any processContents="lax"/>

Open completion after title, you should see:

  • ui:textbox
  • ui:page
  • title
  • a
    Here the demo:

XSAnyDemo

@NikolasKomonen
Copy link
Contributor

@angelozerr I've tested it, also with a second xsd file. It all works great. Should be good to go.

@angelozerr angelozerr merged commit 1e9835c into master Aug 22, 2019
@angelozerr
Copy link
Contributor Author

Thank a lot @NikolasKomonen !

@angelozerr angelozerr deleted the completion-xs-any branch August 22, 2019 16:12
@angelozerr angelozerr restored the completion-xs-any branch August 22, 2019 16:45
@angelozerr angelozerr deleted the completion-xs-any branch August 22, 2019 16:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants