Skip to content

Commit

Permalink
Updated a-frame to v1.03. Added getNodeName method to Gulper. Updated…
Browse files Browse the repository at this point in the history
… Vaadin addon version to 1.0.4
  • Loading branch information
Juho Piirainen authored and Juho Piirainen committed Jan 2, 2020
1 parent d5c0bd3 commit 664aac6
Show file tree
Hide file tree
Showing 38 changed files with 177 additions and 136 deletions.
226 changes: 126 additions & 100 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

<groupId>com.tsc.aframe</groupId>
<artifactId>aframe</artifactId>
<version>1.0.3</version>
<version>1.0.4</version>
<name>a-frame-vaadin</name>
<description>Integration of A-Frame for Vaadin platform</description>

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/Aentity.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-entity")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Aentity extends AFrameBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/Ascene.java
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-scene")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
/*
If you wish to include your own JS modules in the add-on jar, add the module
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/assets/Aassetitem.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-asset-item")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Aassetitem extends AFrameBase {
public Aassetitem() {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/assets/Aassets.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-assets")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
/*
If you wish to include your own JS modules in the add-on jar, add the module
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/assets/Audio.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("audio")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Audio extends AFrameBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/assets/Img.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("img")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Img extends AFrameBase implements IAframeBase {
public Img() {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/assets/Video.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("video")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Video extends AFrameBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/base/AFrameBase.java
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public AFrameBase addXml(String elementXml) {
AFrameBase aFrameBaseObj = Gulper.aFrameFactory(elementXml);
if ( aFrameBaseObj != null ) {
this.add(aFrameBaseObj);
}
}
return aFrameBaseObj;
}
}
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/camera/Acamera.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-camera")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Acamera extends AFrameBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/camera/Acursor.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-cursor")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Acursor extends AFrameBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Abox.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-box")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Abox extends AFramePrimitiveBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Acircle.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-circle")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Acircle extends AFramePrimitiveBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Acone.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-cone")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")

public class Acone extends AFramePrimitiveComplexBase {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Acurvedimage.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-curvedimage")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Acurvedimage extends AFrameMediaBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Acylinder.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-cylinder")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Acylinder extends AFramePrimitiveComplexBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Adodecahedron.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-dodecahedron")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Adodecahedron extends AFramePrimitiveComplexBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Agltfmodel.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-gltf-model")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")

public class Agltfmodel extends AFrameBase {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Aicosahedron.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-icosahedron")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Aicosahedron extends AFramePrimitiveBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Aimage.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-image")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Aimage extends AFrameMediaBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Alight.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-light")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Alight extends AFrameBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Alink.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-link")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Alink extends AFrameBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Aobjmodel.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-obj-model")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Aobjmodel extends AFrameBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Aoctahedron.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-octahedron")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Aoctahedron extends AFramePrimitiveBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Aplane.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-plane")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
/*
If you wish to include your own JS modules in the add-on jar, add the module
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Aring.java
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-ring")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
/*
If you wish to include your own JS modules in the add-on jar, add the module
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Asky.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-sky")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
/*
If you wish to include your own JS modules in the add-on jar, add the module
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Asound.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-sound")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Asound extends AFrameBase implements IAframeBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Asphere.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-sphere")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
/*
If you wish to include your own JS modules in the add-on jar, add the module
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Atetrahedron.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-tetrahedron")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Atetrahedron extends AFramePrimitiveBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Atext.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-text")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Atext extends AFrameBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Atorus.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-torus")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Atorus extends AFramePrimitiveBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Atorusknot.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-torus-knot")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Atorusknot extends AFramePrimitiveBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Atriangle.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-triangle")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Atriangle extends AFramePrimitiveBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Avideo.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-video")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Avideo extends AFrameMediaBase {

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/tsc/aframe/primitives/Avideosphere.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import com.vaadin.flow.component.dependency.NpmPackage;

@Tag("a-videosphere")
@JsModule("aframe/dist/aframe-v1.0.0.min.js")
@JsModule("aframe/dist/aframe-v1.0.3.min.js")
@NpmPackage(value = "aframe", version = "^1.0.0")
public class Avideosphere extends AFrameBase {

Expand Down
15 changes: 15 additions & 0 deletions src/main/java/com/tsc/aframe/utils/Gulper.java
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,21 @@ private static Document convertStringToXMLDocument(String xmlString) {
return null;
}

public static String getNodeName( String xmlString ) {
String nodeName = "unknown";

Document document = convertStringToXMLDocument(xmlString);

if ( document != null ) {
//Normalize the XML Structure; It's just too important !!
document.getDocumentElement().normalize();
//Here comes the root node
nodeName = document.getDocumentElement().getNodeName();
}

return nodeName;
}

public static AFrameBase aFrameFactory( String xmlString ) {

// Get root name
Expand Down

0 comments on commit 664aac6

Please sign in to comment.