File tree 6 files changed +62
-13
lines changed
6 files changed +62
-13
lines changed Original file line number Diff line number Diff line change
1
+ <!--
2
+ HTML/Template file: all-imports.html
3
+ purpose: Imports all elements for demo
4
+ Copyright(C) 2017 friendlyGIS GmbH,
5
+ Gerhard Höger-Hansen, Germany
6
+ http://www.friendlygis.com
7
+ info@friendlygis.com
8
+ https://github.com/GerhardHH
9
+ ----
10
+ Description:
11
+
12
+ -->
1
13
< link rel ="import " href ="./e2u-behaviors.html ">
2
14
< link rel ="import " href ="./e2u-json-object-editor.html ">
3
15
< link rel ="import " href ="./e2u-json-array-editor.html ">
Original file line number Diff line number Diff line change 1
1
<!--
2
- Defines behaviors usable for Energy2Use (namespace e2uBehaviors).
3
-
2
+ HTML/Template file: e2u-behaviors.html
3
+ purpose: Defines behaviors usable for Energy2Use (namespace e2uBehaviors)
4
+ Copyright(C) 2017 friendlyGIS GmbH,
5
+ Gerhard Höger-Hansen, Germany
6
+ http://www.friendlygis.com
7
+ info@friendlygis.com
8
+ https://github.com/GerhardHH
9
+ ----
10
+ Description:
4
11
Especially, holds methods to create GUI elements for the array
5
12
elements and helpers to handle the JSON schema.
6
-
7
-
8
-
9
13
-->
10
-
11
14
< script >
12
15
// initialize behavior namespace if it not yet exists
13
16
window . E2uBehaviors = window . E2uBehaviors || { } ;
Original file line number Diff line number Diff line change
1
+ <!--
2
+ HTML/Template file: e2u-json-array-editor.html
3
+ purpose: Edit array based on JSON schema
4
+ Copyright(C) 2017 friendlyGIS GmbH,
5
+ Gerhard Höger-Hansen, Germany
6
+ http://www.friendlygis.com
7
+ info@friendlygis.com
8
+ https://github.com/GerhardHH
9
+ ----
10
+ Description:
11
+ see below
12
+ -->
1
13
< link rel ="import " href ="../polymer/polymer.html ">
2
14
< link rel ="import " href ="../paper-input/paper-input.html " />
3
15
< link rel ="import " href ="../paper-icon-button/paper-icon-button.html " />
52
64
the index found, we do a splice on value which triggers a splice on objArray
53
65
which does the rest.
54
66
- while entering data, all flow is controlled via the _objArrayChanged(objArray.*)
55
- observer, updating the corresponding elements.
67
+ observer, updating the corresponding elements.
56
68
57
69
NOTE: The dependency mechanisms of Polymer do not support arrays of primitive
58
70
values like Strings etc. Therefore, if an array is defined as such, it is
Original file line number Diff line number Diff line change
1
+ <!--
2
+ HTML/Template file: e2u-json-object-editor.html
3
+ purpose: Polymer element to edit an object based on JSON Schema
4
+ Copyright(C) 2017 friendlyGIS GmbH,
5
+ Gerhard Höger-Hansen, Germany
6
+ http://www.friendlygis.com
7
+ info@friendlygis.com
8
+ https://github.com/GerhardHH
9
+ ----
10
+ Description:
11
+ see below.
12
+ -->
1
13
< link rel ="import " href ="../polymer/polymer.html ">
2
14
< link rel ="import " href ="../paper-input/paper-input.html " />
3
15
< link rel ="import " href ="../iron-flex-layout/iron-flex-layout-classes.html ">
Original file line number Diff line number Diff line change
1
+ <!--
2
+ HTML/Template file: e2u-test-editor.html
3
+ purpose: Provide test environment for demo
4
+ Copyright(C) 2017 friendlyGIS GmbH,
5
+ Gerhard Höger-Hansen, Germany
6
+ http://www.friendlygis.com
7
+ info@friendlygis.com
8
+ https://github.com/GerhardHH
9
+ ----
10
+ Description:
11
+ Simply provides schema and value data and uses the
12
+ e2u-json-object-editor to show it. Provides a text display
13
+ of the resulting object and buttons to update in both directions.
14
+ -->
1
15
< link rel ="import " href ="../polymer/polymer.html ">
2
16
3
17
< link rel ="import " href ="../iron-demo-helpers/demo-pages-shared-styles.html ">
138
152
notify : true ,
139
153
value : function ( ) {
140
154
return {
141
- "birthday" : "1962-12-31" ,
142
155
"company" : "friendlyGIS GmbH" ,
143
156
"name" : {
144
157
"firstName" : "Gerhard" ,
145
158
"lastName" : "Höger-Hansen"
146
159
} ,
147
160
"email" : "info@friendlygis.com" ,
148
- "phoneNumbers" : [ {
149
- "type" : "geschäftlich" ,
150
- "phoneNumber" : "+49 5241 942458"
151
- } ] ,
152
- "comment" : "Hier kann man\nmehrzeilige Eingaben\nmachen!"
161
+ "comment" : "This text uses paper-textarea thus\nallowing us\nmultiline data!"
153
162
} ;
154
163
}
155
164
} ,
Original file line number Diff line number Diff line change
1
+
1
2
<!doctype html>
2
3
< html >
3
4
< head >
You can’t perform that action at this time.
0 commit comments