Compare commits
	
		
			357 Commits
		
	
	
		
			open245
			...
			open-rjs-o
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
|   | 5bc30dbf2a | ||
|   | 71bd77caf4 | ||
|   | f275177aa6 | ||
|   | 05908aa877 | ||
|   | 9b5c62d2d5 | ||
|   | 297e6b00e1 | ||
|   | 848af50d4e | ||
|   | 97e93c3104 | ||
|   | 731cdb343a | ||
|   | d9664d4574 | ||
|   | 5a0e949b62 | ||
|   | 28a6eabfb6 | ||
|   | 6e43342157 | ||
|   | 6ce4c013d7 | ||
|   | 1272fb8509 | ||
|   | e84c88b8c0 | ||
|   | 3a8911e542 | ||
|   | 2a57b83cb0 | ||
|   | 29ecb68b9b | ||
|   | 5b0af8773b | ||
|   | 89a93e2966 | ||
|   | 038322e9aa | ||
|   | 6cef663db5 | ||
|   | b2f5861458 | ||
|   | f8809ce67f | ||
|   | 3c97eb6014 | ||
|   | 3498b0a50a | ||
|   | ed7e0d8b0a | ||
|   | f3828ba516 | ||
|   | 2a48c25453 | ||
|   | 096da0cb94 | ||
|   | ca8a07e1ae | ||
|   | c02f965460 | ||
|   | 5f440bb6de | ||
|   | fc729279ec | ||
|   | dd0f9ab74e | ||
|   | d2a4a85e04 | ||
|   | 37890280ae | ||
|   | a6ceae4045 | ||
|   | 3447e735dc | ||
|   | 989c937ce1 | ||
|   | e0608ddee0 | ||
|   | b35224061f | ||
|   | b25576aed8 | ||
|   | d5f054e328 | ||
|   | eb4959cf49 | ||
|   | cce415fc51 | ||
|   | 00f96c314a | ||
|   | fefd27162c | ||
|   | b388c76e45 | ||
|   | aaeaf3a096 | ||
|   | 57efe4e0d1 | ||
|   | dd4dbc9326 | ||
|   | 6aa77ff468 | ||
|   | f8099550bd | ||
|   | 96249e6bcc | ||
|   | 6e391098a3 | ||
|   | baec0f9719 | ||
|   | 6aab9f4e34 | ||
|   | 1bf73935e4 | ||
|   | 49e51d0a62 | ||
|   | 3e7bc2f37f | ||
|   | 0f56fd2561 | ||
|   | 9f0114eb39 | ||
|   | 4b82893c36 | ||
|   | 734e979c94 | ||
|   | 983973843e | ||
|   | 3b427c31a2 | ||
|   | cee0ecf0ef | ||
|   | 8e3c5db3bf | ||
|   | 11d8daf3ed | ||
|   | 9953e16415 | ||
|   | fe600de0f7 | ||
|   | 386f1f20ff | ||
|   | 5e07951892 | ||
|   | 2514e44083 | ||
|   | 20d9c7158e | ||
|   | d8e319ebf8 | ||
|   | a39cbbd917 | ||
|   | 8df27a1c05 | ||
|   | 26cf9c14f4 | ||
|   | 03edd26e17 | ||
|   | 571f6d183a | ||
|   | 1292e39c46 | ||
|   | 6fe3f82fb1 | ||
|   | da8fb99e82 | ||
|   | c8d77bc2db | ||
|   | b5e52fce75 | ||
|   | 3afcb52934 | ||
|   | 677b0cffec | ||
|   | 248bc68f0d | ||
|   | 02050fa3ef | ||
|   | 57d23c3696 | ||
|   | 8babfc5ca9 | ||
|   | 271b5d1a73 | ||
|   | 7d4e7a0925 | ||
|   | 92f5d5f190 | ||
|   | 1731b985fc | ||
|   | bd4590ad9d | ||
|   | 55fc60ec82 | ||
|   | ab075e9ad8 | ||
|   | 3ac1710d83 | ||
|   | 730878938e | ||
|   | 3fd4304de1 | ||
|   | db7224486c | ||
|   | 424953c894 | ||
|   | 6d0f3c7faa | ||
|   | 434a52ded3 | ||
|   | 2ec906e2d4 | ||
|   | ffff13205a | ||
|   | 16efd85dfc | ||
|   | 1ef09ffbdd | ||
|   | 976ecce075 | ||
|   | 87a51a9eb3 | ||
|   | c84de00e80 | ||
|   | 91997ced01 | ||
|   | 7a4be9e67e | ||
|   | eb942b0bf7 | ||
|   | 1cf23c7ad6 | ||
|   | 15ec9df538 | ||
|   | d6e2895666 | ||
|   | 7974ffdda2 | ||
|   | d5858622ba | ||
|   | 9656e09066 | ||
|   | 096fee8b6d | ||
|   | 0635e7c38e | ||
|   | 845b1dcd6f | ||
|   | 2e959e8503 | ||
|   | e6c9cbf0cd | ||
|   | fd3059b380 | ||
|   | 5a7349117a | ||
|   | 50134bbc7f | ||
|   | 3854df27d8 | ||
|   | fc53dbd8a4 | ||
|   | fb0ba0cff9 | ||
|   | 573e5608fc | ||
|   | 37a7c2b1df | ||
|   | 38274728f6 | ||
|   | 49b3d67272 | ||
|   | 400b992ec3 | ||
|   | de59f191b8 | ||
|   | 3d3b250536 | ||
|   | 32815d8427 | ||
|   | 3e25d17702 | ||
|   | b5d1118a3f | ||
|   | 5b9e43f8ff | ||
|   | 3ffa6f70aa | ||
|   | 0d07c3c289 | ||
|   | 29fdb6d641 | ||
|   | 39d007470a | ||
|   | 285c8cbd1e | ||
|   | a7f277b0d2 | ||
|   | 5ced8e655d | ||
|   | 4de7b7dfb5 | ||
|   | a9518e9890 | ||
|   | 4ed35cddde | ||
|   | 40b21e35fd | ||
|   | 3a36389815 | ||
|   | 606667eb4d | ||
|   | ef5a26dfcc | ||
|   | 8363302caf | ||
|   | 2b2ac0b0d9 | ||
|   | f9a7ca85ac | ||
|   | 46b110e12f | ||
|   | b7eb9491cb | ||
|   | a92d13c10f | ||
|   | 4ad007f882 | ||
|   | 9f2303face | ||
|   | 99512f41b9 | ||
|   | 49a5ac833b | ||
|   | 646df81874 | ||
|   | c5736cafb1 | ||
|   | 93d969ad67 | ||
|   | 7dc6f553ac | ||
|   | b30e72081c | ||
|   | d60bf94501 | ||
|   | a88fadcb49 | ||
|   | 7264a711a3 | ||
|   | ae7a1618e8 | ||
|   | d6d95fed19 | ||
|   | 04ce2f985a | ||
|   | a14f30c03c | ||
|   | bd85392b54 | ||
|   | 7c427e0b6e | ||
|   | 6cf8335f31 | ||
|   | 647a1403d0 | ||
|   | 1d9b8f34e2 | ||
|   | adf119007b | ||
|   | 7114e9b150 | ||
|   | 76c1f5bfe9 | ||
|   | 33f88d30ed | ||
|   | ffdcbece56 | ||
|   | 44eb723efb | ||
|   | 689f80bb23 | ||
|   | a2db98d275 | ||
|   | 49b983cd3a | ||
|   | ad60b9225e | ||
|   | 0c096db8bd | ||
|   | fdf6148811 | ||
|   | 62e7adc0b0 | ||
|   | 72e0304fc0 | ||
|   | e1110a2bc4 | ||
|   | 7172c45404 | ||
|   | d8ced8f635 | ||
|   | e3e44f74d6 | ||
|   | acdd9622d2 | ||
|   | 2866574dc0 | ||
|   | cfc9b61e25 | ||
|   | 066fd55590 | ||
|   | c0dc30edb7 | ||
|   | 2a201df435 | ||
|   | 07179f7290 | ||
|   | 87684e0945 | ||
|   | 55d3a27917 | ||
|   | 1d13b245f9 | ||
|   | e31d9decdc | ||
|   | a5fa11749c | ||
|   | 2b92c1619e | ||
|   | fd135a16af | ||
|   | aed49d89e3 | ||
|   | 05f8739952 | ||
|   | bf39aa1b1d | ||
|   | 4e79de6156 | ||
|   | 78004ebf37 | ||
|   | 51968954a9 | ||
|   | 64607b8e56 | ||
|   | cb432051dc | ||
|   | c184a9ce7c | ||
|   | 62e2114349 | ||
|   | cca1928b82 | ||
|   | 81b136eab1 | ||
|   | d059116782 | ||
|   | bdc99950c6 | ||
|   | 76e15f2963 | ||
|   | 06436bb876 | ||
|   | d8f3f0f430 | ||
|   | 177c1874b9 | ||
|   | 96a7c12d69 | ||
|   | 148a5eb248 | ||
|   | 31d3ec5d20 | ||
|   | 7564384b57 | ||
|   | 639546bf86 | ||
|   | 932e3cb7b0 | ||
|   | cbffc221fb | ||
|   | eef801f1ae | ||
|   | d69cf6c6fe | ||
|   | 0a9c162f26 | ||
|   | 942fa46022 | ||
|   | 74aff1b407 | ||
|   | 2f658348a8 | ||
|   | dbff9e2125 | ||
|   | 793ed7ebe6 | ||
|   | bed1556a3a | ||
|   | 822b4ae96f | ||
|   | 99f3b986b6 | ||
|   | fd4c1ea747 | ||
|   | 944a5a7424 | ||
|   | dda2c89a58 | ||
|   | c8cfbf5281 | ||
|   | 9f383ab101 | ||
|   | 063e97fcb5 | ||
|   | 7811d50372 | ||
|   | e1c6c76612 | ||
|   | aa2a835cb1 | ||
|   | 3741a02d2a | ||
|   | f14cad4a39 | ||
|   | c0ac3a0f96 | ||
|   | 09bae63de7 | ||
|   | 62b9eb5180 | ||
|   | 3f26be885e | ||
|   | 7ab318d57b | ||
|   | 65a33f8af5 | ||
|   | 331b4e9259 | ||
|   | 474afdf8ef | ||
|   | 3f4ccd93ab | ||
|   | 92cf86837b | ||
|   | 5274923c49 | ||
|   | a356e01b14 | ||
|   | 21a37db15b | ||
|   | a20bbd98f5 | ||
|   | 5b3f780204 | ||
|   | 43e920d3b6 | ||
|   | 8ca22cc510 | ||
|   | 3443780ac7 | ||
|   | 8e85675732 | ||
|   | 2bdc95eb95 | ||
|   | f2efb07d93 | ||
|   | 863c3f1720 | ||
|   | b73f9fc19e | ||
|   | 10e711f717 | ||
|   | 529dde57b9 | ||
|   | 7d1a1acc11 | ||
|   | 5e1b0f38b7 | ||
|   | 4e69ca50fb | ||
|   | 05481dcab5 | ||
|   | fa7131ad5c | ||
|   | bd1c3cb7da | ||
|   | cbd21212d1 | ||
|   | 5cd458a733 | ||
|   | 2f90a89065 | ||
|   | 4312857fd4 | ||
|   | 6c4c53dde7 | ||
|   | e49b55024f | ||
|   | 5f1f54fa91 | ||
|   | f4325e2bb3 | ||
|   | e09cf91def | ||
|   | ff1e1251f6 | ||
|   | 5697a39ec3 | ||
|   | 32fb84a3cd | ||
|   | e5aa2b4f87 | ||
|   | 522ce02302 | ||
|   | e32eb11e60 | ||
|   | bda1bf9f9a | ||
|   | 226f0932da | ||
|   | ac529be55c | ||
|   | 99376391a9 | ||
|   | c0ed19fd92 | ||
|   | df484c1800 | ||
|   | 5940f94644 | ||
|   | 7cd255670e | ||
|   | eabde6b2d0 | ||
|   | 37f466705a | ||
|   | 946a6d4a04 | ||
|   | 91a4138334 | ||
|   | f7f6b8d612 | ||
|   | e4a14b7603 | ||
|   | 5706fa4567 | ||
|   | 4eaeea1e14 | ||
|   | f44819a7fe | ||
|   | 05722d9b11 | ||
|   | 92a3fa3e4c | ||
|   | dd83662e0f | ||
|   | 9c90eb52a4 | ||
|   | e37fa75289 | ||
|   | ee314ab387 | ||
|   | d1bc93cd31 | ||
|   | 20cb2ff239 | ||
|   | 8acf01ebdf | ||
|   | ddb567aeb5 | ||
|   | a43c8f2ce8 | ||
|   | fffe07e7e6 | ||
|   | 26db524f0e | ||
|   | 4fcef33c58 | ||
|   | dc9369c0f1 | ||
|   | c5b786e5e0 | ||
|   | 3e0534c4c3 | ||
|   | 19ad4c8174 | ||
|   | 8159c365b5 | ||
|   | 307047d3ac | ||
|   | 83f135e48c | ||
|   | 6d08c81b3b | ||
|   | 89e763b515 | ||
|   | 2a1388772a | ||
|   | fa3821b50f | ||
|   | 8ce8080253 | ||
|   | 96f72b3765 | ||
|   | c932e953bc | 
							
								
								
									
										2
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							| @@ -28,3 +28,5 @@ node_modules | ||||
| # Protractor logs | ||||
| protractor/logs | ||||
|  | ||||
| # npm-debug log | ||||
| npm-debug.log | ||||
|   | ||||
| @@ -291,7 +291,7 @@ checklist.) | ||||
| 1. Changes address original issue? | ||||
| 2. Unit tests included and/or updated with changes? | ||||
| 3. Command line build passes? | ||||
| 4. Expect to pass code review? | ||||
| 4. Changes have been smoke-tested? | ||||
|  | ||||
| ### Reviewer Checklist | ||||
|  | ||||
|   | ||||
							
								
								
									
										35
									
								
								LICENSES.md
									
									
									
									
									
								
							
							
						
						
									
										35
									
								
								LICENSES.md
									
									
									
									
									
								
							| @@ -345,6 +345,41 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI | ||||
|  | ||||
| --- | ||||
|  | ||||
| ### moment-duration-format | ||||
|  | ||||
| #### Info | ||||
|  | ||||
| * Link: https://github.com/jsmreese/moment-duration-format | ||||
|  | ||||
| * Version: 1.3.0 | ||||
|  | ||||
| * Authors: John Madhavan-Reese | ||||
|  | ||||
| * Description: Duration parsing/formatting | ||||
|  | ||||
| #### License | ||||
|  | ||||
| Copyright 2014 John Madhavan-Reese | ||||
|  | ||||
| Permission is hereby granted, free of charge, to any person obtaining a copy of | ||||
| this software and associated documentation files (the "Software"), to deal in | ||||
| the Software without restriction, including without limitation the rights to | ||||
| use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of | ||||
| the Software, and to permit persons to whom the Software is furnished to do so, | ||||
| subject to the following conditions: | ||||
|  | ||||
| The above copyright notice and this permission notice shall be included in all | ||||
| copies or substantial portions of the Software. | ||||
|  | ||||
| THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||||
| IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS | ||||
| FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR | ||||
| COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER | ||||
| IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | ||||
| CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||||
|  | ||||
| --- | ||||
|  | ||||
| ### Json.NET | ||||
|  | ||||
| #### Info | ||||
|   | ||||
							
								
								
									
										58
									
								
								build.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										58
									
								
								build.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,58 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
|  | ||||
| /*global require*/ | ||||
| var requirejs = require("requirejs"), | ||||
|     globby = require("globby"), | ||||
|     fs = require("fs"), | ||||
|     bundles = fs.readFileSync("bundles.json", 'utf8'), | ||||
|     scripts = [], | ||||
|     templates = [], | ||||
|     contents, | ||||
|     index = fs.readFileSync("index.html", 'utf8'); | ||||
|  | ||||
| function trimJsExtension(filename) { | ||||
|     return filename.replace(/\.js$/, ""); | ||||
| } | ||||
|  | ||||
| JSON.parse(bundles).forEach(function (bundle) { | ||||
|     scripts = scripts.concat(globby.sync(bundle + "/src/**/*.js")); | ||||
| }); | ||||
|  | ||||
| requirejs.optimize({ | ||||
|     baseUrl: ".", | ||||
|     name: "main", | ||||
|     out: "target/main.js", | ||||
|     paths: { | ||||
|         'es6-promise': 'platform/framework/lib/es6-promise-2.0.0.min', | ||||
|         'moment': 'platform/telemetry/lib/moment.min', | ||||
|         'moment-duration-format': 'platform/features/clock/lib/moment-duration-format', | ||||
|         'uuid': 'platform/core/lib/uuid' | ||||
|     }, | ||||
|     shim: { | ||||
|         'moment-duration-format': { | ||||
|             deps: [ 'moment' ] | ||||
|         } | ||||
|     }, | ||||
|     include: scripts.map(trimJsExtension), | ||||
|     exclude: globby.sync("platform/framework/lib/**/*.js").map(trimJsExtension) | ||||
| }); | ||||
| @@ -15,19 +15,23 @@ | ||||
|     "platform/containment", | ||||
|     "platform/execution", | ||||
|     "platform/telemetry", | ||||
|     "platform/features/clock", | ||||
|     "platform/features/events", | ||||
|     "platform/features/imagery", | ||||
|     "platform/features/layout", | ||||
|     "platform/features/pages", | ||||
|     "platform/features/plot", | ||||
|     "platform/features/scrolling", | ||||
|     "platform/features/events", | ||||
|     "platform/features/timeline", | ||||
|     "platform/forms", | ||||
|     "platform/identity", | ||||
|     "platform/persistence/aggregator", | ||||
|     "platform/persistence/local", | ||||
|     "platform/persistence/queue", | ||||
|     "platform/policy", | ||||
|     "platform/entanglement", | ||||
|     "platform/search", | ||||
|     "platform/status", | ||||
|  | ||||
|     "example/imagery", | ||||
|     "example/eventGenerator", | ||||
|   | ||||
							
								
								
									
										9
									
								
								docs/footer.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								docs/footer.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | ||||
|         <hr> | ||||
|         <cite> | ||||
|             This document is styled using | ||||
|             <a href="https://github.com/jasonm23/markdown-css-themes"> | ||||
|                 https://github.com/jasonm23/markdown-css-themes | ||||
|             </a>. | ||||
|         </cite> | ||||
|     </body> | ||||
| </html> | ||||
| @@ -20,7 +20,7 @@ | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
|  | ||||
| /*global require,process,GLOBAL*/ | ||||
| /*global require,process,__dirname,GLOBAL*/ | ||||
| /*jslint nomen: false */ | ||||
|  | ||||
|  | ||||
| @@ -47,6 +47,8 @@ GLOBAL.window = GLOBAL.window ||  GLOBAL; // nomnoml expects window to be define | ||||
|         nomnoml = require('nomnoml'), | ||||
|         toc = require("markdown-toc"), | ||||
|         Canvas = require('canvas'), | ||||
|         header = fs.readFileSync(path.resolve(__dirname, 'header.html')), | ||||
|         footer = fs.readFileSync(path.resolve(__dirname, 'footer.html')), | ||||
|         options = require("minimist")(process.argv.slice(2)); | ||||
|  | ||||
|     // Convert from nomnoml source to a target PNG file. | ||||
| @@ -115,9 +117,9 @@ GLOBAL.window = GLOBAL.window ||  GLOBAL; // nomnoml expects window to be define | ||||
|             // Prepend table of contents | ||||
|             markdown = | ||||
|                 [ TOC_HEAD, toc(markdown).content, "", markdown ].join("\n"); | ||||
|             this.push("<html><body>\n"); | ||||
|             this.push(header); | ||||
|             this.push(marked(markdown)); | ||||
|             this.push("\n</body></html>\n"); | ||||
|             this.push(footer); | ||||
|             done(); | ||||
|         }; | ||||
|         return transform; | ||||
| @@ -186,12 +188,12 @@ GLOBAL.window = GLOBAL.window ||  GLOBAL; // nomnoml expects window to be define | ||||
|             var destination = file.replace(options['in'], options.out), | ||||
|                 destPath = path.dirname(destination), | ||||
|                 streamOptions = {}; | ||||
|             if (file.match(/png$/)){ | ||||
|             if (file.match(/png$/)) { | ||||
|                 streamOptions.encoding = null; | ||||
|             } else { | ||||
|                 streamOptions.encoding = 'utf8'; | ||||
|             } | ||||
|              | ||||
|  | ||||
|             mkdirp(destPath, function (err) { | ||||
|                 fs.createReadStream(file, streamOptions) | ||||
|                     .pipe(fs.createWriteStream(destination, streamOptions)); | ||||
|   | ||||
							
								
								
									
										7
									
								
								docs/header.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								docs/header.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,7 @@ | ||||
| <html> | ||||
|     <head> | ||||
|         <link rel="stylesheet" | ||||
|               href="http://jasonm23.github.io/markdown-css-themes/avenir-white.css"> | ||||
|     </head> | ||||
|     <body> | ||||
|  | ||||
| @@ -58,13 +58,13 @@ of the software. | ||||
|  | ||||
| These layers are: | ||||
|  | ||||
| * [_Framework_](Framework.md): The framework layer is responsible for | ||||
| * [_Framework_](framework.md): The framework layer is responsible for | ||||
|   managing the interactions between application components. It has no | ||||
|   application-specific knowledge; at this layer, we have only | ||||
|   established an abstraction by which different software components | ||||
|   may communicate and/or interact. | ||||
| * [_Platform_](Platform.md): The platform layer defines the general look, feel, and | ||||
|   behavior of Open MCT Web. This includes user-facing components like | ||||
| * [_Platform_](platform.md): The platform layer defines the general look,  | ||||
|   feel, and behavior of Open MCT Web. This includes user-facing components like | ||||
|   Browse mode and Edit mode, as well as underlying elements of the | ||||
|   information model and the general service infrastructure. | ||||
| * _Application_: The application layer defines specific features of | ||||
|   | ||||
| @@ -129,7 +129,7 @@ The framework's role in the application is to manage connections between | ||||
| bundles. All application-specific behavior is provided by individual bundles, or | ||||
| as the result of their collaboration. | ||||
|  | ||||
| The framework is described in more detail in the [Framework Overview](../architecture/Framework.md#Overview) of the  | ||||
| The framework is described in more detail in the [Framework Overview](../architecture/framework.md#overview) of the  | ||||
| architecture guide. | ||||
|  | ||||
| ### Tiers | ||||
| @@ -186,7 +186,8 @@ as well as the framework layer's role in mediating between these components. | ||||
| Once the framework layer has wired these software components together, however, | ||||
| the application's logical architecture emerges. | ||||
|  | ||||
| An overview of the logical architecture of the platform is given in the [Platform Architecture](../architecture/Platform.md#PlatformArchitecture)  | ||||
| An overview of the logical architecture of the platform is given in the  | ||||
| [Platform Architecture](../architecture/platform.md#platform-architecture)  | ||||
| section of the Platform guide | ||||
|  | ||||
| ### Web Services | ||||
| @@ -233,7 +234,7 @@ The application is composed of bundles. Plug-ins are bundles. | ||||
| non-persistent state associated with a domain object. | ||||
| * __category__: A machine-readable identifier for a group that something may  | ||||
| belong to. | ||||
| * __composition __: In the context of a domain object, this refers to the set of  | ||||
| * __composition__: In the context of a domain object, this refers to the set of  | ||||
| other domain objects that compose or are contained by that object. A domain  | ||||
| object's composition is the set of domain objects that should appear immediately | ||||
|  beneath it in a tree hierarchy. A domain object's composition is described in  | ||||
| @@ -244,10 +245,10 @@ identifiers asynchronously. | ||||
| readable description of a thing; usually a single sentence or short paragraph.  | ||||
| (Most often used in the context of extensions, domain object models, or other  | ||||
| similar application-specific objects.)  | ||||
| * __domain object __: A meaningful object to the user; a distinct thing in the  | ||||
| * __domain object__: A meaningful object to the user; a distinct thing in the  | ||||
| work support by Open MCT Web. Anything that appears in the left-hand tree is a  | ||||
| domain object.  | ||||
| * __extension __: An extension is a unit of functionality exposed to the platform  | ||||
| * __extension__: An extension is a unit of functionality exposed to the platform  | ||||
| in a declarative fashion by a bundle. The term 'extension category' is used to  | ||||
| distinguish types of extensions from specific extension instances.  | ||||
| * __id__: A string which uniquely identifies a domain object.  | ||||
| @@ -609,8 +610,8 @@ path relative to the bundle's resource directory (`res` by default.) | ||||
|  | ||||
| ### Composite Services | ||||
|  | ||||
| Composite services are described in the [relevant section](../architecture/Framework.md#Composite-Services)  | ||||
| of the framework guide. | ||||
| Composite services are described in the [Composite Services](../architecture/framework.md#composite-services)  | ||||
| section of the framework guide. | ||||
|  | ||||
| A component should include the following properties in its extension definition: | ||||
|  | ||||
| @@ -676,6 +677,40 @@ If the provided capability has no invoke method, the return value here functions | ||||
| as `getCapability` including returning `undefined` if the capability is not  | ||||
| exposed. | ||||
|  | ||||
| ### Identifier Syntax | ||||
|  | ||||
| For most purposes, a domain object identifier can be treated as a purely | ||||
| symbolic string; these are typically generated by Open MCT Web and plug-ins | ||||
| should rarely be concerned with its internal structure. | ||||
|  | ||||
| A domain object identifier has one or two parts, separated by a colon. | ||||
|  | ||||
| * If two parts are present, the part before the colon refers to the space | ||||
|   in which the domain object resides. This may be a persistence space or | ||||
|   a purely symbolic space recognized by a specific model provider. The | ||||
|   part after the colon is the key to use when looking up the domain object | ||||
|   model within that space. | ||||
| * If only one part is present, the domain object has no space specified, | ||||
|   and may presume to reside in the application-configured default space | ||||
|   defined by the `PERSISTENCE_SPACE` constant. | ||||
| * Both the key and the space identifier may consist of any combination | ||||
|   of alphanumeric characters, underscores, dashes, and periods. | ||||
|  | ||||
| Some examples: | ||||
|  | ||||
| * A domain object with the identifier `foo:xyz` would have its model | ||||
|   loaded using key `xyz` from persistence space `foo`. | ||||
| * A domain object with the identifier `bar` would have its model loaded | ||||
|   using key `bar` from the space identified by the `PERSISTENCE_SPACE` | ||||
|   constant. | ||||
|  | ||||
| ```bnf | ||||
| <identifier> ::= <space> ":" <key> | <key> | ||||
| <space> ::= <id char>+ | ||||
| <key> ::= <id char>+ | ||||
| <id char> ::= <letter> | <digit> | "-" | "." | "_" | ||||
| ``` | ||||
|  | ||||
| ## Domain Object Actions | ||||
|  | ||||
| An `Action` is behavior that can be performed upon/using a `DomainObject`. An  | ||||
| @@ -724,8 +759,8 @@ interpretations for specific sources. | ||||
|  | ||||
| ### Telemetry Responses | ||||
|  | ||||
| When returned from the `telemetryService` (see [Services](#Services) section),  | ||||
| telemetry series data will be packaged in a `source -> key -> TelemetrySeries`  | ||||
| When returned from the `telemetryService` (see [Telemetry Services](#telemetry-service)  | ||||
| section), telemetry series data will be packaged in a `source -> key -> TelemetrySeries`  | ||||
| fashion. That is, telemetry is passed in an object containing key-value pairs.  | ||||
| Keys identify telemetry sources; values are objects containing additional  | ||||
| key-value pairs. In this object, keys identify individual telemetry series (and  | ||||
| @@ -906,6 +941,12 @@ look at field  (see below) to determine which field in the model should be | ||||
| modified.  | ||||
| * `ngRequired`: True if input is required. | ||||
| * `ngPattern`: The pattern to match against (for text entry) | ||||
| * `ngBlur`: A function that may be invoked to evaluate the expression | ||||
|   associated with the `ng-blur` attribute associated with the control. | ||||
|   * This should be called when the control has lost focus; for controls | ||||
|     which simply wrap or augment `input` elements, this should be fired | ||||
|     on `blur` events associated with those elements, while more complex | ||||
|     custom controls may fire this at the end of more specific interactions. | ||||
| * `options`: The options for this control, as passed from the `options` property  | ||||
| of an individual row definition.  | ||||
| * `field`: Name of the field in `ngModel` which will hold the value for this  | ||||
| @@ -1042,7 +1083,7 @@ Angular templates which need to interact with information (e.g. the domain | ||||
| object being represented) provided by the platform. This information is passed  | ||||
| in through the template's scope, such that simple representations may be created  | ||||
| by providing only templates. (More complex representations will need controllers  | ||||
| which are referenced from templates. See [https://docs.angularjs.org/guide/controller ]() | ||||
| which are referenced from templates. See https://docs.angularjs.org/guide/controller | ||||
| for more information on controllers in Angular.)  | ||||
|   | ||||
| A representation's scope will contain: | ||||
| @@ -1074,7 +1115,7 @@ representing domain objects in general. For example, support for the  _gestures_ | ||||
| extension category is added by a _representer_. | ||||
|  | ||||
| A representer needs only provide an implementation. When an `mct-representation`  | ||||
| is linked (see  [https://docs.angularjs.org/guide/directive ]() or when the  | ||||
| is linked (see https://docs.angularjs.org/guide/directive ) or when the  | ||||
| domain object being represented changes, a new _representer_ of each declared  | ||||
| type is instantiated. The constructor arguments for a _representer_ are the same  | ||||
| as the arguments to the link function in an Angular directive: `scope` the  | ||||
| @@ -1106,6 +1147,8 @@ property: | ||||
| * `stylesheetUrl`: Path and filename, including extension, for the stylesheet to  | ||||
| include. This path is relative to the bundle's resources folder (by default,   | ||||
| `res`)  | ||||
| * `theme`: Optional; if present, this stylesheet will only be included if this | ||||
| value matches the `THEME` constant. | ||||
|   | ||||
| To control the order of CSS files, use priority  (see the section on Extension  | ||||
| Definitions above.)  | ||||
| @@ -1155,7 +1198,7 @@ capability. | ||||
| (as should appear in the _Create_ or the _Edit Properties_ dialog.) Each  | ||||
| property is described by an object containing the following properties: | ||||
|     * `control`: The key of the control (see `mct-control` and the `controls`  | ||||
|     [extension category](#Controls)) to use for editing this property.  | ||||
|     [extension category](#controls-category)) to use for editing this property.  | ||||
|     * `property`: A string which will be used as the name of the property in the  | ||||
|     domain object's model that the value for this property should be stored  | ||||
|     under. If this value should be stored in an object nested within the domain  | ||||
| @@ -1178,7 +1221,7 @@ the list of version information in the About dialog. | ||||
| dialog. | ||||
|  | ||||
| To control the ordering of line items within the About dialog, use `priority`.  | ||||
| (See section on [Extension Definitions](#ExtensionDefinitions) above.)  | ||||
| (See section on [Extensions](#extensions) above.)  | ||||
|  | ||||
| This extension category does not have implementations.  | ||||
|   | ||||
| @@ -1200,7 +1243,7 @@ applicable for domain objects which have the capabilities identified by these | ||||
| strings.  | ||||
| * `delegation`: Optional boolean, intended to be used in conjunction with   | ||||
| `needs`;  if present, allow required capabilities to be satisfied by means of  | ||||
| capability delegation. (See [Delegation](#Delegation)) | ||||
| capability delegation. (See [Delegation](#delegation-capability)) | ||||
| * `toolbar`: Optional; a definition for the toolbar which may appear in a  | ||||
| toolbar when using this view in Edit mode. This should be specified as a  | ||||
| structure for mct-toolbar , with additional properties available for each item in  | ||||
| @@ -1231,8 +1274,8 @@ A view's selection state is, conceptually, a set of JavaScript objects. The | ||||
| presence of methods/properties on these objects determine which toolbar controls  | ||||
| are visible, and what state they manage and/or behavior they invoke.  | ||||
|  | ||||
| This set may contain up to two different objects: The  _view proxy _, which is  | ||||
| used to make changes to the view as a whole, and the _ selected object _, which is  | ||||
| This set may contain up to two different objects: The  _view proxy_, which is  | ||||
| used to make changes to the view as a whole, and the _selected object_, which is  | ||||
| used to represent some state within the view. (Future versions of Open MCT Web  | ||||
| may support multiple selected objects.)  | ||||
|  | ||||
| @@ -1251,6 +1294,22 @@ object, or the current view proxy. | ||||
| * `all()`: Get an array of all objects in the selection state. Will include  | ||||
| either or both of the view proxy and selected object.  | ||||
|  | ||||
| ## Workers Category | ||||
|  | ||||
| The `workers` extension category allows scripts to be run as web workers | ||||
| using the `workerService`. | ||||
|  | ||||
| An extension of this category has no implementation. The following properties | ||||
| are supported: | ||||
|  | ||||
| * `key`: A symbolic string used to identify this worker. | ||||
| * `workerUrl`: The path, relative to this bundle's `src` folder, where | ||||
|   this worker's source code resides. | ||||
| * `shared`: Optional; a boolean flag which, if true, indicates that this | ||||
|   worker should be instantiated as a | ||||
|   [`SharedWorker`](https://developer.mozilla.org/en-US/docs/Web/API/SharedWorker/SharedWorker). | ||||
|   Default value is `false`. | ||||
|  | ||||
| # Directives | ||||
|  | ||||
| Open MCT Web defines several Angular directives that are intended for use both  | ||||
| @@ -1561,7 +1620,8 @@ extension mechanism is insufficient to achieve a desired result. | ||||
|   | ||||
| ### Action Service | ||||
|  | ||||
| The [Action Service](../architecture/platform#action-service) (`actionService`)  | ||||
| The [Action Service](../architecture/platform.md#action-service)  | ||||
| (`actionService`)  | ||||
| provides `Action` instances which are applicable in specific contexts. See Core  | ||||
| API for additional notes on the interface for actions. The `actionService` has  | ||||
| the following interface:  | ||||
| @@ -1571,7 +1631,8 @@ in the specified action context. | ||||
|  | ||||
| ### Capability Service  | ||||
|  | ||||
| The [Capability Service](../architecture/platform#capability-service) (`capabilityService`)  | ||||
| The [Capability Service](../architecture/platform.md#capability-service)  | ||||
| (`capabilityService`)  | ||||
| provides constructors for capabilities which will be exposed for a given domain  | ||||
| object.  | ||||
|  | ||||
| @@ -1691,7 +1752,7 @@ allowed within the application. It has the following interface: | ||||
| * `allow(category, candidate, context, [callback])`: Check if this decision  | ||||
| should be allowed. Returns a boolean. Its arguments are interpreted as:  | ||||
|     * `category`: A string identifying which kind of decision is being made. See  | ||||
|     the [section on Categories](#PolicyCategories) for categories supported by  | ||||
|     the [section on Categories](#policy-categories) for categories supported by  | ||||
|     the platform; plugins may define and utilize policies of additional  | ||||
|     categories, as well.  | ||||
|     * `candidate`: An object representing the thing which shall or shall not be  | ||||
| @@ -1717,7 +1778,7 @@ When acquiring telemetry for display, it is recommended that the | ||||
| `telemetryHandler` service be used instead of this service. The  | ||||
| `telemetryHandler` has additional support for subscribing to and requesting  | ||||
| telemetry data associated with domain objects or groups of domain objects. See  | ||||
| the [Other Services](#Other-Services) section for more information.  | ||||
| the [Other Services](#other-services) section for more information.  | ||||
|  | ||||
| The `telemetryService` has the following interface: | ||||
|  | ||||
| @@ -1844,6 +1905,14 @@ the TelemetrySeries itself, in that order. | ||||
| * `getSeries(domainObject)`: Get the latest `TelemetrySeries` (as resulted from  | ||||
| a previous `request(...)` call) available for this domain object. | ||||
|  | ||||
| ### Worker Service | ||||
|  | ||||
| The `workerService` may be used to run web workers defined via the | ||||
| `workers` extension category. It has the following method: | ||||
|  | ||||
| * `run(key)`: Run the worker identified by the provided `key`. Returns | ||||
|   a `Worker` (or `SharedWorker`, if the specified worker is defined | ||||
|   as a shared worker); if the `key` is unknown, returns `undefined`. | ||||
|  | ||||
| # Models | ||||
| Domain object models in Open MCT Web are JavaScript objects describing the  | ||||
| @@ -2051,6 +2120,31 @@ objects which has a `relationships` property in their model, whose value is an | ||||
| object containing key-value pairs, where keys are strings identifying  | ||||
| relationship types, and values are arrays of domain object identifiers. | ||||
|  | ||||
| ## Status Capability | ||||
|  | ||||
| The `status` capability provides a way to flag domain objects as possessing | ||||
| certain states, represented as simple strings. These states, in turn, are | ||||
| reflected on `mct-representation` elements as classes (prefixed with | ||||
| `s-status-`.) The `status` capability has the following interface: | ||||
|  | ||||
| * `get()`: Returns an array of all status strings that currently apply | ||||
|   to this object. | ||||
| * `set(status, state)`: Adds or removes a status flag to this domain object. | ||||
|   The `status` argument is the string to set; `state` is a boolean | ||||
|   indicating whether this status should be included (true) or removed (false). | ||||
| * `listen(callback)`: Listen for changes in status. The provided `callback` | ||||
|   will be invoked with an array of all current status strings whenever status | ||||
|   changes. | ||||
|  | ||||
| Plug-ins may add and/or recognize arbitrary status flags. Flags defined | ||||
| and/or supported by the platform are: | ||||
|  | ||||
|  Status    | CSS Class          | Meaning | ||||
| -----------|--------------------|----------------------------------- | ||||
| `editing`  | `s-status-editing` | Domain object is being edited. | ||||
| `pending`  | `s-status-pending` | Domain object is partially loaded. | ||||
|  | ||||
|  | ||||
| ## Telemetry Capability | ||||
|  | ||||
| The telemetry capability provides a means for accessing telemetry data  | ||||
| @@ -2151,8 +2245,8 @@ options. The sources can be deployed in the same directory structure used during | ||||
| development. A few utilities are included to support development processes. | ||||
|  | ||||
| ## Command-line Build | ||||
| Open MCT Web includes a script for building via command line using Maven 3.0.4  | ||||
| [https://maven.apache.org/](). | ||||
| Open MCT Web includes a script for building via command line using Maven 3.3.9 | ||||
| https://maven.apache.org/ . | ||||
|          | ||||
| Invoking mvn clean install will: | ||||
|  | ||||
| @@ -2169,7 +2263,7 @@ download build dependencies. | ||||
|  | ||||
| ## Test Suite | ||||
|  | ||||
| Open MCT Web uses Jasmine [http://jasmine.github.io/]() for automated testing.  | ||||
| Open MCT Web uses Jasmine http://jasmine.github.io/ for automated testing.  | ||||
| The file `test.html` included at the top level of the source repository, can be  | ||||
| run from the browser to perform tests for all active bundles, as defined in  | ||||
| `bundle.json`. | ||||
| @@ -2260,30 +2354,30 @@ Examples of deployment strategies (and the conditions under which they make the | ||||
| most sense) include: | ||||
|  | ||||
| * If the external services that Open MCT Web will utilize are all running on  | ||||
| Apache Tomcat [https://tomcat.apache.org/](), then it makes sense to run Open  | ||||
| [Apache Tomcat](https://tomcat.apache.org/), then it makes sense to run Open  | ||||
| MCT Web from the same Tomcat instance as a separate web application. The  | ||||
| `.war` artifact produced by the command line build facilitates this deployment  | ||||
| option. (See [https://tomcat.apache.org/tomcat-8.0-doc/deployer-howto.html() for  | ||||
| option. (See https://tomcat.apache.org/tomcat-8.0-doc/deployer-howto.html for  | ||||
| general information on deploying in Tomcat.) | ||||
| * If a variety of external services will be running from a variety of  | ||||
| hosts/ports, then it may make sense to use a web server that supports proxying,  | ||||
| such as the Apache HTTP Server [http://httpd.apache.org/](). In this  | ||||
| such as the [Apache HTTP Server](http://httpd.apache.org/). In this  | ||||
| configuration, the HTTP server would be configured to proxy (or reverse proxy)  | ||||
| requests at specific paths to the various external services, while providing  | ||||
| Open MCT Web as flat files from a different path. | ||||
| * If a single server component is being developed to handle all server-side  | ||||
| needs of an Open MCT Web instance, it can make sense to serve Open MCT Web (as  | ||||
| flat files) from the same component using an embedded HTTP server such as Nancy  | ||||
| [http://nancyfx.org/](). | ||||
| flat files) from the same component using an embedded HTTP server such as  | ||||
| [Nancy](http://nancyfx.org/). | ||||
| * If no external services are needed (or if the 'external services' will just  | ||||
| be generating flat files to read) it makes sense to utilize a lightweight flat  | ||||
| file HTTP server such as Lighttpd [http://www.lighttpd.net/](). In this  | ||||
| file HTTP server such as [Lighttpd](http://www.lighttpd.net/). In this  | ||||
| configuration, Open MCT Web sources/resources would be placed at one path, while  | ||||
| the files generated by the external service are placed at another path. | ||||
| * If all external services support CORS, it may make sense to have an HTTP  | ||||
| server that is solely responsible for making Open MCT Web sources/resources  | ||||
| available, and to have Open MCT Web contact these external services directly.  | ||||
| Again, lightweight HTTP servers such as Lighttpd [http://www.lighttpd.net/]()  | ||||
| Again, lightweight HTTP servers such as [Lighttpd](http://www.lighttpd.net/)  | ||||
| are useful in this circumstance. The downside of this option is that additional  | ||||
| configuration effort is required, both to enable CORS on the external services,  | ||||
| and to ensure that Open MCT Web can correctly locate these services. | ||||
| @@ -2323,7 +2417,17 @@ default paths to reach external services are all correct. | ||||
|  | ||||
| ### Configuration Constants | ||||
|  | ||||
| The following constants have global significance: | ||||
| * `PERSISTENCE_SPACE`: The space in which domain objects should be persisted | ||||
|   (or read from) when not otherwise specified. Typically this will not need | ||||
|   to be overridden by other bundles, but persistence adapters may wish to | ||||
|   consume this constant in order to provide persistence for that space. | ||||
|  | ||||
| The following configuration constants are recognized by Open MCT Web bundles: | ||||
| * Common UI elements - `platform/commonUI/general` | ||||
|     * `THEME`: A string identifying the current theme symbolically. Individual | ||||
|     stylesheets (the `stylesheets` extension category) may specify an optional | ||||
|     `theme` property which will be matched against this before inclusion. | ||||
| * CouchDB adapter - `platform/persistence/couch` | ||||
|     * `COUCHDB_PATH`: URL or path to the CouchDB database to be used for domain  | ||||
|     object persistence. Should not include a trailing slash. | ||||
|   | ||||
| @@ -32,6 +32,7 @@ | ||||
|         <li><a href="architecture/">Architecture Overview</a></li> | ||||
|         <li><a href="guide/">Developer Guide</a></li> | ||||
|         <li><a href="tutorials/">Tutorials</a></li> | ||||
|         <li><a href="process/">Development Process</a></li> | ||||
|     </ul> | ||||
| </body> | ||||
| </html> | ||||
|   | ||||
							
								
								
									
										161
									
								
								docs/src/process/cycle.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										161
									
								
								docs/src/process/cycle.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,161 @@ | ||||
| # Development Cycle | ||||
|  | ||||
| Development of Open MCT Web occurs on an iterative cycle of | ||||
| sprints and releases. | ||||
|  | ||||
| * A _sprint_ is three weeks in duration, and represents a | ||||
|   set of improvements that can be completed and tested by the | ||||
|   development team. Software at the end of the sprint is | ||||
|   "semi-stable"; it will have undergone reduced testing and may carry | ||||
|   defects or usability issues of lower severity, particularly if | ||||
|   there are workarounds. | ||||
| * A _release_ occurs every four sprints. Releases are stable, and | ||||
|   will have undergone full acceptance testing to ensure that the | ||||
|   software behaves correctly and usably. | ||||
|  | ||||
| ## Roles | ||||
|  | ||||
| The sprint process assumes the presence of a __project manager.__ | ||||
| The project manager is responsible for | ||||
| making tactical decisions about what development work will be | ||||
| performed, and for coordinating with stakeholders to arrive at | ||||
| higher-level strategic decisions about desired functionality | ||||
| and characteristics of the software, major external milestones, | ||||
| and so forth. | ||||
|  | ||||
| In the absence of a dedicated project manager, this role may be rotated | ||||
| among members of the development team on a per-sprint basis. | ||||
|  | ||||
| Responsibilities of the project manager including: | ||||
|  | ||||
| * Maintaining (with agreement of stakeholders) a "road map" of work | ||||
|   planned for future releases/sprints; this should be higher-level, | ||||
|   usually expressed as "themes", | ||||
|   with just enough specificity to gauge feasibility of plans, | ||||
|   relate work back to milestones, and identify longer-term | ||||
|   dependencies. | ||||
| * Determining (with assistance from the rest of the team) which | ||||
|   issues to work on in a given sprint and how they shall be | ||||
|   assigned. | ||||
| * Pre-planning subsequent sprints to ensure that all members of the | ||||
|   team always have a clear direction. | ||||
| * Scheduling and/or ensuring adherence to | ||||
|   [process points](#process-points). | ||||
| * Responding to changes within the sprint (shifting priorities, | ||||
|   new issues) and re-allocating work for the sprint as needed. | ||||
|  | ||||
| ## Sprint Calendar | ||||
|  | ||||
| Certain [process points](#process-points) are regularly scheduled in | ||||
| the sprint cycle. | ||||
|  | ||||
| ### Sprints by Release | ||||
|  | ||||
| Allocation of work among sprints should be planned relative to release | ||||
| goals and milestones. As a general guideline, higher-risk work (large | ||||
| new features which may carry new defects, major refactoring, design | ||||
| changes with uncertain effects on usability) should be allocated to | ||||
| earlier sprints, allowing for time in later sprints to ensure stability. | ||||
|  | ||||
| | Sprint | Focus                                                   | | ||||
| |:------:|:--------------------------------------------------------| | ||||
| | __1__  | Prototyping, design, experimentation.                   | | ||||
| | __2__  | New features, refinements, enhancements.                | | ||||
| | __3__  | Feature completion, low-risk enhancements, bug fixing.  | | ||||
| | __4__  | Stability & quality assurance.                          | | ||||
|  | ||||
| ### Sprints 1-3 | ||||
|  | ||||
| The first three sprints of a release are primarily centered around | ||||
| development work, with regular acceptance testing in the third | ||||
| week. During this third week, the top priority should be passing | ||||
| acceptance testing (e.g. by resolving any blockers found); any | ||||
| resources not needed for this effort should be used to begin work | ||||
| for the subsequent sprint. | ||||
|  | ||||
| | Week  | Mon                       | Tue    | Wed | Thu                          | Fri         | | ||||
| |:-----:|:-------------------------:|:------:|:---:|:----------------------------:|:-----------:| | ||||
| | __1__ | Sprint plan               | Tag-up |     |                              |             | | ||||
| | __2__ |                           | Tag-up |     |                              | Code freeze | | ||||
| | __3__ | Per-sprint testing        | Triage |     | _Per-sprint testing*_        | Ship        | | ||||
|  | ||||
| * If necessary. | ||||
|  | ||||
| ### Sprint 4 | ||||
|  | ||||
| The software must be stable at the end of the fourth sprint; because of | ||||
| this, the fourth sprint is scheduled differently, with a heightened | ||||
| emphasis on testing. | ||||
|  | ||||
| | Week   | Mon                       | Tue    | Wed | Thu                          | Fri         | | ||||
| |-------:|:-------------------------:|:------:|:---:|:----------------------------:|:-----------:| | ||||
| | __1__  | Sprint plan               | Tag-up |     |                              | Code freeze | | ||||
| | __2__  | Per-release testing       | Triage |     |                              |             | | ||||
| | __3__  | _Per-release testing*_    | Triage |     | _Per-release testing*_       | Ship        | | ||||
|  | ||||
| * If necessary. | ||||
|  | ||||
| ## Process Points | ||||
|  | ||||
| * __Sprint plan.__ Project manager allocates issues based on | ||||
|   theme(s) for sprint, then reviews with team. Each team member | ||||
|   should have roughly two weeks of work allocated (to allow time | ||||
|   in the third week for testing of work completed.) | ||||
|   * Project manager should also sketch out subsequent sprint so | ||||
|     that team may begin work for that sprint during the | ||||
|     third week, since testing and blocker resolution is unlikely | ||||
|     to require all available resources. | ||||
| * __Tag-up.__ Check in and status update among development team. | ||||
|   May amend plan for sprint as-needed. | ||||
| * __Code freeze.__ Any new work from this sprint | ||||
|   (features, bug fixes, enhancements) must be integrated by the | ||||
|   end of the second week of the sprint. After code freeze | ||||
|   (and until the end of the sprint) the only changes that should be | ||||
|   merged into the master branch should directly address issues | ||||
|   needed to pass acceptance testing. | ||||
| * [__Per-release Testing.__](testing/plan.md#per-release-testing) | ||||
|   Structured testing with predefined | ||||
|   success criteria. No release should ship without passing | ||||
|   acceptance tests. Time is allocated in each sprint for subsequent | ||||
|   rounds of acceptance testing if issues are identified during a | ||||
|   prior round. Specific details of acceptance testing need to be | ||||
|   agreed-upon with relevant stakeholders and delivery recipients, | ||||
|   and should be flexible enough to allow changes to plans | ||||
|   (e.g. deferring delivery of some feature in order to ensure | ||||
|   stability of other features.) Baseline testing includes: | ||||
|   * [__Testathon.__](testing/plan.md#user-testing) | ||||
|     Multi-user testing, involving as many users as | ||||
|     is feasible, plus development team. Open-ended; should verify | ||||
|     completed work from this sprint, test exploratorily for | ||||
|     regressions, et cetera. | ||||
|   * [__Long-Duration Test.__](testing/plan.md#long-duration-testing) A | ||||
|     test to verify that the software remains | ||||
|     stable after running for longer durations. May include some | ||||
|     combination of automated testing and user verification (e.g. | ||||
|     checking to verify that software remains subjectively | ||||
|     responsive at conclusion of test.) | ||||
|   * [__Unit Testing.__](testing/plan.md#unit-testing) | ||||
|     Automated testing integrated into the | ||||
|     build. (These tests are verified to pass more often than once | ||||
|     per sprint, as they run before any merge to master, but still | ||||
|     play an important role in per-release testing.) | ||||
| * [__Per-sprint Testing.__](testing/plan.md#per-sprint-testing) | ||||
|   Subset of Pre-release Testing | ||||
|   which should be performed before shipping at the end of any | ||||
|   sprint. Time is allocated for a second round of | ||||
|   Pre-release Testing if the first round is not passed. | ||||
| * __Triage.__ Team reviews issues from acceptance testing and uses | ||||
|   success criteria to determine whether or not they should block | ||||
|   release, then formulates a plan to address these issues before | ||||
|   the next round of acceptance testing. Focus here should be on | ||||
|   ensuring software passes that testing in order to ship on time; | ||||
|   may prefer to disable malfunctioning components and fix them | ||||
|   in a subsequent sprint, for example. | ||||
| * __Ship.__ Tag a code snapshot that has passed acceptance | ||||
|   testing and deploy that version. (Only true if acceptance | ||||
|   testing has passed by this point; if acceptance testing has not | ||||
|   been passed, will need to make ad hoc decisions with stakeholders, | ||||
|   e.g. "extend the sprint" or "defer shipment until end of next | ||||
|   sprint.") | ||||
|  | ||||
|  | ||||
							
								
								
									
										13
									
								
								docs/src/process/index.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								docs/src/process/index.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,13 @@ | ||||
| # Development Process | ||||
|  | ||||
| The process used to develop Open MCT Web is described in the following | ||||
| documents: | ||||
|  | ||||
| * [Development Cycle](cycle.md): Describes how and when specific | ||||
|   process points are repeated during development. | ||||
| * Testing is described in two documents: | ||||
|   * The [Test Plan](testing/plan.md) summarizes the approaches used | ||||
|     to test Open MCT Web. | ||||
|   * The [Test Procedures](testing/procedures.md) document what | ||||
|     specific tests are performed to verify correctness, and how | ||||
|     they should be carried out. | ||||
							
								
								
									
										127
									
								
								docs/src/process/testing/plan.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										127
									
								
								docs/src/process/testing/plan.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,127 @@ | ||||
| # Test Plan | ||||
|  | ||||
| ## Test Levels | ||||
|  | ||||
| Testing for Open MCT Web includes: | ||||
|  | ||||
| * _Smoke testing_: Brief, informal testing to verify that no major issues | ||||
|   or regressions are present in the software, or in specific features of | ||||
|   the software. | ||||
| * _Unit testing_: Automated verification of the performance of individual | ||||
|   software components. | ||||
| * _User testing_: Testing with a representative user base to verify | ||||
|   that application behaves usably and as specified. | ||||
| * _Long-duration testing_: Testing which takes place over a long period | ||||
|   of time to detect issues which are not readily noticeable during | ||||
|   shorter test periods. | ||||
|  | ||||
| ### Smoke Testing | ||||
|  | ||||
| Manual, non-rigorous testing of the software and/or specific features | ||||
| of interest. Verifies that the software runs and that basic functionality | ||||
| is present. | ||||
|  | ||||
| ### Unit Testing | ||||
|  | ||||
| Unit tests are automated tests which exercise individual software | ||||
| components. Tests are subject to code review along with the actual | ||||
| implementation, to ensure that tests are applicable and useful. | ||||
|  | ||||
| Unit tests should meet | ||||
| [test standards](https://github.com/nasa/openmctweb/blob/master/CONTRIBUTING.md#test-standards) | ||||
| as described in the contributing guide. | ||||
|  | ||||
| ### User Testing | ||||
|  | ||||
| User testing is performed at scheduled times involving target users | ||||
| of the software or reasonable representatives, along with members of | ||||
| the development team exercising known use cases. Users test the | ||||
| software directly; the software should be configured as similarly to | ||||
| its planned production configuration as is feasible without introducing | ||||
| other risks (e.g. damage to data in a production instance.) | ||||
|  | ||||
| User testing will focus on the following activities: | ||||
|  | ||||
| * Verifying issues resolved since the last test session. | ||||
| * Checking for regressions in areas related to recent changes. | ||||
| * Using major or important features of the software, | ||||
|   as determined by the user. | ||||
| * General "trying to break things." | ||||
|  | ||||
| During user testing, users will | ||||
| [report issues](https://github.com/nasa/openmctweb/blob/master/CONTRIBUTING.md#issue-reporting) | ||||
| as they are encountered. | ||||
|  | ||||
| Desired outcomes of user testing are: | ||||
|  | ||||
| * Identified software defects. | ||||
| * Areas for usability improvement. | ||||
| * Feature requests (particularly missed requirements.) | ||||
| * Recorded issue verification. | ||||
|  | ||||
| ### Long-duration Testing | ||||
|  | ||||
| Long-duration testing occurs over a twenty-four hour period. The | ||||
| software is run in one or more stressing cases representative of expected | ||||
| usage. After twenty-four hours, the software is evaluated for: | ||||
|  | ||||
| * Performance metrics: Have memory usage or CPU utilization increased | ||||
|   during this time period in unexpected or undesirable ways? | ||||
| * Subjective usability: Does the software behave in the same way it did | ||||
|   at the start of the test? Is it as responsive? | ||||
|  | ||||
| Any defects or unexpected behavior identified during testing should be | ||||
| [reported as issues](https://github.com/nasa/openmctweb/blob/master/CONTRIBUTING.md#issue-reporting) | ||||
| and reviewed for severity. | ||||
|  | ||||
| ## Test Performance | ||||
|  | ||||
| Tests are performed at various levels of frequency. | ||||
|  | ||||
| * _Per-merge_: Performed before any new changes are integrated into | ||||
|   the software. | ||||
| * _Per-sprint_: Performed at the end of every [sprint](../cycle.md). | ||||
| * _Per-release_: Performed at the end of every [release](../cycle.md). | ||||
|  | ||||
| ### Per-merge Testing | ||||
|  | ||||
| Before changes are merged, the author of the changes must perform: | ||||
|  | ||||
| * _Smoke testing_ (both generally, and for areas which interact with | ||||
|   the new changes.) | ||||
| * _Unit testing_ (as part of the automated build step.) | ||||
|  | ||||
| Changes are not merged until the author has affirmed that both | ||||
| forms of testing have been performed successfully; this is documented | ||||
| by the [Author Checklist](https://github.com/nasa/openmctweb/blob/master/CONTRIBUTING.md#author-checklist). | ||||
|  | ||||
| ### Per-sprint Testing | ||||
|  | ||||
| Before a sprint is closed, the development team must additionally | ||||
| perform: | ||||
|  | ||||
| * A relevant subset of [_user testing_](procedures.md#user-test-procedures) | ||||
|   identified by the acting [project manager](../cycle.md#roles). | ||||
| * [_Long-duration testing_](procedures.md#long-duration-testng) | ||||
|   (specifically, for 24 hours.) | ||||
|  | ||||
| Issues are reported as a product of both forms of testing. | ||||
|  | ||||
| A sprint is not closed until both categories have been performed on | ||||
| the latest snapshot of the software, _and_ no issues labelled as | ||||
| ["blocker"](https://github.com/nasa/openmctweb/blob/master/CONTRIBUTING.md#issue-reporting) | ||||
| remain open. | ||||
|  | ||||
| ### Per-release Testing | ||||
|  | ||||
| As [per-sprint testing](#per-sprint-testing), except that _user testing_ | ||||
| should cover all test cases, with less focus on changes from the specific | ||||
| sprint or release. | ||||
|  | ||||
| Per-release testing should also include any acceptance testing steps | ||||
| agreed upon with recipients of the software. | ||||
|  | ||||
| A release is not closed until both categories have been performed on | ||||
| the latest snapshot of the software, _and_ no issues labelled as | ||||
| ["blocker" or "critical"](https://github.com/nasa/openmctweb/blob/master/CONTRIBUTING.md#issue-reporting) | ||||
| remain open. | ||||
							
								
								
									
										169
									
								
								docs/src/process/testing/procedures.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										169
									
								
								docs/src/process/testing/procedures.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,169 @@ | ||||
| # Test Procedures | ||||
|  | ||||
| ## Introduction | ||||
|  | ||||
| This document is intended to be used: | ||||
|  | ||||
| * By testers, to verify that Open MCT Web behaves as specified. | ||||
| * By the development team, to document new test cases and to provide | ||||
|   guidance on how to author these. | ||||
|  | ||||
| ## Writing Procedures | ||||
|  | ||||
| ### Template | ||||
|  | ||||
| Procedures for individual tests should use the following template, | ||||
| adapted from [https://swehb.nasa.gov/display/7150/SWE-114](). | ||||
|  | ||||
| Property       | Value | ||||
| ---------------|--------------------------------------------------------------- | ||||
| Test ID        | | ||||
| Relevant reqs. | | ||||
| Prerequisites  | | ||||
| Test input     | | ||||
| Instructions   | | ||||
| Expectation    | | ||||
| Eval. criteria | | ||||
|  | ||||
| For multi-line descriptions, use an asterisk or similar indicator to refer | ||||
| to a longer-form description below. | ||||
|  | ||||
| #### Example Procedure - Edit a Layout | ||||
|  | ||||
| Property       | Value | ||||
| ---------------|--------------------------------------------------------------- | ||||
| Test ID        | MCT-TEST-000X - Edit a layout | ||||
| Relevant reqs. | MCT-EDIT-000Y | ||||
| Prerequisites  | Create a layout, as in MCT-TEST-000Z | ||||
| Test input     | Domain object database XYZ | ||||
| Instructions   | See below * | ||||
| Expectation    | Change to editing context † | ||||
| Eval. criteria | Visual inspection | ||||
|  | ||||
| * Follow the following steps: | ||||
|  | ||||
| 1. Verify that the created layout is currently navigated-to, | ||||
|    as in MCT-TEST-00ZZ. | ||||
| 2. Click the Edit button, identified by a pencil icon and the text "Edit" | ||||
|    displayed on hover. | ||||
|  | ||||
| † Right-hand viewing area should be surrounded by a dashed | ||||
| blue border when a domain object is being edited. | ||||
|  | ||||
| ### Guidelines | ||||
|  | ||||
| Test procedures should be written assuming minimal prior knowledge of the | ||||
| application: Non-standard terms should only be used when they are documented | ||||
| in [the glossary](#glossary), and shorthands used for user actions should | ||||
| be accompanied by useful references to test procedures describing those | ||||
| actions (when available) or descriptions in user documentation. | ||||
|  | ||||
| Test cases should be narrow in scope; if a list of steps is excessively | ||||
| long (or must be written vaguely to be kept short) it should be broken | ||||
| down into multiple tests which reference one another. | ||||
|  | ||||
| All requirements satisfied by Open MCT Web should be verifiable using | ||||
| one or more test procedures. | ||||
|  | ||||
| ## Glossary | ||||
|  | ||||
| This section will contain terms used in test procedures. This may link to | ||||
| a common glossary, to avoid replication of content. | ||||
|  | ||||
| ## Procedures | ||||
|  | ||||
| This section will contain specific test procedures. Presently, procedures | ||||
| are placeholders describing general patterns for setting up and conducting | ||||
| testing. | ||||
|  | ||||
| ### User Testing Setup | ||||
|  | ||||
| These procedures describes a general pattern for setting up for user | ||||
| testing. Specific deployments should customize this pattern with | ||||
| relevant data and any additional steps necessary. | ||||
|  | ||||
| Property       | Value | ||||
| ---------------|--------------------------------------------------------------- | ||||
| Test ID        | MCT-TEST-SETUP0 - User Testing Setup | ||||
| Relevant reqs. | TBD | ||||
| Prerequisites  | Build of relevant components | ||||
| Test input     | Exemplary database; exemplary telemetry data set | ||||
| Instructions   | See below | ||||
| Expectation    | Able to load application in a web browser (Google Chrome) | ||||
| Eval. criteria | Visual inspection | ||||
|  | ||||
| Instructions: | ||||
|  | ||||
| 1. Start telemetry server. | ||||
| 2. Start ElasticSearch. | ||||
| 3. Restore database snapshot to ElasticSearch. | ||||
| 4. Start telemetry playback. | ||||
| 5. Start HTTP server for client sources. | ||||
|  | ||||
| ### User Test Procedures | ||||
|  | ||||
| Specific user test cases have not yet been authored. In their absence, | ||||
| user testing is conducted by: | ||||
|  | ||||
| * Reviewing the text of issues from the issue tracker to understand the | ||||
|   desired behavior, and exercising this behavior in the running application. | ||||
|   (For instance, by following steps to reproduce from the original issue.) | ||||
|   * Issues which appear to be resolved should be marked as such with comments | ||||
|     on the original issue (e.g. "verified during user testing MM/DD/YYYY".) | ||||
|   * Issues which appear not to have been resolved should be reopened with an | ||||
|     explanation of what unexpected behavior has been observed. | ||||
|   * In cases where an issue appears resolved as-worded but other related | ||||
|     undesirable behavior is observed during testing, a new issue should be | ||||
|     opened, and linked to from a comment in the original issues. | ||||
| * General usage of new features and/or existing features which have undergone | ||||
|   recent changes. Defects or problems with usability should be documented | ||||
|   by filing issues in the issue tracker. | ||||
| * Open-ended testing to discover defects, identify usability issues, and | ||||
|   generate feature requests. | ||||
|  | ||||
| ### Long-Duration Testing | ||||
|  | ||||
| The purpose of long-duration testing is to identify performance issues | ||||
| and/or other defects which are sensitive to the amount of time the | ||||
| application is kept running. (Memory leaks, for instance.) | ||||
|  | ||||
| Property       | Value | ||||
| ---------------|--------------------------------------------------------------- | ||||
| Test ID        | MCT-TEST-LDT0 - Long-duration Testing | ||||
| Relevant reqs. | TBD | ||||
| Prerequisites  | MCT-TEST-SETUP0 | ||||
| Test input     | (As for test setup.) | ||||
| Instructions   | See "Instructions" below * | ||||
| Expectation    | See "Expectations" below † | ||||
| Eval. criteria | Visual inspection | ||||
|  | ||||
| * Instructions: | ||||
|  | ||||
| 1. Start `top` or a similar tool to measure CPU usage and memory utilization. | ||||
| 2. Open several user-created displays (as many as would be realistically | ||||
|    opened during actual usage in a stressing case) in some combination of | ||||
|    separate tabs and windows (approximately as many tabs-per-window as | ||||
|    total windows.) | ||||
| 3. Ensure that playback data is set to run continuously for at least 24 hours | ||||
|    (e.g. on a loop.) | ||||
| 4. Record CPU usage and memory utilization. | ||||
| 5. In at least one tab, try some general user interface gestures and make | ||||
|    notes about the subjective experience of using the application. (Particularly, | ||||
|    the degree of responsiveness.) | ||||
| 6. Leave client displays open for 24 hours. | ||||
| 7. Record CPU usage and memory utilization again. | ||||
| 8. Make additional notes about the subjective experience of using the | ||||
|    application (again, particularly responsiveness.) | ||||
| 9. Check logs for any unexpected warnings or errors. | ||||
|  | ||||
| † Expectations: | ||||
|  | ||||
| * At the end of the test, CPU usage and memory usage should both be similar | ||||
|   to their levels at the start of the test. | ||||
| * At the end of the test, subjective usage of the application should not | ||||
|   be observably different from the way it was at the start of the test. | ||||
|   (In particular, responsiveness should not decrease.) | ||||
| * Logs should not contain any unexpected warnings or errors ("expected" | ||||
|   warnings or errors are those that have been documented and prioritized | ||||
|   as known issues, or those that are explained by transient conditions | ||||
|   external to the software, such as network outages.) | ||||
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							| @@ -62,7 +62,7 @@ define( | ||||
|                 // so it's not checked for here, just formatted for display | ||||
|                 // differently. | ||||
|                 return (i + offset) * 1000 + firstTime * 1000 - | ||||
|                     (domain === 'yesterday' ? ONE_DAY : 0); | ||||
|                     (domain === 'yesterday' ? (ONE_DAY * 1000) : 0); | ||||
|             }; | ||||
|  | ||||
|             generatorData.getRangeValue = function (i, range) { | ||||
|   | ||||
							
								
								
									
										12
									
								
								example/mobile/bundle.json
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								example/mobile/bundle.json
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,12 @@ | ||||
| { | ||||
|   "name": "Mobile", | ||||
|   "description": "Allows elements with pertinence to mobile usage and development", | ||||
|   "extensions": { | ||||
|     "stylesheets": [ | ||||
|       { | ||||
|         "stylesheetUrl": "css/mobile-example.css", | ||||
|         "priority": "mandatory" | ||||
|       } | ||||
|     ] | ||||
|   } | ||||
| } | ||||
							
								
								
									
										26
									
								
								example/mobile/res/config.rb
									
									
									
									
									
										Executable file
									
								
							
							
						
						
									
										26
									
								
								example/mobile/res/config.rb
									
									
									
									
									
										Executable file
									
								
							| @@ -0,0 +1,26 @@ | ||||
| # Require any additional compass plugins here. | ||||
| # require "compass-growl" | ||||
|  | ||||
| # Set this to the root of your project when deployed: | ||||
| http_path = "/" | ||||
| css_dir = "css" | ||||
| sass_dir = "sass" | ||||
| images_dir = "images" | ||||
| javascripts_dir = "js" | ||||
|  | ||||
| # You can select your preferred output style here (can be overridden via the command line): | ||||
| # :expanded, :compressed, :nested | ||||
| output_style = :nested | ||||
|  | ||||
| # To enable relative paths to assets via compass helper functions. Uncomment: | ||||
| relative_assets = true | ||||
|  | ||||
| # To disable debugging comments that display the original location of your selectors. Uncomment: | ||||
| # line_comments = false | ||||
|  | ||||
|  | ||||
| # If you prefer the indented syntax, you might want to regenerate this | ||||
| # project again passing --syntax sass, or you can uncomment this: | ||||
| # preferred_syntax = :sass | ||||
| # and then run: | ||||
| # sass-convert -R --from scss --to sass vfn_platform/static/sass scss && rm -rf sass && mv scss sass | ||||
							
								
								
									
										103
									
								
								example/mobile/res/css/mobile-example.css
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										103
									
								
								example/mobile/res/css/mobile-example.css
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,103 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /************************** FEATURES */ | ||||
| /************************** VERY INFLUENTIAL GLOBAL DIMENSIONS */ | ||||
| /************************** RATIOS */ | ||||
| /************************** LAYOUT */ | ||||
| /************************** CONTROLS */ | ||||
| /************************** PATHS */ | ||||
| /************************** TIMINGS */ | ||||
| /************************** LIMITS */ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /************************** MOBILE REPRESENTATION ITEMS DIMENSIONS */ | ||||
| /************************** MOBILE TREE MENU DIMENSIONS */ | ||||
| /************************** WINDOW DIMENSIONS FOR RWD */ | ||||
| /************************** MEDIA QUERIES: WINDOW CHECKS FOR SPECIFIC ORIENTATIONS FOR EACH DEVICE */ | ||||
| /************************** MEDIA QUERIES: WINDOWS FOR SPECIFIC ORIENTATIONS FOR EACH DEVICE */ | ||||
| /************************** DEVICE PARAMETERS FOR MENUS/REPRESENTATIONS */ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /* REQUIRES mobile/_constants */ | ||||
| @media screen and (orientation: portrait) and (max-width: 514px) and (max-height: 740px) and (max-device-width: 799px) and (max-device-height: 1024px), screen and (orientation: landscape) and (max-height: 514px) and (max-width: 740px) and (max-device-width: 799px) and (max-device-height: 1024px), screen and (orientation: landscape) and (max-height: 514px) and (max-width: 740px) and (max-device-width: 1024px) and (max-device-height: 799px), screen and (orientation: portrait) and (min-width: 515px) and (max-width: 799px) and (min-height: 741px) and (max-height: 1024px) and (max-device-width: 799px) and (max-device-height: 1024px), screen and (orientation: landscape) and (min-height: 515px) and (max-height: 799px) and (min-width: 741px) and (max-width: 1024px) and (max-device-width: 799px) and (max-device-height: 1024px), screen and (orientation: landscape) and (min-height: 515px) and (max-height: 799px) and (min-width: 741px) and (max-width: 1024px) and (max-device-width: 1024px) and (max-device-height: 799px) { | ||||
|   /* line 28, ../sass/mobile-example.scss */ | ||||
|   .create-btn-holder { | ||||
|     display: block !important; } } | ||||
							
								
								
									
										31
									
								
								example/mobile/res/sass/mobile-example.scss
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										31
									
								
								example/mobile/res/sass/mobile-example.scss
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,31 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| @import "../../../../platform/commonUI/general/res/sass/constants"; | ||||
| @import "../../../../platform/commonUI/general/res/sass/mobile/constants"; | ||||
| @import "../../../../platform/commonUI/general/res/sass/mobile/mixins"; | ||||
|  | ||||
| @include phoneandtablet { | ||||
|     // Show the Create button | ||||
|     .create-btn-holder { | ||||
|         display: block !important; | ||||
|     } | ||||
| } | ||||
| @@ -39,8 +39,11 @@ define( | ||||
|                 start = Date.now(); | ||||
|  | ||||
|             function update() { | ||||
|                 var secs = (Date.now() - start) / 1000; | ||||
|                 var now = Date.now(), | ||||
|                     secs = (now - start) / 1000; | ||||
|                 displayed = Math.round(digests / secs); | ||||
|                 start = now; | ||||
|                 digests = 0; | ||||
|             } | ||||
|  | ||||
|             function increment() { | ||||
|   | ||||
							
								
								
									
										2
									
								
								example/scratchpad/README.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								example/scratchpad/README.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,2 @@ | ||||
| Example of using multiple persistence stores by exposing a root | ||||
| object with a different space prefix. | ||||
							
								
								
									
										23
									
								
								example/scratchpad/bundle.json
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										23
									
								
								example/scratchpad/bundle.json
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,23 @@ | ||||
| { | ||||
|     "extensions": { | ||||
|         "roots": [ | ||||
|             { | ||||
|                 "id": "scratch:root", | ||||
|                 "model": { | ||||
|                     "type": "folder", | ||||
|                     "composition": [], | ||||
|                     "name": "Scratchpad" | ||||
|                 }, | ||||
|                 "priority": "preferred" | ||||
|             } | ||||
|         ], | ||||
|         "components": [ | ||||
|             { | ||||
|                 "provides": "persistenceService", | ||||
|                 "type": "provider", | ||||
|                 "implementation": "ScratchPersistenceProvider.js", | ||||
|                 "depends": [ "$q" ] | ||||
|             } | ||||
|         ] | ||||
|     } | ||||
| } | ||||
							
								
								
									
										79
									
								
								example/scratchpad/src/ScratchPersistenceProvider.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										79
									
								
								example/scratchpad/src/ScratchPersistenceProvider.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,79 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
|  | ||||
| /*global define,window*/ | ||||
|  | ||||
| define( | ||||
|     [], | ||||
|     function () { | ||||
|         'use strict'; | ||||
|  | ||||
|         /** | ||||
|          * The ScratchPersistenceProvider keeps JSON documents in memory | ||||
|          * and provides a persistence interface, but changes are lost on reload. | ||||
|          * @memberof example/scratchpad | ||||
|          * @constructor | ||||
|          * @implements {PersistenceService} | ||||
|          * @param q Angular's $q, for promises | ||||
|          */ | ||||
|         function ScratchPersistenceProvider($q) { | ||||
|             this.$q = $q; | ||||
|             this.table = {}; | ||||
|         } | ||||
|  | ||||
|         ScratchPersistenceProvider.prototype.listSpaces = function () { | ||||
|             return this.$q.when(['scratch']); | ||||
|         }; | ||||
|  | ||||
|         ScratchPersistenceProvider.prototype.listObjects = function (space) { | ||||
|             return this.$q.when( | ||||
|                 space === 'scratch' ? Object.keys(this.table) : [] | ||||
|             ); | ||||
|         }; | ||||
|  | ||||
|         ScratchPersistenceProvider.prototype.createObject = function (space, key, value) { | ||||
|             if (space === 'scratch') { | ||||
|                 this.table[key] = JSON.stringify(value); | ||||
|             } | ||||
|             return this.$q.when(space === 'scratch'); | ||||
|         }; | ||||
|  | ||||
|         ScratchPersistenceProvider.prototype.readObject = function (space, key) { | ||||
|             return this.$q.when( | ||||
|                 (space === 'scratch' && this.table[key]) ? | ||||
|                         JSON.parse(this.table[key]) : undefined | ||||
|             ); | ||||
|         }; | ||||
|  | ||||
|         ScratchPersistenceProvider.prototype.deleteObject = function (space, key, value) { | ||||
|             if (space === 'scratch') { | ||||
|                 delete this.table[key]; | ||||
|             } | ||||
|             return this.$q.when(space === 'scratch'); | ||||
|         }; | ||||
|  | ||||
|         ScratchPersistenceProvider.prototype.updateObject = | ||||
|             ScratchPersistenceProvider.prototype.createObject; | ||||
|  | ||||
|         return ScratchPersistenceProvider; | ||||
|     } | ||||
| ); | ||||
							
								
								
									
										10
									
								
								index.html
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								index.html
									
									
									
									
									
								
							| @@ -27,12 +27,12 @@ | ||||
|     <title></title> | ||||
|     <script type="text/javascript" | ||||
|             src="platform/framework/lib/require.js" | ||||
|             data-main="platform/framework/src/Main.js"> | ||||
|             data-main="main.js"> | ||||
|     </script> | ||||
| 	<link rel="icon" type="image/png" href="platform/commonUI/general/res/images/favicons/favicon-32x32.png" sizes="32x32"> | ||||
| 	<link rel="icon" type="image/png" href="platform/commonUI/general/res/images/favicons/favicon-96x96.png" sizes="96x96"> | ||||
| 	<link rel="icon" type="image/png" href="platform/commonUI/general/res/images/favicons/favicon-16x16.png" sizes="16x16"> | ||||
| 	<link rel="shortcut icon" href="platform/commonUI/general/res/images/favicons/favicon.ico"> | ||||
|     <link rel="icon" type="image/png" href="platform/commonUI/general/res/images/favicons/favicon-32x32.png" sizes="32x32"> | ||||
|     <link rel="icon" type="image/png" href="platform/commonUI/general/res/images/favicons/favicon-96x96.png" sizes="96x96"> | ||||
|     <link rel="icon" type="image/png" href="platform/commonUI/general/res/images/favicons/favicon-16x16.png" sizes="16x16"> | ||||
|     <link rel="shortcut icon" href="platform/commonUI/general/res/images/favicons/favicon.ico"> | ||||
| </head> | ||||
| <body class="user-environ" ng-view> | ||||
|  | ||||
|   | ||||
| @@ -34,7 +34,6 @@ module.exports = function(config) { | ||||
|         // List of files / patterns to load in the browser. | ||||
|         // By default, files are also included in a script tag. | ||||
|         files: [ | ||||
|             '**/moment*', | ||||
|             {pattern: 'example/**/*.js', included: false}, | ||||
|             {pattern: 'platform/**/*.js', included: false}, | ||||
|             {pattern: 'warp/**/*.js', included: false}, | ||||
|   | ||||
							
								
								
									
										37
									
								
								main.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										37
									
								
								main.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,37 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
|  | ||||
| /*global require*/ | ||||
| (function (require, options) { | ||||
|     'use strict'; | ||||
|     require.config({ | ||||
|         shim: { | ||||
|             "platform/framework/lib/angular.min": { | ||||
|                 exports: "angular" | ||||
|             }, | ||||
|             "platform/framework/lib/angular-route.min": { | ||||
|                 deps: ["platform/framework/lib/angular.min"] | ||||
|             } | ||||
|         } | ||||
|     }); | ||||
|     require(["platform/framework/src/Main"]); | ||||
| }(require)); | ||||
| @@ -4,6 +4,8 @@ | ||||
|   "description": "The OpenMCTWeb core platform", | ||||
|   "dependencies": { | ||||
|     "express": "^4.13.1", | ||||
|     "globby": "^4.0.0", | ||||
|     "requirejs": "^2.1.17", | ||||
|     "minimist": "^1.1.1" | ||||
|   }, | ||||
|   "devDependencies": { | ||||
| @@ -16,13 +18,13 @@ | ||||
|     "karma-jasmine": "^0.1.5", | ||||
|     "karma-phantomjs-launcher": "^0.1.4", | ||||
|     "karma-requirejs": "^0.2.2", | ||||
|     "requirejs": "^2.1.17", | ||||
|     "marked": "^0.3.5", | ||||
|     "glob": ">= 3.0.0", | ||||
|     "split": "^1.0.0", | ||||
|     "mkdirp": "^0.5.1", | ||||
|     "nomnoml": "^0.0.3", | ||||
|     "canvas": "^1.2.7", | ||||
|     "strip-html-comments": "^1.0.0", | ||||
|     "markdown-toc": "^0.11.7" | ||||
|   }, | ||||
|   "scripts": { | ||||
| @@ -32,7 +34,8 @@ | ||||
|     "watch": "karma start", | ||||
|     "jsdoc": "jsdoc -c jsdoc.json -r -d target/docs/api", | ||||
|     "otherdoc": "node docs/gendocs.js --in docs/src --out target/docs", | ||||
|     "docs": "npm run jsdoc ; npm run otherdoc" | ||||
|     "docs": "npm run jsdoc ; npm run otherdoc", | ||||
|     "postinstall": "node build.js" | ||||
|   }, | ||||
|   "repository": { | ||||
|     "type": "git", | ||||
|   | ||||
| @@ -1,9 +1,4 @@ | ||||
| { | ||||
|     "configuration": { | ||||
|         "paths": { | ||||
|             "uuid": "uuid" | ||||
|         } | ||||
|     }, | ||||
|     "extensions": { | ||||
|         "routes": [ | ||||
|             { | ||||
| @@ -107,6 +102,12 @@ | ||||
|                 "implementation": "navigation/NavigationService.js" | ||||
|             } | ||||
|         ], | ||||
|         "policies": [ | ||||
|             { | ||||
|                 "implementation": "creation/CreationPolicy.js", | ||||
|                 "category": "creation" | ||||
|             } | ||||
|         ], | ||||
|         "actions": [ | ||||
|             { | ||||
|                 "key": "navigate", | ||||
| @@ -159,7 +160,7 @@ | ||||
|                 "provides": "creationService", | ||||
|                 "type": "provider", | ||||
|                 "implementation": "creation/CreationService.js", | ||||
|                 "depends": [ "persistenceService", "now", "$q", "$log" ] | ||||
|                 "depends": [ "$q", "$log" ] | ||||
|             } | ||||
|         ], | ||||
|         "runs": [ | ||||
| @@ -178,16 +179,6 @@ | ||||
|                 "copyright": "Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)", | ||||
|                 "license": "license-mit", | ||||
|                 "link": "https://github.com/sindresorhus/screenfull.js/blob/gh-pages/license" | ||||
|             }, | ||||
|             { | ||||
|                 "name": "Math.uuid.js", | ||||
|                 "version": "1.4", | ||||
|                 "description": "Unique identifer generation (code adapted.)", | ||||
|                 "author": "Robert Kieffer", | ||||
|                 "website": "https://github.com/broofa/node-uuid", | ||||
|                 "copyright": "Copyright (c) 2010 Robert Kieffer", | ||||
|                 "license": "license-mit", | ||||
|                 "link": "http://opensource.org/licenses/MIT" | ||||
|             } | ||||
|         ] | ||||
|     } | ||||
|   | ||||
| @@ -20,15 +20,17 @@ | ||||
|  at runtime from the About dialog for additional information. | ||||
| --> | ||||
| <span ng-controller="BrowseObjectController"> | ||||
|     <div class="object-browse-bar bar l-flex"> | ||||
|         <div class="items-select left"> | ||||
|     <div class="object-browse-bar l-flex-row"> | ||||
|         <div class="items-select left flex-elem l-flex-row grows"> | ||||
|             <mct-representation key="'back-arrow'" | ||||
|                                 mct-object="domainObject" | ||||
|                                 class="l-back"></mct-representation> | ||||
|             <mct-representation key="'object-header'" mct-object="domainObject"> | ||||
|                                 class="flex-elem l-back"></mct-representation> | ||||
|             <mct-representation key="'object-header'" | ||||
|                                 mct-object="domainObject" | ||||
|                                 class="l-flex-row flex-elem grows object-header"> | ||||
|             </mct-representation> | ||||
|         </div> | ||||
|         <div class="btn-bar right"> | ||||
|         <div class="btn-bar right l-flex-row flex-elem flex-justify-end flex-fixed"> | ||||
|             <mct-representation key="'switcher'" | ||||
|                                 mct-object="domainObject" | ||||
|                                 ng-model="representation"> | ||||
|   | ||||
| @@ -28,30 +28,23 @@ | ||||
|         <mct-split-pane class='abs contents' | ||||
|                         anchor='left'> | ||||
|             <div class='split-pane-component treeview pane left'> | ||||
|                 <!--<a class="mini-tab-icon anchor-left toggle-pane toggle-search mobile-hide" | ||||
|                    title="Enable search" | ||||
|                    ng-click="modelPaneTree.toggle()" | ||||
|                    ng-class="{ collapsed : !modelPaneTree.visible() }" | ||||
|                    ng-style="{ opacity: modelPaneTree.visible()? 0:1 }"></a>--> | ||||
|                 <div class="holder holder-create-and-search abs l-mobile"> | ||||
|                 <div class="abs holder l-flex-col holder-treeview-elements"> | ||||
|                     <mct-representation key="'create-button'" | ||||
|                                         mct-object="navigatedObject" | ||||
|                                         mct-device="desktop"> | ||||
|                                         class="holder flex-elem create-btn-holder"> | ||||
|                     </mct-representation> | ||||
|                     <mct-include key="'search'" | ||||
|                                  ng-model="treeModel" | ||||
|                                  class="holder l-flex-col flex-elem search-holder" | ||||
|                                  ng-class="{ active: treeModel.search, grows: treeModel.search }"> | ||||
|                     </mct-include> | ||||
|                     <mct-representation key="'tree'" | ||||
|                                         mct-object="domainObject" | ||||
|                                         parameters="tree" | ||||
|                                         ng-model="treeModel" | ||||
|                                         class="holder flex-elem grows vscroll tree-holder" | ||||
|                                         ng-hide="treeModel.search"> | ||||
|                     </mct-representation> | ||||
|                     <div class='holder search-holder abs' | ||||
|                          ng-class="{active: treeModel.search}"> | ||||
|                         <mct-include key="'search'" | ||||
|                                      ng-model="treeModel"> | ||||
|                         </mct-include> | ||||
|                     </div> | ||||
|                     <div class='tree-holder abs mobile-tree-holder' | ||||
|                          ng-hide="treeModel.search"> | ||||
|                         <mct-representation key="'tree'" | ||||
|                                             mct-object="domainObject" | ||||
|                                             parameters="tree" | ||||
|                                             ng-model="treeModel"> | ||||
|                         </mct-representation> | ||||
|                     </div> | ||||
|                 </div> | ||||
|             </div> | ||||
|  | ||||
| @@ -63,7 +56,7 @@ | ||||
|                    ng-click="modelPaneTree.toggle()" | ||||
|                    ng-class="{ collapsed : !modelPaneTree.visible() }"></a> | ||||
|  | ||||
|                 <div class='holder holder-object-and-inspector abs l-mobile' id='content-area' | ||||
|                 <div class='holder holder-object-and-inspector abs' id='content-area' | ||||
|                      ng-controller="PaneController as modelPaneInspect" | ||||
|                      ng-class="modelPaneInspect.visible() ? 'pane-inspect-showing' : 'pane-inspect-hidden'"> | ||||
|  | ||||
|   | ||||
| @@ -19,12 +19,12 @@ | ||||
|  this source code distribution or the Licensing information page available | ||||
|  at runtime from the About dialog for additional information. | ||||
| --> | ||||
| <div class='object-header'> | ||||
|     <span class='type-icon ui-symbol'>{{type.getGlyph()}}</span> | ||||
|     <!--span class='type-name mobile-important-hide'>{{type.getName()}}</span--> | ||||
|     <span class="l-elem-wrapper l-flex"> | ||||
|         <span ng-if="parameters.mode" class='action'>{{parameters.mode}}</span> | ||||
|         <span class='title-label'>{{model.name}}</span> | ||||
|         <mct-representation key="'menu-arrow'" mct-object='domainObject'></mct-representation> | ||||
|     </span> | ||||
| </div> | ||||
| <span class='type-icon ui-symbol flex-elem'>{{type.getGlyph()}}</span> | ||||
| <span class="l-elem-wrapper l-flex-row flex-elem grows"> | ||||
|     <span ng-if="parameters.mode" class='action flex-elem'>{{parameters.mode}}</span> | ||||
|     <span class='title-label flex-elem flex-can-shrink'>{{model.name}}</span> | ||||
|     <mct-representation | ||||
|         key="'menu-arrow'" | ||||
|         mct-object='domainObject' | ||||
|         class="flex-elem"></mct-representation> | ||||
| </span> | ||||
| @@ -69,7 +69,7 @@ define( | ||||
|  | ||||
|             // Introduce one create action per type | ||||
|             return this.typeService.listTypes().filter(function (type) { | ||||
|                 return type.hasFeature("creation"); | ||||
|                 return self.policyService.allow("creation", type); | ||||
|             }).map(function (type) { | ||||
|                 return new CreateAction( | ||||
|                     type, | ||||
|   | ||||
							
								
								
									
										45
									
								
								platform/commonUI/browse/src/creation/CreationPolicy.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										45
									
								
								platform/commonUI/browse/src/creation/CreationPolicy.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,45 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /*global define*/ | ||||
|  | ||||
| define( | ||||
|     [], | ||||
|     function () { | ||||
|         "use strict"; | ||||
|  | ||||
|         /** | ||||
|          * A policy for determining whether objects of a given type can be | ||||
|          * created. | ||||
|          * @constructor | ||||
|          * @implements {Policy} | ||||
|          * @memberof platform/commonUI/browse | ||||
|          */ | ||||
|         function CreationPolicy() { | ||||
|         } | ||||
|  | ||||
|         CreationPolicy.prototype.allow = function (type) { | ||||
|             return type.hasFeature("creation"); | ||||
|         }; | ||||
|  | ||||
|         return CreationPolicy; | ||||
|     } | ||||
| ); | ||||
| @@ -25,8 +25,8 @@ | ||||
|  * Module defining CreateService. Created by vwoeltje on 11/10/14. | ||||
|  */ | ||||
| define( | ||||
|     ["uuid"], | ||||
|     function (uuid) { | ||||
|     [], | ||||
|     function () { | ||||
|         "use strict"; | ||||
|  | ||||
|         var NON_PERSISTENT_WARNING = | ||||
| @@ -42,11 +42,9 @@ define( | ||||
|          * @memberof platform/commonUI/browse | ||||
|          * @constructor | ||||
|          */ | ||||
|         function CreationService(persistenceService, now, $q, $log) { | ||||
|             this.persistenceService = persistenceService; | ||||
|         function CreationService($q, $log) { | ||||
|             this.$q = $q; | ||||
|             this.$log = $log; | ||||
|             this.now = now; | ||||
|         } | ||||
|  | ||||
|         /** | ||||
| @@ -70,26 +68,17 @@ define( | ||||
|          */ | ||||
|         CreationService.prototype.createObject = function (model, parent) { | ||||
|             var persistence = parent.getCapability("persistence"), | ||||
|                 newObject = parent.useCapability("instantiation", model), | ||||
|                 newObjectPersistence = newObject.getCapability("persistence"), | ||||
|                 self = this; | ||||
|  | ||||
|             // Persist the new domain object's model; it will be fully | ||||
|             // constituted as a domain object when loaded back, as all | ||||
|             // domain object models are. | ||||
|             function doPersist(space, id, model) { | ||||
|                 return self.persistenceService.createObject( | ||||
|                     space, | ||||
|                     id, | ||||
|                     model | ||||
|                 ).then(function () { return id; }); | ||||
|             } | ||||
|  | ||||
|             // Add the newly-created object's id to the parent's | ||||
|             // composition, so that it will subsequently appear | ||||
|             // as a child contained by that parent. | ||||
|             function addToComposition(id, parent, parentPersistence) { | ||||
|             function addToComposition() { | ||||
|                 var compositionCapability = parent.getCapability('composition'), | ||||
|                     addResult = compositionCapability && | ||||
|                         compositionCapability.add(id); | ||||
|                         compositionCapability.add(newObject); | ||||
|  | ||||
|                 return self.$q.when(addResult).then(function (result) { | ||||
|                     if (!result) { | ||||
| @@ -97,7 +86,7 @@ define( | ||||
|                         return undefined; | ||||
|                     } | ||||
|  | ||||
|                     return parentPersistence.persist().then(function () { | ||||
|                     return persistence.persist().then(function () { | ||||
|                         return result; | ||||
|                     }); | ||||
|                 }); | ||||
| @@ -105,21 +94,13 @@ define( | ||||
|  | ||||
|             // We need the parent's persistence capability to determine | ||||
|             // what space to create the new object's model in. | ||||
|             if (!persistence) { | ||||
|             if (!persistence || !newObjectPersistence) { | ||||
|                 self.$log.warn(NON_PERSISTENT_WARNING); | ||||
|                 return self.$q.reject(new Error(NON_PERSISTENT_WARNING)); | ||||
|             } | ||||
|  | ||||
|             // We create a new domain object in three sequential steps: | ||||
|             // 1. Get a new UUID for the object | ||||
|             // 2. Create a model with that ID in the persistence space | ||||
|             // 3. Add that ID to | ||||
|             return self.$q.when(uuid()).then(function (id) { | ||||
|                 model.persisted = self.now(); | ||||
|                 return doPersist(persistence.getSpace(), id, model); | ||||
|             }).then(function (id) { | ||||
|                 return addToComposition(id, parent, persistence); | ||||
|             }); | ||||
|             // Persist the new object, then add it to composition. | ||||
|             return newObjectPersistence.persist().then(addToComposition); | ||||
|         }; | ||||
|  | ||||
|  | ||||
|   | ||||
| @@ -33,6 +33,9 @@ define( | ||||
|             var mockTypeService, | ||||
|                 mockDialogService, | ||||
|                 mockCreationService, | ||||
|                 mockPolicyService, | ||||
|                 mockCreationPolicy, | ||||
|                 mockPolicyMap = {}, | ||||
|                 mockTypes, | ||||
|                 provider; | ||||
|  | ||||
| @@ -67,14 +70,32 @@ define( | ||||
|                     "creationService", | ||||
|                     [ "createObject" ] | ||||
|                 ); | ||||
|                 mockPolicyService = jasmine.createSpyObj( | ||||
|                     "policyService", | ||||
|                     [ "allow" ] | ||||
|                 ); | ||||
|  | ||||
|                 mockTypes = [ "A", "B", "C" ].map(createMockType); | ||||
|  | ||||
|                 mockTypes.forEach(function(type){ | ||||
|                     mockPolicyMap[type.getName()] = true; | ||||
|                 }); | ||||
|  | ||||
|                 mockCreationPolicy = function(type){ | ||||
|                     return mockPolicyMap[type.getName()]; | ||||
|                 }; | ||||
|  | ||||
|                 mockPolicyService.allow.andCallFake(function(category, type){ | ||||
|                     return category === "creation" && mockCreationPolicy(type) ? true : false; | ||||
|                 }); | ||||
|  | ||||
|                 mockTypeService.listTypes.andReturn(mockTypes); | ||||
|  | ||||
|                 provider = new CreateActionProvider( | ||||
|                     mockTypeService, | ||||
|                     mockDialogService, | ||||
|                     mockCreationService | ||||
|                     mockCreationService, | ||||
|                     mockPolicyService | ||||
|                 ); | ||||
|             }); | ||||
|  | ||||
| @@ -94,15 +115,15 @@ define( | ||||
|  | ||||
|             it("does not expose non-creatable types", function () { | ||||
|                 // One of the types won't have the creation feature... | ||||
|                 mockTypes[1].hasFeature.andReturn(false); | ||||
|                 mockPolicyMap[mockTypes[0].getName()] = false; | ||||
|                 // ...so it should have been filtered out. | ||||
|                 expect(provider.getActions({ | ||||
|                     key: "create", | ||||
|                     domainObject: {} | ||||
|                 }).length).toEqual(2); | ||||
|                 // Make sure it was creation which was used to check | ||||
|                 expect(mockTypes[1].hasFeature) | ||||
|                     .toHaveBeenCalledWith("creation"); | ||||
|                 expect(mockPolicyService.allow) | ||||
|                     .toHaveBeenCalledWith("creation", mockTypes[0]); | ||||
|             }); | ||||
|         }); | ||||
|     } | ||||
|   | ||||
							
								
								
									
										53
									
								
								platform/commonUI/browse/test/creation/CreationPolicySpec.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										53
									
								
								platform/commonUI/browse/test/creation/CreationPolicySpec.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,53 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /*global define,describe,it,expect,beforeEach,jasmine*/ | ||||
|  | ||||
| define( | ||||
|     ["../../src/creation/CreationPolicy"], | ||||
|     function (CreationPolicy) { | ||||
|         "use strict"; | ||||
|  | ||||
|         describe("The creation policy", function () { | ||||
|             var mockType, | ||||
|                 policy; | ||||
|  | ||||
|             beforeEach(function () { | ||||
|                 mockType = jasmine.createSpyObj( | ||||
|                     'type', | ||||
|                     ['hasFeature'] | ||||
|                 ); | ||||
|  | ||||
|                 policy = new CreationPolicy(); | ||||
|             }); | ||||
|  | ||||
|             it("allows creation of types with the creation feature", function () { | ||||
|                 mockType.hasFeature.andReturn(true); | ||||
|                 expect(policy.allow(mockType)).toBeTruthy(); | ||||
|             }); | ||||
|  | ||||
|             it("disallows creation of types without the creation feature", function () { | ||||
|                 mockType.hasFeature.andReturn(false); | ||||
|                 expect(policy.allow(mockType)).toBeFalsy(); | ||||
|             }); | ||||
|         }); | ||||
|     } | ||||
| ); | ||||
| @@ -30,9 +30,7 @@ define( | ||||
|         "use strict"; | ||||
|  | ||||
|         describe("The creation service", function () { | ||||
|             var mockPersistenceService, | ||||
|                 mockNow, | ||||
|                 mockQ, | ||||
|             var mockQ, | ||||
|                 mockLog, | ||||
|                 mockParentObject, | ||||
|                 mockNewObject, | ||||
| @@ -40,7 +38,9 @@ define( | ||||
|                 mockPersistenceCapability, | ||||
|                 mockCompositionCapability, | ||||
|                 mockContextCapability, | ||||
|                 mockCreationCapability, | ||||
|                 mockCapabilities, | ||||
|                 mockNewPersistenceCapability, | ||||
|                 creationService; | ||||
|  | ||||
|             function mockPromise(value) { | ||||
| @@ -60,11 +60,6 @@ define( | ||||
|             } | ||||
|  | ||||
|             beforeEach(function () { | ||||
|                 mockPersistenceService = jasmine.createSpyObj( | ||||
|                     "persistenceService", | ||||
|                     [ "createObject" ] | ||||
|                 ); | ||||
|                 mockNow = jasmine.createSpy('now'); | ||||
|                 mockQ = { when: mockPromise, reject: mockReject }; | ||||
|                 mockLog = jasmine.createSpyObj( | ||||
|                     "$log", | ||||
| @@ -76,7 +71,7 @@ define( | ||||
|                 ); | ||||
|                 mockNewObject = jasmine.createSpyObj( | ||||
|                     "newObject", | ||||
|                     [ "getId" ] | ||||
|                     [ "getId", "getCapability", "useCapability" ] | ||||
|                 ); | ||||
|                 mockMutationCapability = jasmine.createSpyObj( | ||||
|                     "mutation", | ||||
| @@ -94,19 +89,22 @@ define( | ||||
|                     "context", | ||||
|                     ["getPath"] | ||||
|                 ); | ||||
|                 mockCreationCapability = jasmine.createSpyObj( | ||||
|                     "creation", | ||||
|                     ["instantiate", "invoke"] | ||||
|                 ); | ||||
|                 mockCapabilities = { | ||||
|                     mutation: mockMutationCapability, | ||||
|                     persistence: mockPersistenceCapability, | ||||
|                     composition: mockCompositionCapability, | ||||
|                     context: mockContextCapability | ||||
|                     context: mockContextCapability, | ||||
|                     instantiation: mockCreationCapability | ||||
|                 }; | ||||
|  | ||||
|                 mockPersistenceService.createObject.andReturn( | ||||
|                     mockPromise(true) | ||||
|                 mockNewPersistenceCapability = jasmine.createSpyObj( | ||||
|                     "new-persistence", | ||||
|                     [ "persist", "getSpace" ] | ||||
|                 ); | ||||
|  | ||||
|                 mockNow.andReturn(12321); | ||||
|  | ||||
|                 mockParentObject.getCapability.andCallFake(function (key) { | ||||
|                     return mockCapabilities[key]; | ||||
|                 }); | ||||
| @@ -115,9 +113,16 @@ define( | ||||
|                 }); | ||||
|                 mockParentObject.getId.andReturn('parentId'); | ||||
|  | ||||
|                 mockPersistenceCapability.persist.andReturn( | ||||
|                     mockPromise(true) | ||||
|                 ); | ||||
|                 mockNewObject.getId.andReturn('newId'); | ||||
|                 mockNewObject.getCapability.andCallFake(function (c) { | ||||
|                     return c === 'persistence' ? | ||||
|                             mockNewPersistenceCapability : undefined; | ||||
|                 }); | ||||
|  | ||||
|                 mockPersistenceCapability.persist | ||||
|                     .andReturn(mockPromise(true)); | ||||
|                 mockNewPersistenceCapability.persist | ||||
|                     .andReturn(mockPromise(true)); | ||||
|  | ||||
|                 mockMutationCapability.invoke.andReturn(mockPromise(true)); | ||||
|                 mockPersistenceCapability.getSpace.andReturn("testSpace"); | ||||
| @@ -125,10 +130,12 @@ define( | ||||
|                     mockPromise([mockNewObject]) | ||||
|                 ); | ||||
|                 mockCompositionCapability.add.andReturn(mockPromise(true)); | ||||
|                 mockCreationCapability.instantiate.andReturn(mockNewObject); | ||||
|                 mockCreationCapability.invoke.andCallFake(function (model) { | ||||
|                     return mockCreationCapability.instantiate(model); | ||||
|                 }); | ||||
|  | ||||
|                 creationService = new CreationService( | ||||
|                     mockPersistenceService, | ||||
|                     mockNow, | ||||
|                     mockQ, | ||||
|                     mockLog | ||||
|                 ); | ||||
| @@ -137,21 +144,18 @@ define( | ||||
|             it("allows new objects to be created", function () { | ||||
|                 var model = { someKey: "some value" }; | ||||
|                 creationService.createObject(model, mockParentObject); | ||||
|                 expect(mockPersistenceService.createObject).toHaveBeenCalledWith( | ||||
|                     "testSpace", | ||||
|                     jasmine.any(String), // the object id; generated UUID | ||||
|                     model | ||||
|                 ); | ||||
|                 expect(mockCreationCapability.instantiate) | ||||
|                     .toHaveBeenCalledWith(model); | ||||
|             }); | ||||
|  | ||||
|             it("adds new id's to the parent's composition", function () { | ||||
|             it("adds new objects to the parent's composition", function () { | ||||
|                 var model = { someKey: "some value" }, | ||||
|                     parentModel = { composition: ["notAnyUUID"] }; | ||||
|                 creationService.createObject(model, mockParentObject); | ||||
|  | ||||
|                 // Verify that a new ID was added | ||||
|                 expect(mockCompositionCapability.add) | ||||
|                     .toHaveBeenCalledWith(jasmine.any(String)); | ||||
|                     .toHaveBeenCalledWith(mockNewObject); | ||||
|             }); | ||||
|  | ||||
|             it("provides the newly-created object", function () { | ||||
| @@ -207,11 +211,6 @@ define( | ||||
|                 expect(mockLog.error).toHaveBeenCalled(); | ||||
|             }); | ||||
|  | ||||
|             it("attaches a 'persisted' timestamp", function () { | ||||
|                 var model = { someKey: "some value" }; | ||||
|                 creationService.createObject(model, mockParentObject); | ||||
|                 expect(model.persisted).toEqual(mockNow()); | ||||
|             }); | ||||
|  | ||||
|         }); | ||||
|     } | ||||
|   | ||||
| @@ -8,6 +8,7 @@ | ||||
|     "creation/CreateMenuController", | ||||
|     "creation/CreateWizard", | ||||
|     "creation/CreationService", | ||||
|     "creation/CreationPolicy", | ||||
|     "creation/LocatorController", | ||||
|     "navigation/NavigateAction", | ||||
|     "navigation/NavigationService", | ||||
|   | ||||
| @@ -181,7 +181,7 @@ define( | ||||
|          * @typedef DialogOption | ||||
|          * @property {string} label a label to be displayed as the button | ||||
|          * text for this action | ||||
|          * @property {function} action a function to be called when the | ||||
|          * @property {function} callback a function to be called when the | ||||
|          * button is clicked | ||||
|          */ | ||||
|  | ||||
|   | ||||
| @@ -22,7 +22,8 @@ | ||||
| <div class='top-bar edit abs'> | ||||
|     <mct-representation key="'object-header'" | ||||
|                         mct-object="domainObject" | ||||
|                         parameters="{ mode: 'Edit' }"> | ||||
|                         parameters="{ mode: 'Edit' }" | ||||
|                         class="l-flex-row flex-elem grows object-header"> | ||||
|     </mct-representation> | ||||
|     <div class='buttons-main btn-bar buttons abs'> | ||||
|         <mct-representation key="'switcher'" | ||||
|   | ||||
| @@ -50,7 +50,7 @@ define( | ||||
|             // Simply trigger refresh of in-view objects; do not | ||||
|             // write anything to database. | ||||
|             persistence.persist = function () { | ||||
|                 cache.markDirty(editableObject); | ||||
|                 return cache.markDirty(editableObject); | ||||
|             }; | ||||
|  | ||||
|             // Delegate refresh to the original object; this avoids refreshing | ||||
|   | ||||
| @@ -111,6 +111,7 @@ define( | ||||
|          */ | ||||
|         EditableDomainObjectCache.prototype.markDirty = function (domainObject) { | ||||
|             this.dirtyObjects[domainObject.getId()] = domainObject; | ||||
|             return this.$q.when(true); | ||||
|         }; | ||||
|  | ||||
|         /** | ||||
|   | ||||
| @@ -31,6 +31,7 @@ define( | ||||
|                 mockEditableObject, | ||||
|                 mockDomainObject, | ||||
|                 mockCache, | ||||
|                 mockPromise, | ||||
|                 capability; | ||||
|  | ||||
|             beforeEach(function () { | ||||
| @@ -50,7 +51,9 @@ define( | ||||
|                     "cache", | ||||
|                     [ "markDirty" ] | ||||
|                 ); | ||||
|                 mockPromise = jasmine.createSpyObj("promise", ["then"]); | ||||
|  | ||||
|                 mockCache.markDirty.andReturn(mockPromise); | ||||
|                 mockDomainObject.getCapability.andReturn(mockPersistence); | ||||
|  | ||||
|                 capability = new EditablePersistenceCapability( | ||||
| @@ -84,6 +87,10 @@ define( | ||||
|                 expect(mockPersistence.refresh).toHaveBeenCalled(); | ||||
|             }); | ||||
|  | ||||
|             it("returns a promise from persist", function () { | ||||
|                 expect(capability.persist().then).toEqual(jasmine.any(Function)); | ||||
|             }); | ||||
|  | ||||
|         }); | ||||
|     } | ||||
| ); | ||||
| @@ -18,7 +18,11 @@ | ||||
|         "runs": [ | ||||
|             { | ||||
|                 "implementation": "StyleSheetLoader.js", | ||||
|                 "depends": [ "stylesheets[]", "$document" ] | ||||
|                 "depends": [ "stylesheets[]", "$document", "THEME" ] | ||||
|             }, | ||||
|             { | ||||
|                 "implementation": "UnsupportedBrowserWarning.js", | ||||
|                 "depends": [ "notificationService", "agentService" ] | ||||
|             } | ||||
|         ], | ||||
|         "stylesheets": [ | ||||
| @@ -194,6 +198,11 @@ | ||||
|             { | ||||
|                 "key": "MCT_SCROLL_Y_ATTRIBUTE", | ||||
|                 "value": "mctScrollY" | ||||
|             }, | ||||
|             { | ||||
|                 "key": "THEME", | ||||
|                 "value": "unspecified", | ||||
|                 "priority": "fallback" | ||||
|             } | ||||
|         ], | ||||
|         "containers": [ | ||||
| @@ -220,10 +229,6 @@ | ||||
|                 "templateUrl": "templates/subtree.html", | ||||
|                 "uses": [ "composition" ] | ||||
|             }, | ||||
|             { | ||||
|                 "key": "test", | ||||
|                 "templateUrl": "templates/test.html" | ||||
|             }, | ||||
|             { | ||||
|                 "key": "tree-node", | ||||
|                 "templateUrl": "templates/tree-node.html", | ||||
|   | ||||
| @@ -1,19 +1,27 @@ | ||||
| { | ||||
| 	"metadata": { | ||||
| 		"name": "WTD Symbols", | ||||
| 		"lastOpened": 1446490786311, | ||||
| 		"created": 1446489891263 | ||||
| 		"lastOpened": 1446670352108, | ||||
| 		"created": 1446670349721 | ||||
| 	}, | ||||
| 	"iconSets": [ | ||||
| 		{ | ||||
| 			"selection": [ | ||||
| 				{ | ||||
| 					"order": 113, | ||||
| 					"order": 116, | ||||
| 					"id": 93, | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58902, | ||||
| 					"name": "icon-eye-open-no-gleam", | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 115, | ||||
| 					"id": 92, | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58901, | ||||
| 					"name": "icon-crosshair", | ||||
| 					"tempChar": "" | ||||
| 					"name": "icon-eye-open", | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 110, | ||||
| @@ -21,7 +29,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58899, | ||||
| 					"name": "icon-collapse-pane-left", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 111, | ||||
| @@ -29,7 +37,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58900, | ||||
| 					"name": "icon-collapse-pane-right", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 109, | ||||
| @@ -37,7 +45,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58898, | ||||
| 					"name": "icon-save", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 108, | ||||
| @@ -45,7 +53,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58897, | ||||
| 					"name": "icon-dataset", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 90, | ||||
| @@ -53,7 +61,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58896, | ||||
| 					"name": "icon-bell", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 91, | ||||
| @@ -61,7 +69,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58889, | ||||
| 					"name": "icon-hourglass", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 92, | ||||
| @@ -74,7 +82,7 @@ | ||||
| 						58890 | ||||
| 					], | ||||
| 					"name": "icon-info-v15", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 93, | ||||
| @@ -82,7 +90,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58887, | ||||
| 					"name": "icon-x-in-circle", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 94, | ||||
| @@ -90,7 +98,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58881, | ||||
| 					"name": "icon-datatable", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 95, | ||||
| @@ -98,7 +106,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58882, | ||||
| 					"name": "icon-tabular-scrolling", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 96, | ||||
| @@ -106,7 +114,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58884, | ||||
| 					"name": "icon-tabular", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 97, | ||||
| @@ -114,7 +122,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58885, | ||||
| 					"name": "icon-calendar", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 98, | ||||
| @@ -122,7 +130,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58886, | ||||
| 					"name": "icon-paint-bucket", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 99, | ||||
| @@ -130,7 +138,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 123, | ||||
| 					"name": "icon-pointer-left", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 100, | ||||
| @@ -138,7 +146,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 125, | ||||
| 					"name": "icon-pointer-right", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 101, | ||||
| @@ -146,7 +154,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 80, | ||||
| 					"name": "icon-person", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 102, | ||||
| @@ -154,7 +162,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 232, | ||||
| 					"name": "icon-chain-links", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 103, | ||||
| @@ -162,7 +170,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 115, | ||||
| 					"name": "icon-database-in-brackets", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 104, | ||||
| @@ -170,7 +178,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 114, | ||||
| 					"name": "icon-refresh", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 105, | ||||
| @@ -178,7 +186,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 108, | ||||
| 					"name": "icon-lock", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 106, | ||||
| @@ -186,7 +194,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 51, | ||||
| 					"name": "icon-box-with-dashed-lines", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 10, | ||||
| @@ -194,7 +202,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58880, | ||||
| 					"name": "icon-box-with-arrow-cursor", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 11, | ||||
| @@ -202,7 +210,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 65, | ||||
| 					"name": "icon-activity-mode", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 12, | ||||
| @@ -210,7 +218,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 97, | ||||
| 					"name": "icon-activity", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 87, | ||||
| @@ -218,7 +226,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 33, | ||||
| 					"name": "icon-alert-rect", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 14, | ||||
| @@ -226,7 +234,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58883, | ||||
| 					"name": "icon-alert-triangle", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 15, | ||||
| @@ -234,7 +242,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 238, | ||||
| 					"name": "icon-arrow-double-down", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 16, | ||||
| @@ -242,7 +250,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 235, | ||||
| 					"name": "icon-arrow-double-up", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 2, | ||||
| @@ -250,7 +258,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 118, | ||||
| 					"name": "icon-arrow-down", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 19, | ||||
| @@ -258,7 +266,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 60, | ||||
| 					"name": "icon-arrow-left", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 20, | ||||
| @@ -266,7 +274,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 62, | ||||
| 					"name": "icon-arrow-right", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 21, | ||||
| @@ -274,7 +282,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 236, | ||||
| 					"name": "icon-arrow-tall-down", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 22, | ||||
| @@ -282,7 +290,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 237, | ||||
| 					"name": "icon-arrow-tall-up", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 23, | ||||
| @@ -290,7 +298,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 94, | ||||
| 					"name": "icon-arrow-up", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 24, | ||||
| @@ -298,7 +306,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 73, | ||||
| 					"name": "icon-arrows-out", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 25, | ||||
| @@ -306,7 +314,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58893, | ||||
| 					"name": "icon-arrows-right-left", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 33, | ||||
| @@ -314,7 +322,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 53, | ||||
| 					"name": "icon-arrows-up-down", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 26, | ||||
| @@ -322,7 +330,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 42, | ||||
| 					"name": "icon-asterisk", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 27, | ||||
| @@ -330,7 +338,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 72, | ||||
| 					"name": "icon-autoflow-tabular", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 28, | ||||
| @@ -338,7 +346,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 224, | ||||
| 					"name": "icon-box", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 29, | ||||
| @@ -346,7 +354,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 50, | ||||
| 					"name": "icon-check", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 30, | ||||
| @@ -354,7 +362,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 67, | ||||
| 					"name": "icon-clock", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 31, | ||||
| @@ -362,7 +370,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 46, | ||||
| 					"name": "icon-connectivity", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 32, | ||||
| @@ -370,7 +378,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 100, | ||||
| 					"name": "icon-database-query", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 17, | ||||
| @@ -378,7 +386,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 68, | ||||
| 					"name": "icon-database", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 35, | ||||
| @@ -386,7 +394,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 81, | ||||
| 					"name": "icon-dictionary", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 36, | ||||
| @@ -394,7 +402,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 242, | ||||
| 					"name": "icon-duplicate", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 37, | ||||
| @@ -402,7 +410,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 102, | ||||
| 					"name": "icon-folder-new", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 38, | ||||
| @@ -410,7 +418,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 70, | ||||
| 					"name": "icon-folder", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 39, | ||||
| @@ -418,7 +426,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 95, | ||||
| 					"name": "icon-fullscreen-collapse", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 40, | ||||
| @@ -426,7 +434,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 122, | ||||
| 					"name": "icon-fullscreen-expand", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 41, | ||||
| @@ -434,7 +442,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 71, | ||||
| 					"name": "icon-gear", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 49, | ||||
| @@ -442,7 +450,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 227, | ||||
| 					"name": "icon-image", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 42, | ||||
| @@ -450,7 +458,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 225, | ||||
| 					"name": "icon-layers", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 43, | ||||
| @@ -458,7 +466,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 76, | ||||
| 					"name": "icon-layout", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 44, | ||||
| @@ -466,7 +474,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 226, | ||||
| 					"name": "icon-line-horz", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 75, | ||||
| @@ -474,7 +482,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 244, | ||||
| 					"name": "icon-link", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 46, | ||||
| @@ -482,7 +490,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 88, | ||||
| 					"name": "icon-magnify-in", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 47, | ||||
| @@ -490,7 +498,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 89, | ||||
| 					"name": "icon-magnify-out", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 48, | ||||
| @@ -498,7 +506,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 77, | ||||
| 					"name": "icon-magnify", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 34, | ||||
| @@ -506,7 +514,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 109, | ||||
| 					"name": "icon-menu", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 50, | ||||
| @@ -514,7 +522,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 243, | ||||
| 					"name": "icon-move", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 51, | ||||
| @@ -522,7 +530,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 121, | ||||
| 					"name": "icon-new-window", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 52, | ||||
| @@ -530,7 +538,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 111, | ||||
| 					"name": "icon-object", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 73, | ||||
| @@ -538,7 +546,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 63, | ||||
| 					"name": "icon-object-unknown", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 53, | ||||
| @@ -546,7 +554,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 86, | ||||
| 					"name": "icon-packet", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 54, | ||||
| @@ -554,7 +562,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 234, | ||||
| 					"name": "icon-page", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 55, | ||||
| @@ -562,7 +570,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 241, | ||||
| 					"name": "icon-pause", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 56, | ||||
| @@ -570,7 +578,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 112, | ||||
| 					"name": "icon-pencil", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 65, | ||||
| @@ -578,7 +586,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 79, | ||||
| 					"name": "icon-people", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 57, | ||||
| @@ -586,7 +594,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 239, | ||||
| 					"name": "icon-play", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 58, | ||||
| @@ -594,7 +602,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 233, | ||||
| 					"name": "icon-plot-resource", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 59, | ||||
| @@ -602,7 +610,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 43, | ||||
| 					"name": "icon-plus", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 60, | ||||
| @@ -610,7 +618,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 45, | ||||
| 					"name": "icon-minus", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 61, | ||||
| @@ -618,7 +626,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 54, | ||||
| 					"name": "icon-sine", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 62, | ||||
| @@ -626,7 +634,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 228, | ||||
| 					"name": "icon-T", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 63, | ||||
| @@ -634,7 +642,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 116, | ||||
| 					"name": "icon-telemetry-panel", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 64, | ||||
| @@ -642,7 +650,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 84, | ||||
| 					"name": "icon-telemetry", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 18, | ||||
| @@ -650,7 +658,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 246, | ||||
| 					"name": "icon-thumbs-strip", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 67, | ||||
| @@ -658,7 +666,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 83, | ||||
| 					"name": "icon-timeline", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 68, | ||||
| @@ -666,7 +674,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 245, | ||||
| 					"name": "icon-timer", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 69, | ||||
| @@ -674,7 +682,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 90, | ||||
| 					"name": "icon-trash", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 70, | ||||
| @@ -682,7 +690,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 229, | ||||
| 					"name": "icon-two-parts-both", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 71, | ||||
| @@ -690,7 +698,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 231, | ||||
| 					"name": "icon-two-parts-one-only", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 72, | ||||
| @@ -698,7 +706,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 120, | ||||
| 					"name": "icon-x-heavy", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				}, | ||||
| 				{ | ||||
| 					"order": 66, | ||||
| @@ -706,7 +714,7 @@ | ||||
| 					"prevSize": 32, | ||||
| 					"code": 58946, | ||||
| 					"name": "icon-x", | ||||
| 					"tempChar": "" | ||||
| 					"tempChar": "" | ||||
| 				} | ||||
| 			], | ||||
| 			"id": 2, | ||||
| @@ -722,13 +730,43 @@ | ||||
| 			"prevSize": 32, | ||||
| 			"icons": [ | ||||
| 				{ | ||||
| 					"id": 92, | ||||
| 					"id": 93, | ||||
| 					"paths": [ | ||||
| 						"M514 2c-282.8 0-512 229.2-512 512s229.2 512 512 512 512-229.2 512-512-229.2-512-512-512zM860.2 450h-282.2v-282.2c69.6 12.8 133.8 46.2 185 97.4 51 51 84.4 115.2 97.2 184.8zM450 167.8v282.2h-282.2c12.8-69.6 46.2-133.8 97.4-185 51-51 115.2-84.4 184.8-97.2zM167.8 578h282.2v282.2c-69.6-12.8-133.8-46.2-185-97.4-51-51-84.4-115.2-97.2-184.8zM578 860.2v-282.2h282.2c-12.8 69.6-46.2 133.8-97.4 185-51 51-115.2 84.4-184.8 97.2z" | ||||
| 						"M512 64c-261 0-480.6 195.4-512 448 31.4 252.6 251 448 512 448s480.6-195.4 512-448c-31.4-252.6-251-448-512-448zM768.2 734.6c-71.4 62.8-162.8 97.4-257.6 97.4s-186.2-34.6-257.6-97.4c-66.6-58.6-110.6-137.2-125-222.6 0 0 0-0.2 0-0.2 76.8-154 220.8-257.6 384-257.6s307.2 103.8 384 257.6c0 0 0 0.2 0 0.2-14.4 85.4-61.2 164-127.8 222.6z", | ||||
| 						"M512 288c-123.8 0-224 100.2-224 224s100.2 224 224 224 224-100.2 224-224-100.2-224-224-224zM576 544c-53 0-96-43-96-96s43-96 96-96 96 43 96 96c0 53-43 96-96 96z" | ||||
| 					], | ||||
| 					"attrs": [ | ||||
| 						{ | ||||
| 							"fill": "rgb(0, 0, 0)" | ||||
| 							"fill": "rgb(6, 161, 75)" | ||||
| 						}, | ||||
| 						{ | ||||
| 							"fill": "rgb(6, 161, 75)" | ||||
| 						} | ||||
| 					], | ||||
| 					"isMulticolor": false, | ||||
| 					"grid": 0, | ||||
| 					"tags": [ | ||||
| 						"icon-eye-open-no-gleam" | ||||
| 					], | ||||
| 					"colorPermutations": { | ||||
| 						"125525525516161751": [ | ||||
| 							1, | ||||
| 							1 | ||||
| 						] | ||||
| 					} | ||||
| 				}, | ||||
| 				{ | ||||
| 					"id": 92, | ||||
| 					"paths": [ | ||||
| 						"M512 64c-261 0-480.6 195.4-512 448 31.4 252.6 251 448 512 448s480.6-195.4 512-448c-31.4-252.6-251-448-512-448zM768.2 734.6c-71.4 62.8-162.8 97.4-257.6 97.4s-186.2-34.6-257.6-97.4c-66.6-58.6-110.6-137.2-125-222.6 0 0 0-0.2 0-0.2 76.8-154 220.8-257.6 384-257.6s307.2 103.8 384 257.6c0 0 0 0.2 0 0.2-14.4 85.4-61.2 164-127.8 222.6z", | ||||
| 						"M512 288c-123.8 0-224 100.2-224 224s100.2 224 224 224 224-100.2 224-224-100.2-224-224-224z" | ||||
| 					], | ||||
| 					"attrs": [ | ||||
| 						{ | ||||
| 							"fill": "rgb(6, 161, 75)" | ||||
| 						}, | ||||
| 						{ | ||||
| 							"fill": "rgb(6, 161, 75)" | ||||
| 						} | ||||
| 					], | ||||
| 					"isMulticolor": false, | ||||
| @@ -738,7 +776,8 @@ | ||||
| 					], | ||||
| 					"colorPermutations": { | ||||
| 						"125525525516161751": [ | ||||
| 							0 | ||||
| 							1, | ||||
| 							1 | ||||
| 						] | ||||
| 					} | ||||
| 				}, | ||||
|   | ||||
										
											Binary file not shown.
										
									
								
							| @@ -92,6 +92,7 @@ | ||||
| <glyph unicode="" glyph-name="icon-save" d="M192.2 384c-0.2 0-0.2 0 0 0l-0.2-448h640v447.8c0 0 0 0-0.2 0.2h-639.6zM978.8 749.2l-165.4 165.4c-25 25-74.2 45.4-109.4 45.4h-576c-70.4 0-128-57.6-128-128v-768c0-70.4 57.6-128 128-128v448c0 35.2 28.8 64 64 64h640c35.2 0 64-28.8 64-64v-448c70.4 0 128 57.6 128 128v576c0 35.2-20.4 84.4-45.2 109.2zM704 704c0-35.2-28.8-64-64-64h-448c-35.2 0-64 28.8-64 64v192h320v-192h128v192h128v-192z" /> | ||||
| <glyph unicode="" glyph-name="icon-collapse-pane-left" d="M256 960h-256v-1024h256c105.6 0 192 86.4 192 192v640c0 105.6-86.4 192-192 192zM512 640l512-320v640z" /> | ||||
| <glyph unicode="" glyph-name="icon-collapse-pane-right" d="M768 960h256v-1024h-256c-105.6 0-192 86.4-192 192v640c0 105.6 86.4 192 192 192zM512 640l-512-320v640z" /> | ||||
| <glyph unicode="" glyph-name="icon-crosshair" d="M514 958c-282.8 0-512-229.2-512-512s229.2-512 512-512 512 229.2 512 512-229.2 512-512 512zM860.2 510h-282.2v282.2c69.6-12.8 133.8-46.2 185-97.4 51-51 84.4-115.2 97.2-184.8zM450 792.2v-282.2h-282.2c12.8 69.6 46.2 133.8 97.4 185 51 51 115.2 84.4 184.8 97.2zM167.8 382h282.2v-282.2c-69.6 12.8-133.8 46.2-185 97.4-51 51-84.4 115.2-97.2 184.8zM578 99.8v282.2h282.2c-12.8-69.6-46.2-133.8-97.4-185-51-51-115.2-84.4-184.8-97.2z" /> | ||||
| <glyph unicode="" glyph-name="icon-eye-open" d="M512 896c-261 0-480.6-195.4-512-448 31.4-252.6 251-448 512-448s480.6 195.4 512 448c-31.4 252.6-251 448-512 448zM768.2 225.4c-71.4-62.8-162.8-97.4-257.6-97.4s-186.2 34.6-257.6 97.4c-66.6 58.6-110.6 137.2-125 222.6 0 0 0 0.2 0 0.2 76.8 154 220.8 257.6 384 257.6s307.2-103.8 384-257.6c0 0 0-0.2 0-0.2-14.4-85.4-61.2-164-127.8-222.6zM512 672c-123.8 0-224-100.2-224-224s100.2-224 224-224 224 100.2 224 224-100.2 224-224 224z" /> | ||||
| <glyph unicode="" glyph-name="icon-eye-open-no-gleam" d="M512 896c-261 0-480.6-195.4-512-448 31.4-252.6 251-448 512-448s480.6 195.4 512 448c-31.4 252.6-251 448-512 448zM768.2 225.4c-71.4-62.8-162.8-97.4-257.6-97.4s-186.2 34.6-257.6 97.4c-66.6 58.6-110.6 137.2-125 222.6 0 0 0 0.2 0 0.2 76.8 154 220.8 257.6 384 257.6s307.2-103.8 384-257.6c0 0 0-0.2 0-0.2-14.4-85.4-61.2-164-127.8-222.6zM512 672c-123.8 0-224-100.2-224-224s100.2-224 224-224 224 100.2 224 224-100.2 224-224 224zM576 416c-53 0-96 43-96 96s43 96 96 96 96-43 96-96c0-53-43-96-96-96z" /> | ||||
| <glyph unicode="" glyph-name="icon-x" d="M384 448l-365.332-365.332c-24.89-24.89-24.89-65.62 0-90.51l37.49-37.49c24.89-24.89 65.62-24.89 90.51 0 0 0 365.332 365.332 365.332 365.332l365.332-365.332c24.89-24.89 65.62-24.89 90.51 0l37.49 37.49c24.89 24.89 24.89 65.62 0 90.51l-365.332 365.332c0 0 365.332 365.332 365.332 365.332 24.89 24.89 24.89 65.62 0 90.51l-37.49 37.49c-24.89 24.89-65.62 24.89-90.51 0 0 0-365.332-365.332-365.332-365.332l-365.332 365.332c-24.89 24.89-65.62 24.89-90.51 0l-37.49-37.49c-24.89-24.89-24.89-65.62 0-90.51 0 0 365.332-365.332 365.332-365.332z" /> | ||||
| </font></defs></svg> | ||||
| Before Width: | Height: | Size: 29 KiB After Width: | Height: | Size: 29 KiB | 
										
											Binary file not shown.
										
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										147
									
								
								platform/commonUI/general/res/sass/_archetypes.scss
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										147
									
								
								platform/commonUI/general/res/sass/_archetypes.scss
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,147 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
|  | ||||
| /********************************************* COLUMN LAYOUTS STYLES */ | ||||
| @mixin cols($totalCols, $span) { | ||||
|     $cw: 100% / $totalCols; | ||||
|     min-width: (500px / $totalCols) * $span; | ||||
|     @if ($totalCols != $span) { | ||||
|         width: ($cw * $span) - $ueColMargin; | ||||
|     } @else { | ||||
|         width: $cw; | ||||
|     } | ||||
| } | ||||
|  | ||||
| .cols { | ||||
|     @include clearfix; | ||||
|     .col { | ||||
|         @include box-sizing(border-box); | ||||
|         @include clearfix; | ||||
|         float: left; | ||||
|         margin-left: $ueColMargin; | ||||
|         padding-left: $interiorMargin; | ||||
|         position: relative; | ||||
|         &:first-child { | ||||
|             margin-left: 0; | ||||
|             padding-left: 0; | ||||
|         } | ||||
|     } | ||||
|     &.cols-2 { | ||||
|         $nc: 2; | ||||
|         .col-1 { | ||||
|             @include cols($nc, 1); | ||||
|         } | ||||
|     } | ||||
|     &.cols-2-ff { | ||||
|         // 2 columns, first column is fixed, second is fluid | ||||
|         .col-100px { | ||||
|             width: 100px; | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     &.cols-6 { | ||||
|         $nc: 6; | ||||
|         .col-1 { | ||||
|             @include cols($nc, 1); | ||||
|         } | ||||
|     } | ||||
|     &.cols-16 { | ||||
|         $nc: 16; | ||||
|         .col-1 { | ||||
|             @include cols($nc, 1); | ||||
|         } | ||||
|         .col-2 { | ||||
|             @include cols($nc, 2); | ||||
|         } | ||||
|         .col-7 { | ||||
|             @include cols($nc, 7); | ||||
|         } | ||||
|     } | ||||
|     &.cols-32 { | ||||
|         $nc: 32; | ||||
|         .col-2 { | ||||
|             @include cols($nc, 2); | ||||
|         } | ||||
|         .col-15 { | ||||
|             @include cols($nc, 15); | ||||
|         } | ||||
|     } | ||||
|     .l-row { | ||||
|         @include clearfix; | ||||
|         padding: $interiorMargin 0; | ||||
|     } | ||||
| } | ||||
|  | ||||
| /********************************************* FLEX STYLES */ | ||||
| .l-flex-row, | ||||
| .l-flex-col { | ||||
|     @include display-flex; | ||||
|     @include flex-wrap(nowrap); | ||||
|     .flex-elem { | ||||
|         min-height: 0; // Needed to allow element to shrink within parent | ||||
|         position: relative; | ||||
|         &:not(.grows) { | ||||
|             @include flex(0 0 auto); | ||||
|             &.flex-can-shrink { | ||||
|                 @include flex(0 1 auto); | ||||
|             } | ||||
|         } | ||||
|         &.grows { | ||||
|             @include flex(1 1 auto); | ||||
|         } | ||||
|     } | ||||
|     .flex-container { | ||||
|         // Apply to wrapping elements, mct-includes, etc. | ||||
|         @include display-flex; | ||||
|         @include flex-wrap(nowrap); | ||||
|         @include flex(1 1 auto); | ||||
|         min-height:0; | ||||
|     } | ||||
| } | ||||
|  | ||||
| .l-flex-row { | ||||
|     @include flex-direction(row); | ||||
|     &.flex-elem { @include flex(1 1 auto); } | ||||
|     .flex-elem { | ||||
|         height: inherit; | ||||
|         line-height: inherit; | ||||
|         min-width: 0; | ||||
|     } | ||||
|     .flex-container { @include flex-direction(row); } | ||||
| } | ||||
|  | ||||
| .l-flex-col { | ||||
|     @include flex-direction(column); | ||||
|     .flex-elem { | ||||
|         min-height: 0; | ||||
|         &.holder:not(:last-child) { margin-bottom: $interiorMarginLg; } | ||||
|     } | ||||
|     .flex-container { @include flex-direction(column); } | ||||
| } | ||||
|  | ||||
| .flex-fixed { | ||||
|     @include flex(0 0 auto); | ||||
| } | ||||
|  | ||||
| .flex-justify-end { | ||||
|     @include justify-content(flex-end); | ||||
| } | ||||
| @@ -35,21 +35,29 @@ $ltGamma: 20%; | ||||
| $btnFontSizeToH: 0.45; | ||||
|  | ||||
| /************************** LAYOUT */ | ||||
| $ueTopBarH: 24px; // Change when breadcrumb is enabled | ||||
| $ueTopBarH: 24px; | ||||
| $ueTopBarEditH: 30px; | ||||
| $ueTopBarBtnH: 35px; | ||||
| $ueFooterH: 25px; | ||||
| $ueColMargin: 1.5%; | ||||
| $ueAppLogoW: 105px; | ||||
| $ueEditToolBarH: 25px; | ||||
| $ueBrowseLeftPaneTreeW: 25%; | ||||
| $ueBrowseRightPaneInspectW: 20%; | ||||
| $ueCollapsedPaneEdgeM: 20px; | ||||
| $ueCollapsedPaneEdgeM: 22px; | ||||
| $uePaneMiniTabH: $ueTopBarH; | ||||
| $uePaneMiniTabW: 9px; | ||||
| $uePaneMiniTabCollapsedW: 11px; | ||||
| $ueEditLeftPaneW: 75%; | ||||
| $treeSearchInputBarH: 25px; | ||||
| $ueTimeControlH: (33px, 20px, 20px); | ||||
| // Panes | ||||
| $ueBrowseLeftPaneTreeMinW: 150px; | ||||
| $ueBrowseLeftPaneTreeMaxW: 35%; | ||||
| $ueBrowseLeftPaneTreeW: 25%; | ||||
| $ueBrowseRightPaneInspectMinW: 200px; | ||||
| $ueBrowseRightPaneInspectMaxW: 35%; | ||||
| $ueBrowseRightPaneInspectW: 20%; | ||||
| $ueDesktopMinW: 600px; | ||||
|  | ||||
| // Overlay | ||||
| $ovrTopBarH: 45px; | ||||
| $ovrFooterH: 24px; | ||||
|   | ||||
| @@ -142,6 +142,16 @@ mct-container { | ||||
| 	display: none !important; | ||||
| } | ||||
|  | ||||
| .off { | ||||
|     visibility: hidden; | ||||
|     opacity: 0; | ||||
|     height: 0; | ||||
|     margin: 0; | ||||
|     padding: 0; | ||||
|     border: 0; | ||||
|     margin: 0 !important; | ||||
| } | ||||
|  | ||||
| .sep { | ||||
| 	color: rgba(#fff, 0.2); | ||||
| } | ||||
| @@ -43,6 +43,11 @@ | ||||
|             vertical-align: bottom; | ||||
|         } | ||||
|     } | ||||
|      | ||||
|     ul { | ||||
|         @include box-sizing(border-box); | ||||
|         padding-right: $interiorMargin; | ||||
|     } | ||||
|  | ||||
|     ul li, | ||||
|     em { | ||||
|   | ||||
| @@ -21,6 +21,7 @@ | ||||
|  *****************************************************************************/ | ||||
| @import "effects"; | ||||
| @import "global"; | ||||
| @import "archetypes"; | ||||
| @import "about"; | ||||
| @import "text"; | ||||
| @import "icons"; | ||||
|   | ||||
| @@ -95,10 +95,7 @@ $pad: $interiorMargin * $baseRatio; | ||||
|  | ||||
| .s-icon-btn { | ||||
|     @extend .ui-symbol; | ||||
|     color: $colorBtnIcon; | ||||
|     &:hover { | ||||
|         color: lighten($colorBtnIcon, $ltGamma); | ||||
|     } | ||||
|     // Color and styling additionally in _controls.scss | ||||
| } | ||||
|  | ||||
| .mini-tab { | ||||
| @@ -225,6 +222,11 @@ $pad: $interiorMargin * $baseRatio; | ||||
|         overflow: hidden; | ||||
|         word-break: break-all; | ||||
|  | ||||
|         &.collapsed { | ||||
|             $d: $uePaneMiniTabCollapsedW; | ||||
|             width: $d; font-size: $d; | ||||
|         } | ||||
|  | ||||
|         &:before, | ||||
|         &:after { | ||||
|             position: absolute; | ||||
|   | ||||
| @@ -127,7 +127,6 @@ label.checkbox.custom { | ||||
|         &:before { | ||||
|             @include border-radius($basicCr * .75); | ||||
|             background: $bg; | ||||
|             //border-bottom: 1px solid lighten($bg, 10%); | ||||
|             @include box-shadow(inset rgba(black, 0.4) 0 1px 2px); | ||||
|             box-sizing: border-box; | ||||
|             content: " "; | ||||
| @@ -188,7 +187,8 @@ label.checkbox.custom { | ||||
|     } | ||||
| } | ||||
|  | ||||
| .context-available { | ||||
| .context-available, | ||||
| .s-icon-btn { | ||||
|     $c: $colorKey; | ||||
|     color: $c; | ||||
|     &:hover { | ||||
| @@ -202,7 +202,6 @@ label.checkbox.custom { | ||||
|  | ||||
| /******************************************************** OBJECT-HEADER */ | ||||
| .object-header { | ||||
|     //@include test(); | ||||
|     font-size: 1em; | ||||
|  | ||||
|     > .type-icon { | ||||
| @@ -213,8 +212,6 @@ label.checkbox.custom { | ||||
|     } | ||||
|  | ||||
|     .l-elem-wrapper { | ||||
|         //@include test(#66f, 0.2); | ||||
|         @include justify-content(flex-start); | ||||
|         mct-representation { | ||||
|             // Holds the context-available item | ||||
|             // Must have min-width to make flex work properly | ||||
| @@ -228,19 +225,15 @@ label.checkbox.custom { | ||||
|     } | ||||
|  | ||||
|     .title-label { | ||||
|         //@include test(green, 0.9); | ||||
|         color: $colorObjHdrTxt; | ||||
|         @include ellipsize(); | ||||
|         //color: pushBack($colorBodyFg, 40%); | ||||
|         @include webkitProp(flex, '0 1 auto'); | ||||
|         padding-right: 0.35em; // For context arrow. Done with em's so pad is relative to the scale of the text. | ||||
|         //position: relative; | ||||
|     } | ||||
|  | ||||
|     .context-available { | ||||
|         font-size: 0.7em; | ||||
|         @include webkitProp(flex, '0 0 1'); | ||||
|         //margin-right: $interiorMargin; | ||||
|     } | ||||
|  | ||||
|     @include desktop { | ||||
| @@ -303,7 +296,6 @@ label.checkbox.custom { | ||||
|     @include border-radius($basicCr); | ||||
|     @include boxIncised(0.3, 4px); | ||||
|     background: $colorProgressBarOuter; | ||||
|     //border:1px solid $colorProgressBarOuter; | ||||
|     .progress-amt { | ||||
|         @include border-radius($basicCr); | ||||
|         @include boxShdw(); | ||||
| @@ -343,8 +335,6 @@ label.checkbox.custom { | ||||
| .slider { | ||||
|     $knobH: 100%; //14px; | ||||
|     .slot { | ||||
|         //        @include border-radius($basicCr * .75); | ||||
|         //@include sliderTrack(); | ||||
|         width: auto; | ||||
|         position: absolute; | ||||
|         top: 0; | ||||
| @@ -400,14 +390,11 @@ label.checkbox.custom { | ||||
|     width: 230px; | ||||
|     .l-month-year-pager { | ||||
|         $pagerW: 20px; | ||||
|         //@include test(); | ||||
|         //font-size: 0.8rem; | ||||
|         height: $r1H; | ||||
|         margin-bottom: $interiorMargin; | ||||
|         position: relative; | ||||
|         .pager, | ||||
|         .val { | ||||
|             //@include test(red); | ||||
|             @extend .abs; | ||||
|         } | ||||
|         .pager { | ||||
| @@ -454,7 +441,6 @@ label.checkbox.custom { | ||||
|         } | ||||
|         li { | ||||
|             @include flex(1 0); | ||||
|             //@include test(); | ||||
|             margin-left: 1px; | ||||
|             padding: $interiorMargin; | ||||
|             text-align: center; | ||||
| @@ -512,8 +498,6 @@ label.checkbox.custom { | ||||
|         @include background-image(linear-gradient(lighten($bg, $gr), $bg 20px)); | ||||
|         @include border-radius(2px); | ||||
|         @include box-sizing(border-box); | ||||
|         //@include boxShdwSubtle(); | ||||
|         //border-top: 1px solid lighten($bg, 20%); | ||||
|         &:hover { | ||||
|             @include background-image(linear-gradient(lighten($hc, $gr), $hc 20px)); | ||||
|         } | ||||
|   | ||||
| @@ -1,46 +1,32 @@ | ||||
| .l-time-display { | ||||
| 	$transTime: 200ms; | ||||
| 	// Layout | ||||
|     line-height: 140%; | ||||
| 	&:hover { | ||||
| 		.l-btn.control { | ||||
| 			opacity: 1; | ||||
| 		} | ||||
| 	} | ||||
| 	.l-elem-wrapper { | ||||
| 		position: relative; | ||||
| 	} | ||||
| 	.l-elem { | ||||
| 		display: inline-block; | ||||
| 	} | ||||
|  | ||||
| 	&.l-timer { | ||||
| 		.l-elem.l-value { | ||||
| 			@include trans-prop-nice(left, $transTime); | ||||
| 			position: absolute; | ||||
| 			left: 0; | ||||
| 			z-index: 1; | ||||
| 			.ui-symbol.direction { | ||||
| 				font-size: 0.8em; | ||||
| 			} | ||||
| 		} | ||||
| 		&:hover .l-elem.l-value { | ||||
| 			left: 20px; | ||||
|         .control { | ||||
|             @include trans-prop-nice((width, opacity), $transTime); | ||||
|             line-height: inherit; | ||||
|             margin-right: 0; | ||||
|             opacity: 0; | ||||
|             width: 0; | ||||
|         } | ||||
| 		&:hover .control { | ||||
|             margin-right: $interiorMargin; | ||||
|             opacity: 1; | ||||
| 			width: 1em; | ||||
| 		} | ||||
| 	} | ||||
|  | ||||
| 	// Look-and-feel | ||||
| 	.l-elem { | ||||
| 		.value.active, | ||||
| 		&.value.active { | ||||
| 			color: $colorKeyFg; | ||||
| 		} | ||||
| 	} | ||||
| 	.l-btn.control { | ||||
| 		@include trans-prop-nice-fade($transTime); | ||||
| 		opacity: 0; | ||||
| 		font-size: 0.65em; | ||||
| 		vertical-align: top; | ||||
| 		//line-height: 1em; | ||||
| 	} | ||||
|  | ||||
|     .value { | ||||
|         color: pullForward($colorBodyFg, 50%); | ||||
|         font-weight: 400; | ||||
|         .direction { | ||||
|             font-size: 0.8em; | ||||
|         } | ||||
|     } | ||||
| } | ||||
|   | ||||
| @@ -25,7 +25,6 @@ | ||||
| 	    margin: 0 0 2px 0; // Needed to avoid dropshadow from being clipped by parent containers | ||||
|     } | ||||
| 	padding: 0 $interiorMargin; | ||||
|     overflow: hidden; | ||||
| 	position: relative; | ||||
|     line-height: $formInputH; | ||||
| 	select { | ||||
|   | ||||
| @@ -29,7 +29,7 @@ | ||||
|     //@include test(red); | ||||
|     display: block; | ||||
|     position: absolute; | ||||
|     z-index: 1; | ||||
|     z-index: 3; | ||||
|     &:after { | ||||
|         // The handle | ||||
|         content:""; | ||||
| @@ -43,7 +43,6 @@ | ||||
|         } | ||||
|     } | ||||
|     &:active { | ||||
|         //@include test(); | ||||
|         &:after { | ||||
|             background-color: $colorSplitterActive !important; | ||||
|         } | ||||
| @@ -122,11 +121,3 @@ | ||||
|         } | ||||
|     } | ||||
| } | ||||
|  | ||||
| /*.browse-area .splitter { | ||||
| 	top: 0; //$ueTopBarH + $interiorMarginLg; | ||||
| } | ||||
|  | ||||
| .edit-area .splitter { | ||||
| 	top: 0; | ||||
| }*/ | ||||
|   | ||||
| @@ -20,6 +20,8 @@ | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
|  | ||||
| /* REQUIRES /platform/commonUI/general/res/sass/_constants.scss */ | ||||
|  | ||||
| /************************** MOBILE REPRESENTATION ITEMS DIMENSIONS */ | ||||
| $mobileListIconSize: 30px; | ||||
| $mobileTitleDescH: 35px; | ||||
| @@ -32,51 +34,31 @@ $mobileTreeItemH: 35px; | ||||
| $mobileTreeItemIndent: 20px; | ||||
| $mobileTreeRightArrowW: 30px; | ||||
|  | ||||
| /************************** WINDOW DIMENSIONS FOR RWD */ | ||||
| $phoMaxW: 514px; | ||||
| $phoMaxH: 740px; | ||||
|  | ||||
| $tabMinW: 515px; | ||||
| $tabMaxW: 799px; | ||||
|  | ||||
| $tabMinH: 741px; | ||||
| $tabMaxH: 1024px; | ||||
|  | ||||
| $compMinW: 800px; | ||||
| $compMinH: 1025px; | ||||
| /************************** DEVICE WIDTHS */ | ||||
| // IMPORTANT! Usage assumes that ranges are mutually exclusive and have no gaps | ||||
| $phoMaxW: 767px; | ||||
| $tabMinW: 768px; | ||||
| $tabMaxW: 1024px; | ||||
| $desktopMinW: 1025px; | ||||
|  | ||||
| /************************** MEDIA QUERIES: WINDOW CHECKS FOR SPECIFIC ORIENTATIONS FOR EACH DEVICE */ | ||||
| $screenPortrait: "screen and (orientation: portrait)"; | ||||
| $screenLandscape: "screen and (orientation: landscape)"; | ||||
| $screenPortrait: "(orientation: portrait)"; | ||||
| $screenLandscape: "(orientation: landscape)"; | ||||
|  | ||||
| $mobileDevice: "(max-device-width: #{$tabMaxW}) and (max-device-height: #{$tabMaxH})"; | ||||
| $mobileDeviceEmu: "(max-device-width: #{$tabMaxH}) and (max-device-height: #{$tabMaxW})"; | ||||
| //$mobileDevice: "(max-device-width: #{$tabMaxW})"; | ||||
|  | ||||
| $phonePortraitCheck: "(max-width: #{$phoMaxW}) and (max-height: #{$phoMaxH})"; | ||||
| $phoneLandscapeCheck: "(max-height: #{$phoMaxW}) and (max-width: #{$phoMaxH})"; | ||||
|  | ||||
| $tabWidPorCheck: "(min-width: #{$tabMinW}) and (max-width: #{$tabMaxW})"; | ||||
| $tabHeiPorCheck: "(min-height: #{$tabMinH}) and (max-height: #{$tabMaxH})"; | ||||
| $tabletPortraitCheck: "#{$tabWidPorCheck} and #{$tabHeiPorCheck}"; | ||||
|  | ||||
| $tabWidLanCheck: "(min-height: #{$tabMinW}) and (max-height: #{$tabMaxW})"; | ||||
| $tabHeiLanCheck: "(min-width: #{$tabMinH}) and (max-width: #{$tabMaxH})"; | ||||
| $tabletLandscapeCheck: "#{$tabWidLanCheck} and #{$tabHeiLanCheck}"; | ||||
|  | ||||
| $desktopPortraitCheck: "(min-device-width: #{$compMinW}) and (min-device-height: #{$compMinH})"; | ||||
| $desktopLandscapeCheck: "(min-device-width: #{$compMinH}) and (min-device-height: #{$compMinW})"; | ||||
| $phoneCheck: "(max-device-width: #{$phoMaxW})"; | ||||
| $tabletCheck: "(min-device-width: #{$tabMinW}) and (max-device-width: #{$tabMaxW})"; | ||||
| $desktopCheck: "(min-device-width: #{$desktopMinW}) and (-webkit-min-device-pixel-ratio: 1)"; | ||||
|  | ||||
| /************************** MEDIA QUERIES: WINDOWS FOR SPECIFIC ORIENTATIONS FOR EACH DEVICE */ | ||||
| $phonePortrait: "#{$screenPortrait} and #{$phonePortraitCheck} and #{$mobileDevice}"; | ||||
| $phoneLandscape: "#{$screenLandscape} and #{$phoneLandscapeCheck} and #{$mobileDevice}"; | ||||
| $phoneLandscapeEmu: "#{$screenLandscape} and #{$phoneLandscapeCheck} and #{$mobileDeviceEmu}"; | ||||
| $phonePortrait: "only screen and #{$screenPortrait} and #{$phoneCheck}"; | ||||
| $phoneLandscape: "only screen and #{$screenLandscape} and #{$phoneCheck}"; | ||||
|  | ||||
| $tabletPortrait: "#{$screenPortrait} and #{$tabletPortraitCheck} and #{$mobileDevice}"; | ||||
| $tabletLandscape: "#{$screenLandscape} and #{$tabletLandscapeCheck} and #{$mobileDevice}"; | ||||
| $tabletLandscapeEmu: "#{$screenLandscape} and #{$tabletLandscapeCheck} and #{$mobileDeviceEmu}"; | ||||
| $tabletPortrait: "only screen and #{$screenPortrait} and #{$tabletCheck}"; | ||||
| $tabletLandscape: "only screen and #{$screenLandscape} and #{$tabletCheck}"; | ||||
|  | ||||
| $desktopPortrait: "screen and #{$desktopPortraitCheck}"; | ||||
| $desktopLandscape: "screen and #{$desktopLandscapeCheck}"; | ||||
| $desktop: "only screen and #{$desktopCheck}"; | ||||
|  | ||||
| /************************** DEVICE PARAMETERS FOR MENUS/REPRESENTATIONS */ | ||||
| $proporMenuOnly: 90%; | ||||
|   | ||||
| @@ -36,16 +36,23 @@ | ||||
|         //@include test(); | ||||
|         @include slMenuTransitions; | ||||
|         margin-left: 0 !important; | ||||
|         #content-area { | ||||
|         .holder-object-and-inspector { | ||||
|             @include slMenuTransitions; | ||||
|             left: $bodyMargin; | ||||
|             right: $bodyMargin; | ||||
|             opacity: 1; | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     .holder.holder-create-and-search { | ||||
|         right: $bodyMargin !important; | ||||
|     .create-btn-holder { | ||||
|         // Hide the create button by default in mobile; | ||||
|         // This can be overridden by the examples/mobile bundle | ||||
|         display: none; | ||||
|     } | ||||
|  | ||||
|     .holder.holder-treeview-elements { | ||||
|         right: $bodyMargin !important; | ||||
|     } | ||||
|  | ||||
| // When the tree is hidden, these are the | ||||
|     // classes used for the left menu and the | ||||
| @@ -55,10 +62,6 @@ | ||||
|         // is hidden. | ||||
|         .pane.left.treeview { | ||||
|             @include trans-prop-nice(opacity, 150ms); | ||||
|             //right: 100% !important; | ||||
|             //width: auto !important; | ||||
|             //overflow-y: hidden; | ||||
|             //overflow-x: hidden; | ||||
|             opacity: 0 !important; | ||||
|         } | ||||
|         .pane.right.items { | ||||
| @@ -72,7 +75,6 @@ | ||||
|         // causing cut/copy/paste menu to | ||||
|         // not appear. Should me moved in | ||||
|         // future to properly work | ||||
|         //@include user-select(none); | ||||
|  | ||||
|         // Sets the left tree menu when the tree is shown. | ||||
|         .pane.left.treeview { | ||||
| @@ -100,7 +102,6 @@ | ||||
|     } | ||||
|  | ||||
|     .object-browse-bar { | ||||
|         //@include test(); | ||||
|         left: 45px !important; | ||||
|         .context-available { | ||||
|             opacity: 1 !important; | ||||
| @@ -148,7 +149,7 @@ | ||||
|         .pane.right.items { | ||||
|             left: 0 !important; | ||||
|             @include transform(translateX($proporMenuOnly)); | ||||
|             #content-area { | ||||
|             .holder-object-and-inspector { | ||||
|                 opacity: 0; | ||||
|             } | ||||
|         } | ||||
| @@ -159,4 +160,4 @@ | ||||
|     .desktop-hide { | ||||
|         display: none; | ||||
|     } | ||||
| } | ||||
| } | ||||
|   | ||||
| @@ -20,11 +20,12 @@ | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
|  | ||||
| /* REQUIRES /platform/commonUI/general/res/sass/mobile/_constants.scss */ | ||||
|  | ||||
| // Phones in any orientation | ||||
| @mixin phone { | ||||
|     @media #{$phonePortrait}, | ||||
|            #{$phoneLandscape}, | ||||
|            #{$phoneLandscapeEmu} { | ||||
|            #{$phoneLandscape} { | ||||
|         @content | ||||
|     } | ||||
| } | ||||
| @@ -38,8 +39,7 @@ | ||||
|  | ||||
| // Phones in landscape orientation | ||||
| @mixin phoneLandscape { | ||||
|     @media #{$phoneLandscape}, | ||||
|            #{$phoneLandscapeEmu} { | ||||
|     @media #{$phoneLandscape} { | ||||
|         @content | ||||
|     } | ||||
| } | ||||
| @@ -47,8 +47,7 @@ | ||||
| // Tablets in any orientation | ||||
| @mixin tablet { | ||||
|     @media #{$tabletPortrait}, | ||||
|            #{$tabletLandscape}, | ||||
|            #{$tabletLandscapeEmu} { | ||||
|            #{$tabletLandscape} { | ||||
|         @content | ||||
|     } | ||||
| } | ||||
| @@ -62,8 +61,7 @@ | ||||
|  | ||||
| // Tablets in landscape orientation | ||||
| @mixin tabletLandscape { | ||||
|     @media #{$tabletLandscape}, | ||||
|            #{$tabletLandscapeEmu} { | ||||
|     @media #{$tabletLandscape} { | ||||
|         @content | ||||
|     } | ||||
| } | ||||
| @@ -72,10 +70,8 @@ | ||||
| @mixin phoneandtablet { | ||||
|     @media #{$phonePortrait}, | ||||
|            #{$phoneLandscape}, | ||||
|            #{$phoneLandscapeEmu}, | ||||
|            #{$tabletPortrait}, | ||||
|            #{$tabletLandscape}, | ||||
|            #{$tabletLandscapeEmu} { | ||||
|            #{$tabletLandscape} { | ||||
|         @content | ||||
|     } | ||||
| } | ||||
| @@ -84,17 +80,14 @@ | ||||
| @mixin desktopandtablet { | ||||
|     @media #{$tabletPortrait}, | ||||
|            #{$tabletLandscape}, | ||||
|            #{$tabletLandscapeEmu}, | ||||
|            #{$desktopPortrait}, | ||||
|            #{$desktopLandscape} { | ||||
|            #{$desktop} { | ||||
|         @content | ||||
|     } | ||||
| } | ||||
|  | ||||
| // Desktop monitors in any orientation | ||||
| @mixin desktop { | ||||
|     @media #{$desktopPortrait}, | ||||
|            #{$desktopLandscape} { | ||||
|     @media #{$desktop} { | ||||
|         @content | ||||
|     } | ||||
| } | ||||
|   | ||||
| @@ -22,21 +22,19 @@ | ||||
|  | ||||
| // Override the Create menu for mobile | ||||
| @include phoneandtablet { | ||||
|     .menu-element { | ||||
|         .super-menu { | ||||
|             $d: 250px; | ||||
|             width: $d; | ||||
|             height: $d; | ||||
|     .super-menu { | ||||
|         $d: 250px; | ||||
|         width: $d; | ||||
|         height: $d; | ||||
|  | ||||
|             .pane { | ||||
|                 &.left { | ||||
|                     border-right: none; | ||||
|                     padding-right: 0; | ||||
|                     width: 100%; | ||||
|                 } | ||||
|                 &.right { | ||||
|                     display: none; | ||||
|                 } | ||||
|         .pane { | ||||
|             &.left { | ||||
|                 border-right: none; | ||||
|                 padding-right: 0; | ||||
|                 width: 100%; | ||||
|             } | ||||
|             &.right { | ||||
|                 display: none; | ||||
|             } | ||||
|         } | ||||
|     } | ||||
|   | ||||
| @@ -20,11 +20,9 @@ | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| $yBarW: 60px; | ||||
| $yLabelW: auto; | ||||
| $yLabelW: 10px; | ||||
| $xBarH: 32px; | ||||
| $legendH: 20px; | ||||
| //$colorHash: rgba(white, 0.3); // MOVED INTO CONSTANTS | ||||
| //$styleHash: dashed; // MOVED INTO CONSTANTS | ||||
| $swatchD: 8px; | ||||
| $plotDisplayArea: ($legendH + $interiorMargin, 0, $xBarH + $interiorMargin, $yBarW); // Top, right, bottom, left | ||||
|  | ||||
| @@ -36,7 +34,6 @@ $plotDisplayArea: ($legendH + $interiorMargin, 0, $xBarH + $interiorMargin, $yBa | ||||
| 	height: 100%; | ||||
|  | ||||
| 	.gl-plot-axis-area { | ||||
| 		//		@include test(green); | ||||
| 		position: absolute; | ||||
| 		&.gl-plot-x { | ||||
| 			top: auto; | ||||
| @@ -59,7 +56,7 @@ $plotDisplayArea: ($legendH + $interiorMargin, 0, $xBarH + $interiorMargin, $yBa | ||||
| 	.gl-plot-coords { | ||||
| 		@include box-sizing(border-box); | ||||
| 		@include border-radius($controlCr); | ||||
| 		background: black; //rgba($colorKey, 0.5); | ||||
| 		background: black; | ||||
| 		color: lighten($colorBodyFg, 30%); | ||||
| 		padding: 2px 5px; | ||||
| 		position: absolute; | ||||
| @@ -88,11 +85,9 @@ $plotDisplayArea: ($legendH + $interiorMargin, 0, $xBarH + $interiorMargin, $yBa | ||||
|  | ||||
| 	.gl-plot-label, | ||||
| 	.l-plot-label { | ||||
| 		//		@include test(yellow); | ||||
| 		color: $colorPlotLabelFg; | ||||
| 		position: absolute; | ||||
| 		text-align: center; | ||||
| //		text-transform: uppercase; | ||||
|  | ||||
| 		&.gl-plot-x-label, | ||||
| 		&.l-plot-x-label { | ||||
| @@ -117,20 +112,26 @@ $plotDisplayArea: ($legendH + $interiorMargin, 0, $xBarH + $interiorMargin, $yBa | ||||
| 		} | ||||
| 	} | ||||
|  | ||||
| 	.gl-plot-y-options { | ||||
| 	.gl-plot-x-options, | ||||
|     .gl-plot-y-options { | ||||
| 		$h: 32px; | ||||
| //		@include test(); | ||||
| 		position: absolute; | ||||
| 		top: 50%; | ||||
| 		right: auto; | ||||
| 		bottom: auto; | ||||
| 		left: $yLabelW + $interiorMargin; | ||||
| 		margin-top: $h / -2; | ||||
| 		height: auto; | ||||
| 		min-height: $h; | ||||
| 		width: $h; | ||||
|         z-index: 2; | ||||
| 	} | ||||
|  | ||||
|     .gl-plot-x-options { | ||||
|         top: $interiorMargin; | ||||
|     } | ||||
|  | ||||
|     .gl-plot-y-options { | ||||
|         @include transform(translateY(-50%)); | ||||
|         min-width: 150px; // Need this due to enclosure of .select | ||||
|         top: 50%; | ||||
|         left: $yLabelW + $interiorMargin * 2; | ||||
|     } | ||||
|  | ||||
| 	.gl-plot-hash { | ||||
| 		position: absolute; | ||||
| 		border: 0 $colorPlotHash $stylePlotHash; | ||||
| @@ -214,21 +215,13 @@ $plotDisplayArea: ($legendH + $interiorMargin, 0, $xBarH + $interiorMargin, $yBa | ||||
| 			display: inline-block; | ||||
| 			height: $swatchD; | ||||
| 			width: $swatchD; | ||||
| 			//margin-right: $interiorMarginSm; | ||||
| 		} | ||||
| 		&[class*='s-limit'] { | ||||
| 			.title-label { | ||||
| 				//color: #fff; | ||||
| 			} | ||||
| 		} | ||||
| 	} | ||||
| } | ||||
|  | ||||
| .gl-plot-legend { | ||||
| 	.plot-legend-item { | ||||
| 		//@include test(); | ||||
| 		@include border-radius($smallCr); | ||||
| 		//color: #fff; | ||||
| 		line-height: 1.5em; | ||||
| 		padding: 0px $itemPadLR; | ||||
| 		.plot-color-swatch { | ||||
| @@ -250,7 +243,6 @@ $plotDisplayArea: ($legendH + $interiorMargin, 0, $xBarH + $interiorMargin, $yBa | ||||
|  | ||||
| .gl-plot-tick, | ||||
| .tick-label { | ||||
| 	//			@include test(red); | ||||
| 	font-size: 0.7rem; | ||||
| 	position: absolute; | ||||
| 	overflow: hidden; | ||||
| @@ -277,7 +269,6 @@ $plotDisplayArea: ($legendH + $interiorMargin, 0, $xBarH + $interiorMargin, $yBa | ||||
| } | ||||
|  | ||||
| .gl-plot-tick { | ||||
| 	//			@include test(red); | ||||
| 	&.gl-plot-x-tick-label { | ||||
| 		top: $interiorMargin; | ||||
| 	} | ||||
|   | ||||
| @@ -20,30 +20,22 @@ | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
|  | ||||
| .abs.search-holder { | ||||
| 	//@include test(#990000); | ||||
| 	height: $treeSearchInputBarH; | ||||
| 	bottom: 0; | ||||
| 	&.active { | ||||
| 		height: auto; | ||||
| 		bottom: 0; | ||||
| 	} | ||||
| 	top: 23px; | ||||
|  | ||||
| 	// Align with the top of the divider bar, below create button | ||||
| 	//margin-top: 10px; // CH comment out | ||||
| 	z-index:5; | ||||
| .clear-icon, | ||||
| .menu-icon { | ||||
|     cursor: pointer; | ||||
|     font-family: symbolsfont; | ||||
|     @include trans-prop-nice((opacity, color), 150ms); | ||||
| } | ||||
|  | ||||
| .search { | ||||
| .clear-icon { | ||||
|     // 'x' in circle icon | ||||
|     &:before { | ||||
|         content: '\e607'; | ||||
|     } | ||||
| } | ||||
|  | ||||
| .holder-search { | ||||
| 	$iconWidth: 20px; | ||||
| 	$leftMargin: 6px; | ||||
| 	$rightPadding: 5px; | ||||
| 	@include webkitVal(display, flex); | ||||
| 	//display: flex; | ||||
| 	@include webkitProp(flex-direction, column); | ||||
| 	//flex-direction: column; | ||||
| 	height: 100%; | ||||
|  | ||||
| 	.search-bar { | ||||
| 		$textInputHeight: 19px; // This is equal to the default value, 19px | ||||
| @@ -52,38 +44,25 @@ | ||||
| 		font-size: 0.8em; | ||||
| 		max-width: 250px; | ||||
| 		position: relative; | ||||
| 		width: 100%; | ||||
| 		.search-input, | ||||
| 		.search-icon { | ||||
| 		} | ||||
| 		 | ||||
|  | ||||
| 		.search-input { | ||||
| 			height: $treeSearchInputBarH; | ||||
| 			line-height: $treeSearchInputBarH; | ||||
| 			padding-top: 0; | ||||
| 			padding-bottom: 0; | ||||
| 		} | ||||
| 		 | ||||
| 		.search-icon, | ||||
| 		&:before, | ||||
| 		.clear-icon, | ||||
| 		.menu-icon { | ||||
| 			//@include test(#008800); | ||||
| 			@include box-sizing(border-box); | ||||
| 			color: $colorInputIcon; | ||||
| 			height: $iconD; width: $iconD; | ||||
| 			height: $iconD; | ||||
|             width: $iconD; | ||||
| 			line-height: $iconD; | ||||
| 			position: absolute; | ||||
| 			text-align: center; | ||||
| 			top: $iconEdgeM; | ||||
| 		} | ||||
|  | ||||
| 		.clear-icon, | ||||
| 		.menu-icon { | ||||
| 			cursor: pointer; | ||||
| 			@include transition(color, .25s); | ||||
| 		} | ||||
|  | ||||
|  | ||||
| 		.search-input { | ||||
| 			position: relative; | ||||
| 			width: 100%; | ||||
| @@ -92,31 +71,21 @@ | ||||
|  | ||||
| 			// Make work for mct-control textfield | ||||
| 			input { | ||||
| 				width: 100%; | ||||
| 				width: inherit; // was 100% | ||||
| 			} | ||||
| 		} | ||||
|  | ||||
| 		.search-icon { | ||||
| 			//color: $colorItemFg; | ||||
| 			left: $interiorMarginSm; | ||||
| 			transition: visibility .15s, opacity .15s, color .2s; | ||||
| 			pointer-events: none; | ||||
|  | ||||
| 			&.content { | ||||
| 				// Make icon invisible whenever there is text input | ||||
| 				//visibility: hidden; | ||||
| 				//opacity: 0; | ||||
| 			} | ||||
| 		} | ||||
|  | ||||
| 		// Make icon invisible when the text input is focused | ||||
| 		.search-input:focus + div.search-icon { | ||||
| 			//visibility: hidden; | ||||
| 			//opacity: 0; | ||||
| 		} | ||||
| 		&:before { | ||||
|             // Magnify glass icon | ||||
|             content:'\4d'; | ||||
|             font-family: symbolsfont; | ||||
|             left: $interiorMarginSm; | ||||
|             @include trans-prop-nice(color, 250ms); | ||||
|             pointer-events: none; | ||||
|         } | ||||
|  | ||||
| 		// Make icon lighten when hovering over search bar | ||||
| 		.search-input:hover + div.search-icon { | ||||
| 		&:hover:before { | ||||
| 			color: pullForward($colorInputIcon, 10%); | ||||
| 		} | ||||
|  | ||||
| @@ -124,13 +93,10 @@ | ||||
| 			right: $iconD + $interiorMargin; | ||||
|  | ||||
| 			// Icon is visible only when there is text input | ||||
| 			visibility: hidden; | ||||
|             visibility: hidden; | ||||
| 			opacity: 0; | ||||
|  | ||||
| 			transition: visibility .15s, opacity .15s, color .2s; | ||||
|  | ||||
| 			&.content { | ||||
| 				visibility: visible; | ||||
| 			&.show { | ||||
|                 visibility: visible; | ||||
| 				opacity: 1; | ||||
| 			} | ||||
|  | ||||
| @@ -140,6 +106,8 @@ | ||||
| 		} | ||||
|  | ||||
| 		.menu-icon { | ||||
|             // 'v' invoke menu icon | ||||
|             &:before { content: '\76'; } | ||||
| 			font-size: 0.8em; | ||||
| 			padding-right: $iconEdgeM; | ||||
| 			right: $iconEdgeM; | ||||
| @@ -152,43 +120,19 @@ | ||||
|  | ||||
| 		.search-menu-holder { | ||||
| 			float: right; | ||||
| 			//margin-top: $textInputHeight - 2px; | ||||
| 			//left: -50px; | ||||
| 			left: -20px; | ||||
|  | ||||
| 			z-index: 1; | ||||
|  | ||||
| 			z-index: 70; | ||||
| 			transition: visibility .05s, opacity .05s; | ||||
|  | ||||
| 			&.off { | ||||
| 				visibility: hidden; | ||||
| 				opacity: 0; | ||||
| 			} | ||||
| 		} | ||||
|  | ||||
| 		// Hovering reveals menu | ||||
| 		.menu-icon:hover + div.search-menu-holder { | ||||
| 			visibility: visible; | ||||
| 		} | ||||
| 		div.search-menu-holder:hover { | ||||
| 			visibility: visible; | ||||
| 		} | ||||
| 	} | ||||
|  | ||||
| 	.active-filter-display { | ||||
| 		//order: 2; | ||||
| 		$s: 0.65em; | ||||
| 		$p: $interiorMargin; | ||||
| 		@include border-radius($basicCr); | ||||
| 		@include box-sizing(border-box); | ||||
| 		line-height: 130%; | ||||
| 		padding: $p 0; | ||||
| 		padding-left: $s * 2.25; | ||||
| 		font-size: $s; | ||||
| 		//background-color: rgba(#000, 0.3); | ||||
| 		//border-radius: $basicCr; | ||||
| 		margin-top: $interiorMarginSm; | ||||
|  | ||||
|  | ||||
| 		.clear-filters-icon { | ||||
| 			color: $colorInputIcon; | ||||
| @@ -198,43 +142,28 @@ | ||||
| 			left: 1px; | ||||
| 			cursor: pointer; | ||||
| 		} | ||||
|  | ||||
| 		// Transition looks weird when the results list has none | ||||
| 		//transition: visibility .2s, opacity .2s; | ||||
|  | ||||
| 		&.off { | ||||
| 			visibility: hidden; | ||||
| 			opacity: 0; | ||||
| 			height: 0; | ||||
| 			margin: 0; | ||||
| 			padding: 0; | ||||
| 			border: 0; | ||||
| 		} | ||||
| 	} | ||||
|  | ||||
| 	.search-scroll { | ||||
| 		order: 3; | ||||
| 		margin-top: 4px; | ||||
|  | ||||
| 		// Adjustable scrolling size | ||||
| 		overflow-y: auto; | ||||
| 		top: auto; | ||||
| 		height: auto; | ||||
| 		max-height: 100%; | ||||
| 		position: relative; | ||||
|  | ||||
| 		.load-icon { | ||||
| 			position: relative; | ||||
| 		} | ||||
|  | ||||
| 	.search-results { | ||||
|         @include trans-prop-nice((opacity, visibility), 250ms); | ||||
|         margin-top: $interiorMarginLg; // Always include margin here to fend off the search input | ||||
| 		padding-right: $interiorMargin; | ||||
|         .hint { | ||||
|             margin-bottom: $interiorMarginLg; | ||||
|             font-size: 0.65em; | ||||
|             opacity: 0.6; | ||||
|         } | ||||
|         &.active { | ||||
|             visibility: visible; | ||||
|             opacity: 1; | ||||
|         } | ||||
| 		.load-more-button { | ||||
| 			margin-top: $interiorMargin 0; | ||||
| 			font-size: 0.8em; | ||||
| 			position: relative; | ||||
| 			left: 50%; | ||||
| 			margin-left: -45px; | ||||
| 			text-align: center; | ||||
| 			width: 90px; | ||||
|             @include transform(translateX(-50%)); | ||||
|             display: inline-block; | ||||
| 			margin-top: $interiorMargin; | ||||
|             padding: 0 $interiorMarginLg; | ||||
| 			font-size: 0.75em; | ||||
| 			margin-left: 50%; | ||||
| 			white-space: nowrap; | ||||
| 		} | ||||
| 	} | ||||
|   | ||||
| @@ -29,11 +29,13 @@ | ||||
| 			border-color: lighten($bc, 10%); | ||||
| 		} | ||||
| 	} | ||||
| 	>.object-header.abs { | ||||
| 		//@include test(red); | ||||
| 	.object-top-bar { | ||||
| 		font-size: 0.75em; | ||||
| 		height: $ohH; | ||||
| 		line-height: $ohH; | ||||
|         .left { | ||||
|             padding-right: $interiorMarginLg; | ||||
|         } | ||||
| 	} | ||||
| 	>.object-holder.abs { | ||||
| 		top: $ohH + $interiorMargin; | ||||
|   | ||||
| @@ -19,23 +19,6 @@ | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| @mixin cols($totalCols, $span) { | ||||
|     $cw: 100% / $totalCols; | ||||
|     min-width: (500px / $totalCols) * $span; | ||||
|     @if ($totalCols != $span) { | ||||
|         width: ($cw * $span) - $ueColMargin; | ||||
|     } @else { | ||||
|         width: $cw; | ||||
|     } | ||||
| } | ||||
|  | ||||
| /*.holder-all { | ||||
|     $myM: 0; // $interiorMarginSm; | ||||
|     top: $myM; | ||||
|     right: $myM; | ||||
|     bottom: $myM; | ||||
|     left: $myM; | ||||
| }*/ | ||||
|  | ||||
| .browse-area, | ||||
| .edit-area, | ||||
| @@ -48,7 +31,7 @@ | ||||
| } | ||||
|  | ||||
| .contents { | ||||
|     $myM: 0; //$interiorMargin; | ||||
|     $myM: 0; | ||||
|     box-sizing: border-box; | ||||
|     position: absolute; | ||||
|     top: $myM; | ||||
| @@ -63,37 +46,6 @@ | ||||
|     } | ||||
| } | ||||
|  | ||||
| .bar { | ||||
|     .icon.major { | ||||
|         margin-right: $interiorMargin; | ||||
|     } | ||||
|     &.abs { | ||||
|         text-wrap: none; | ||||
|         white-space: nowrap; | ||||
|         &.left, | ||||
|         .left { | ||||
|             width: 45%; | ||||
|             right: auto; | ||||
|         } | ||||
|         &.right, | ||||
|         .right { | ||||
|             width: 45%; | ||||
|             left: auto; | ||||
|             text-align: right; | ||||
|             .icon.major { | ||||
|                 margin-left: $interiorMargin * 3; | ||||
|             } | ||||
|         } | ||||
|         .l-flex, | ||||
|         &.l-flex { | ||||
|             .left, | ||||
|             .right { | ||||
|                 width: auto; | ||||
|             } | ||||
|         } | ||||
|     } | ||||
| } | ||||
|  | ||||
| .user-environ { | ||||
|     .browse-area, | ||||
|     .editor { | ||||
| @@ -134,12 +86,10 @@ | ||||
| 		background: $colorFooterBg; | ||||
| 		color: lighten($colorBodyBg, 30%); | ||||
| 		font-size: .7rem; | ||||
|  | ||||
| 		.status-holder { | ||||
| 			@include box-sizing(border-box); | ||||
| 			@include absPosDefault($interiorMargin); | ||||
| 			@include ellipsize(); | ||||
| 			//line-height: $ueFooterH - ($interiorMargin * 2); | ||||
| 			right: 120px; | ||||
| 			text-transform: uppercase; | ||||
| 			z-index: 1; | ||||
| @@ -158,86 +108,6 @@ | ||||
| 	} | ||||
| } | ||||
|  | ||||
| .cols { | ||||
|     @include clearfix; | ||||
|     .col { | ||||
|         @include box-sizing(border-box); | ||||
|         @include clearfix; | ||||
|         //		background: rgba(#ffcc00, 0.2); | ||||
|         float: left; | ||||
|         margin-left: $ueColMargin; | ||||
|         padding-left: $interiorMargin; | ||||
|         position: relative; | ||||
|         &:first-child { | ||||
|             margin-left: 0; | ||||
|             padding-left: 0; | ||||
|         } | ||||
|     } | ||||
|     &.cols-2 { | ||||
|         $nc: 2; | ||||
|         .col-1 { | ||||
|             @include cols($nc, 1); | ||||
|         } | ||||
|     } | ||||
|     &.cols-2-ff { | ||||
|         // 2 columns, first column is fixed, second is fluid | ||||
|         .col-100px { | ||||
|             width: 100px; | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     &.cols-6 { | ||||
|         $nc: 6; | ||||
|         .col-1 { | ||||
|             @include cols($nc, 1); | ||||
|         } | ||||
|     } | ||||
|     &.cols-16 { | ||||
|         $nc: 16; | ||||
|         .col-1 { | ||||
|             @include cols($nc, 1); | ||||
|         } | ||||
|         .col-2 { | ||||
|             @include cols($nc, 2); | ||||
|         } | ||||
|         .col-7 { | ||||
|             @include cols($nc, 7); | ||||
|         } | ||||
|     } | ||||
|     &.cols-32 { | ||||
|         $nc: 32; | ||||
|         .col-2 { | ||||
|             @include cols($nc, 2); | ||||
|         } | ||||
|         .col-15 { | ||||
|             @include cols($nc, 15); | ||||
|         } | ||||
|     } | ||||
|     .l-row { | ||||
|         @include clearfix; | ||||
|         padding: $interiorMargin 0; | ||||
|     } | ||||
| } | ||||
|  | ||||
| .browse-mode { | ||||
|     .split-layout { | ||||
|         .split-pane-component.pane { | ||||
|             //@include test(green); | ||||
|             &.treeview.left { | ||||
|                 min-width: 150px; | ||||
|                 max-width: 800px; | ||||
|                 width: $ueBrowseLeftPaneTreeW; | ||||
|             } | ||||
|             &.t-inspect.right { | ||||
|                 min-width: 200px; | ||||
|                 max-width: 600px; | ||||
|                 //padding-left: $ueCollapsedPaneEdgeM; // Allow room for mini-tab element | ||||
|                 width: $ueBrowseRightPaneInspectW; | ||||
|             } | ||||
|         } | ||||
|     } | ||||
| } | ||||
|  | ||||
| .edit-mode { | ||||
|     .split-layout { | ||||
|         .split-pane-component.pane.right { | ||||
| @@ -258,7 +128,6 @@ | ||||
|         text-transform: uppercase; | ||||
|         height: $ueTopBarH; | ||||
|         line-height: $ueTopBarH; | ||||
|         margin-bottom: $interiorMargin; | ||||
|     } | ||||
|  | ||||
|     .primary-pane { | ||||
| @@ -266,30 +135,7 @@ | ||||
|         z-index: 2; | ||||
|     } | ||||
|  | ||||
|     &.treeview.left { | ||||
|         //.create-btn-holder { | ||||
|         //    //bottom: auto; | ||||
|         //    //top: 0; | ||||
|         //    height: $ueTopBarH; | ||||
|         //    .wrapper.menu-element { | ||||
|         //        position: absolute; | ||||
|         //        bottom: $interiorMargin; | ||||
|         //    } | ||||
|         //} | ||||
|         .holder-create-and-search{ | ||||
|  | ||||
|         } | ||||
|         .search-holder { | ||||
|             top: $ueTopBarH + $interiorMarginLg; | ||||
|         } | ||||
|         .tree-holder { | ||||
|             overflow: auto; | ||||
|             top: $ueTopBarH + $interiorMarginLg + $treeSearchInputBarH + $interiorMargin; | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     .mini-tab-icon.toggle-pane { | ||||
|         //@include test(blue, 0.3); | ||||
|         z-index: 5; | ||||
|         @include desktop { | ||||
|             $d: $uePaneMiniTabH; | ||||
| @@ -334,7 +180,6 @@ | ||||
|             } | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     &.items { | ||||
|         .object-browse-bar { | ||||
|             .left.abs, | ||||
| @@ -346,32 +191,8 @@ | ||||
| } | ||||
|  | ||||
| .split-layout { | ||||
|     &.horizontal { | ||||
|         // Slides up and down | ||||
|         > .pane { | ||||
|             //			@include test(); | ||||
|             margin-top: $interiorMargin; | ||||
|             &:first-child { | ||||
|                 margin-top: 0; | ||||
|             } | ||||
|         } | ||||
|     } | ||||
|    /* &.vertical { | ||||
|         // Slides left and right | ||||
|         > .pane.left { | ||||
|             > .holder { | ||||
|                 left: $bodyMargin; | ||||
|             } | ||||
|         } | ||||
|         > .pane.right { | ||||
|             > .holder { | ||||
|                 right: $bodyMargin; | ||||
|             } | ||||
|         } | ||||
|     }*/ | ||||
|  | ||||
|     // Specific elements margins | ||||
|     .holder.holder-create-and-search { | ||||
|     .holder.holder-treeview-elements { | ||||
|         top: $bodyMargin; | ||||
|         right: 0; | ||||
|         bottom: $bodyMargin; | ||||
| @@ -392,7 +213,6 @@ | ||||
|             bottom: $bodyMargin; | ||||
|             left: $bodyMargin; | ||||
|             right: $bodyMargin; | ||||
|  | ||||
|         } | ||||
|     } | ||||
| } | ||||
| @@ -425,76 +245,43 @@ | ||||
|     } | ||||
| } | ||||
|  | ||||
| /***************************************************** OBJECT BROWSE BAR */ | ||||
| .object-browse-bar { | ||||
|     //@include test(blue); | ||||
|     @include absPosDefault(0, visible); | ||||
|     @include absPosDefault(0, visible); // Must use visible to avoid hiding view switcher menu | ||||
|     @include box-sizing(border-box); | ||||
|     height: $ueTopBarH; | ||||
|     line-height: $ueTopBarH; | ||||
|     white-space: nowrap; | ||||
|  | ||||
|     .left { | ||||
|         padding-right: $interiorMarginLg * 2; | ||||
|         padding-right: $interiorMarginLg; | ||||
|         .l-back { | ||||
|             display: inline-block; | ||||
|             float: left; | ||||
|             margin-right: $interiorMarginLg; | ||||
|         } | ||||
|     } | ||||
| } | ||||
|  | ||||
| .l-flex { | ||||
|     @include webkitVal('display', 'flex'); | ||||
|     @include webkitProp('flex-flow', 'row nowrap'); | ||||
|     .left { | ||||
|         //@include test(red); | ||||
|         @include webkitProp(flex, '1 1 0'); | ||||
|         padding-right: $interiorMarginLg; | ||||
|     } | ||||
| } | ||||
|  | ||||
| // When the tree is hidden, these are the | ||||
| // classes used for the left menu and the | ||||
| // right representation. | ||||
| .pane-tree-hidden { | ||||
|     // Sets the left tree menu when the tree is hidden. | ||||
|     //.pane.left.treeview, | ||||
|     .tree-holder, | ||||
|     .splitter-treeview, | ||||
|     .holder-create-and-search { | ||||
|     .holder-treeview-elements { | ||||
|         opacity: 0; | ||||
|     } | ||||
|     /*.holder-create-and-search { | ||||
|         @include trans-prop-nice((top, left), 250ms); | ||||
|         top: $ueTopBarH + $interiorMargin; | ||||
|         left: -1 * $bodyMargin !important; | ||||
|         .create-btn { | ||||
|             @include border-left-radius(0); | ||||
|             @include trans-prop-nice((width), 250ms); | ||||
|             width: $uePaneMiniTabW !important; | ||||
|             text-align: center !important; | ||||
|             padding: 0; | ||||
|             .title-label, | ||||
|             &:after { | ||||
|                 display: none; | ||||
|             } | ||||
|             &:before { | ||||
|                 font-size: 9px; | ||||
|             } | ||||
|         } | ||||
|     }*/ | ||||
| } | ||||
|  | ||||
| .pane-tree-showing { | ||||
|     // Sets the left tree menu when the tree is shown. | ||||
|     //.pane.left.treeview, | ||||
|     .tree-holder, | ||||
|     .splitter-treeview { | ||||
|         @include trans-prop-nice(opacity, $dur: 250ms, $delay: 250ms); | ||||
|         opacity: 1; | ||||
|     } | ||||
|  | ||||
|     .holder-create-and-search { | ||||
|     .holder-treeview-elements { | ||||
|         @include trans-prop-nice(opacity, $dur: 250ms, $delay: 200ms); | ||||
|     } | ||||
| } | ||||
| @@ -508,8 +295,12 @@ | ||||
|         } | ||||
|     } | ||||
| } | ||||
|  | ||||
| .pane-inspect-hidden { | ||||
|     .l-object-and-inspector { | ||||
|         .t-inspect { | ||||
|             z-index: 1 !important; // Move down so that primary pane elements are clickable | ||||
|         } | ||||
|         .l-inspect, | ||||
|         .splitter-inspect { | ||||
|             opacity: 0; | ||||
| @@ -518,6 +309,24 @@ | ||||
| } | ||||
|  | ||||
| @include desktop { | ||||
|     .holder-all { | ||||
|         min-width: $ueDesktopMinW; | ||||
|     } | ||||
|     .split-layout { | ||||
|         .split-pane-component.pane { | ||||
|             &.treeview.left { | ||||
|                 min-width: $ueBrowseLeftPaneTreeMinW; | ||||
|                 max-width: $ueBrowseLeftPaneTreeMaxW; | ||||
|                 width: $ueBrowseLeftPaneTreeW; | ||||
|             } | ||||
|             &.t-inspect.right { | ||||
|                 min-width: $ueBrowseRightPaneInspectMinW; | ||||
|                 max-width: $ueBrowseRightPaneInspectMaxW; | ||||
|                 width: $ueBrowseRightPaneInspectW; | ||||
|                 z-index: 3; // Must lift up beyond primary pane to allow overflow to go underneath | ||||
|             } | ||||
|         } | ||||
|     } | ||||
|     .pane.treeview.left .tree-holder { | ||||
|         padding-right: $interiorMargin; | ||||
|     } | ||||
| @@ -527,8 +336,10 @@ | ||||
|     .pane-inspect-hidden .l-object-and-inspector { | ||||
|         .pane.left { right: $ueCollapsedPaneEdgeM !important; } | ||||
|     } | ||||
|  | ||||
|     .pane:not(.resizing) { | ||||
|         @include trans-prop-nice-resize-w(250ms); | ||||
|     } | ||||
|     .pane.primary-pane .object-browse-bar { | ||||
|         min-width: 200px; // Needed for nice display when primary pane is constrained severely via splitters | ||||
|     } | ||||
| } | ||||
|   | ||||
| @@ -1,18 +1,40 @@ | ||||
| <!-- | ||||
|  Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  as represented by the Administrator of the National Aeronautics and Space | ||||
|  Administration. All rights reserved. | ||||
|  | ||||
|  Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  "License"); you may not use this file except in compliance with the License. | ||||
|  You may obtain a copy of the License at | ||||
|  http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  | ||||
|  Unless required by applicable law or agreed to in writing, software | ||||
|  distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  License for the specific language governing permissions and limitations | ||||
|  under the License. | ||||
|  | ||||
|  Open MCT Web includes source code licensed under additional open source | ||||
|  licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  this source code distribution or the Licensing information page available | ||||
|  at runtime from the About dialog for additional information. | ||||
| --> | ||||
| <span class="s-btn" | ||||
|       ng-controller="DateTimeFieldController"> | ||||
|     <input type="text" | ||||
|            ng-model="textValue" | ||||
|            ng-blur="restoreTextValue(); ngBlur()" | ||||
|            ng-class="{ error: textInvalid }"> | ||||
|     </input> | ||||
|     <a class="ui-symbol icon icon-calendar" | ||||
|        ng-if="structure.format === 'utc' || !structure.format" | ||||
|        ng-click="pickerActive = !pickerActive"> | ||||
|        ng-click="picker.active = !picker.active"> | ||||
|     </a> | ||||
|     <mct-popup ng-if="pickerActive"> | ||||
|         <div mct-click-elsewhere="pickerActive = false"> | ||||
|     <mct-popup ng-if="picker.active"> | ||||
|         <div mct-click-elsewhere="picker.active = false"> | ||||
|             <mct-control key="'datetime-picker'" | ||||
|                          ng-model="ngModel" | ||||
|                          field="field" | ||||
|                          ng-model="pickerModel" | ||||
|                          field="'value'" | ||||
|                          options="{ hours: true }"> | ||||
|             </mct-control> | ||||
|         </div> | ||||
|   | ||||
| @@ -20,12 +20,14 @@ | ||||
|  at runtime from the About dialog for additional information. | ||||
| --> | ||||
| <div ng-controller="TimeRangeController"> | ||||
|     <div class="l-time-range-inputs-holder"> | ||||
|     <form class="l-time-range-inputs-holder" | ||||
|           ng-submit="updateBoundsFromForm()"> | ||||
|         <span class="l-time-range-inputs-elem ui-symbol type-icon">C</span> | ||||
|         <span class="l-time-range-input"> | ||||
|             <mct-control key="'datetime-field'" | ||||
|                          structure="{ format: parameters.format }" | ||||
|                          ng-model="ngModel.outer" | ||||
|                          ng-model="formModel" | ||||
|                          ng-blur="updateBoundsFromForm()" | ||||
|                          field="'start'" | ||||
|                          class="time-range-start"> | ||||
|             </mct-control> | ||||
| @@ -36,12 +38,15 @@ | ||||
|         <span class="l-time-range-input" ng-controller="ToggleController as t2"> | ||||
|             <mct-control key="'datetime-field'" | ||||
|                          structure="{ format: parameters.format }" | ||||
|                          ng-model="ngModel.outer" | ||||
|                          ng-model="formModel" | ||||
|                          ng-blur="updateBoundsFromForm()" | ||||
|                          field="'end'" | ||||
|                          class="time-range-end"> | ||||
|             </mct-control>  | ||||
|         </span> | ||||
|     </div> | ||||
|  | ||||
|         <input type="submit" class="hidden"> | ||||
|     </form> | ||||
|  | ||||
|     <div class="l-time-range-slider-holder"> | ||||
|         <div class="l-time-range-slider"> | ||||
|   | ||||
| @@ -20,9 +20,9 @@ | ||||
|  at runtime from the About dialog for additional information. | ||||
| --> | ||||
| <span class="l-inspect" ng-controller="ObjectInspectorController as controller"> | ||||
|     <div class="abs holder holder-inspector-elements"> | ||||
|     <div class="pane-header">Inspection</div> | ||||
|     <ul> | ||||
|     <div class="abs holder holder-inspector-elements l-flex-col"> | ||||
|     <div class="pane-header flex-elem">Inspection</div> | ||||
|     <ul class="flex-elem grows vscroll"> | ||||
|         <li> | ||||
|             <em>Properties</em> | ||||
|             <div class="inspector-properties" | ||||
|   | ||||
| @@ -38,8 +38,9 @@ define( | ||||
|          * @constructor | ||||
|          * @param {object[]} stylesheets stylesheet extension definitions | ||||
|          * @param $document Angular's jqLite-wrapped document element | ||||
|          * @param {string} activeTheme the theme in use | ||||
|          */ | ||||
|         function StyleSheetLoader(stylesheets, $document) { | ||||
|         function StyleSheetLoader(stylesheets, $document, activeTheme) { | ||||
|             var head = $document.find('head'), | ||||
|                 document = $document[0]; | ||||
|  | ||||
| @@ -62,8 +63,15 @@ define( | ||||
|                 head.append(link); | ||||
|             } | ||||
|  | ||||
|             // Stylesheets which specify themes should only be applied | ||||
|             // when that theme has been declared. | ||||
|             function matchesTheme(stylesheet) { | ||||
|                 return stylesheet.theme === undefined || | ||||
|                     stylesheet.theme === activeTheme; | ||||
|             } | ||||
|  | ||||
|             // Add all stylesheets from extensions | ||||
|             stylesheets.forEach(addStyleSheet); | ||||
|             stylesheets.filter(matchesTheme).forEach(addStyleSheet); | ||||
|         } | ||||
|  | ||||
|         return StyleSheetLoader; | ||||
|   | ||||
							
								
								
									
										64
									
								
								platform/commonUI/general/src/UnsupportedBrowserWarning.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										64
									
								
								platform/commonUI/general/src/UnsupportedBrowserWarning.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,64 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /*global define*/ | ||||
|  | ||||
| /** | ||||
|  * This bundle provides various general-purpose UI elements, including | ||||
|  * platform styling. | ||||
|  * @namespace platform/commonUI/general | ||||
|  */ | ||||
| define( | ||||
|     [], | ||||
|     function () { | ||||
|         "use strict"; | ||||
|  | ||||
|         var WARNING_TITLE = "Unsupported browser", | ||||
|             WARNING_DESCRIPTION = [ | ||||
|                 "This software has been developed and tested", | ||||
|                 "using the latest Google Chrome,", | ||||
|                 "and may be unstable in other browsers." | ||||
|             ].join(" "), | ||||
|             MOBILE_BROWSER = "Safari", | ||||
|             DESKTOP_BROWSER = "Chrome"; | ||||
|  | ||||
|         /** | ||||
|          * Shows a warning if a user's browser is unsupported. | ||||
|          * @memberof platform/commonUI/general | ||||
|          * @constructor | ||||
|          * @param {NotificationService} notificationService the notification | ||||
|          *        service | ||||
|          */ | ||||
|         function UnsupportedBrowserWarning(notificationService, agentService) { | ||||
|             var testToBrowser = agentService.isMobile() ? | ||||
|                     MOBILE_BROWSER : DESKTOP_BROWSER; | ||||
|  | ||||
|             if (!agentService.isBrowser(testToBrowser)) { | ||||
|                 notificationService.alert({ | ||||
|                     title: WARNING_TITLE, | ||||
|                     actionText: WARNING_DESCRIPTION | ||||
|                 }); | ||||
|             } | ||||
|         } | ||||
|  | ||||
|         return UnsupportedBrowserWarning; | ||||
|     } | ||||
| ); | ||||
| @@ -53,7 +53,9 @@ define( | ||||
|                         formatter.parse($scope.textValue) !== value) { | ||||
|                     $scope.textValue = formatter.format(value); | ||||
|                     $scope.textInvalid = false; | ||||
|                     $scope.lastValidValue = $scope.textValue; | ||||
|                 } | ||||
|                 $scope.pickerModel = { value: value }; | ||||
|             } | ||||
|  | ||||
|             function updateFromView(textValue) { | ||||
| @@ -61,6 +63,17 @@ define( | ||||
|                 if (!$scope.textInvalid) { | ||||
|                     $scope.ngModel[$scope.field] = | ||||
|                         formatter.parse(textValue); | ||||
|                     $scope.lastValidValue = $scope.textValue; | ||||
|                 } | ||||
|             } | ||||
|  | ||||
|             function updateFromPicker(value) { | ||||
|                 if (value !== $scope.ngModel[$scope.field]) { | ||||
|                     $scope.ngModel[$scope.field] = value; | ||||
|                     updateFromModel(value); | ||||
|                     if ($scope.ngBlur) { | ||||
|                         $scope.ngBlur(); | ||||
|                     } | ||||
|                 } | ||||
|             } | ||||
|  | ||||
| @@ -69,9 +82,20 @@ define( | ||||
|                 updateFromModel($scope.ngModel[$scope.field]); | ||||
|             } | ||||
|  | ||||
|             function restoreTextValue() { | ||||
|                 $scope.textValue = $scope.lastValidValue; | ||||
|                 updateFromView($scope.textValue); | ||||
|             } | ||||
|  | ||||
|             $scope.restoreTextValue = restoreTextValue; | ||||
|  | ||||
|             $scope.picker = { active: false }; | ||||
|  | ||||
|             $scope.$watch('structure.format', setFormat); | ||||
|             $scope.$watch('ngModel[field]', updateFromModel); | ||||
|             $scope.$watch('pickerModel.value', updateFromPicker); | ||||
|             $scope.$watch('textValue', updateFromView); | ||||
|  | ||||
|         } | ||||
|  | ||||
|         return DateTimeFieldController; | ||||
|   | ||||
| @@ -175,6 +175,13 @@ define( | ||||
|                 updateViewFromModel($scope.ngModel); | ||||
|             } | ||||
|  | ||||
|             function updateFormModel() { | ||||
|                 $scope.formModel = { | ||||
|                     start: (($scope.ngModel || {}).outer || {}).start, | ||||
|                     end: (($scope.ngModel || {}).outer || {}).end | ||||
|                 }; | ||||
|             } | ||||
|  | ||||
|             function updateOuterStart(t) { | ||||
|                 var ngModel = $scope.ngModel; | ||||
|  | ||||
| @@ -192,6 +199,7 @@ define( | ||||
|                     ngModel.inner.end | ||||
|                 ); | ||||
|  | ||||
|                 updateFormModel(); | ||||
|                 updateViewForInnerSpanFromModel(ngModel); | ||||
|                 updateTicks(); | ||||
|             } | ||||
| @@ -213,6 +221,7 @@ define( | ||||
|                     ngModel.inner.start | ||||
|                 ); | ||||
|  | ||||
|                 updateFormModel(); | ||||
|                 updateViewForInnerSpanFromModel(ngModel); | ||||
|                 updateTicks(); | ||||
|             } | ||||
| @@ -223,6 +232,14 @@ define( | ||||
|                 updateTicks(); | ||||
|             } | ||||
|  | ||||
|             function updateBoundsFromForm() { | ||||
|                 $scope.ngModel = $scope.ngModel || {}; | ||||
|                 $scope.ngModel.outer = { | ||||
|                     start: $scope.formModel.start, | ||||
|                     end: $scope.formModel.end | ||||
|                 }; | ||||
|             } | ||||
|  | ||||
|             $scope.startLeftDrag = startLeftDrag; | ||||
|             $scope.startRightDrag = startRightDrag; | ||||
|             $scope.startMiddleDrag = startMiddleDrag; | ||||
| @@ -230,10 +247,13 @@ define( | ||||
|             $scope.rightDrag = rightDrag; | ||||
|             $scope.middleDrag = middleDrag; | ||||
|  | ||||
|             $scope.updateBoundsFromForm = updateBoundsFromForm; | ||||
|  | ||||
|             $scope.ticks = []; | ||||
|  | ||||
|             // Initialize scope to defaults | ||||
|             updateViewFromModel($scope.ngModel); | ||||
|             updateFormModel(); | ||||
|  | ||||
|             $scope.$watchCollection("ngModel", updateViewFromModel); | ||||
|             $scope.$watch("spanWidth", updateSpanWidth); | ||||
|   | ||||
| @@ -51,6 +51,10 @@ define( | ||||
|                     position = [ rect.left, rect.top ], | ||||
|                     popup = popupService.display(div, position); | ||||
|  | ||||
|                 // TODO: Handle in CSS; | ||||
|                 //       https://github.com/nasa/openmctweb/issues/298 | ||||
|                 div.css('z-index', 75); | ||||
|  | ||||
|                 transclude(function (clone) { | ||||
|                     div.append(clone); | ||||
|                 }); | ||||
|   | ||||
| @@ -204,7 +204,7 @@ define( | ||||
|                 // And poll for position changes enforced by styles | ||||
|                 activeInterval = $interval(function () { | ||||
|                     getSetPosition(getSetPosition()); | ||||
|                 }, POLLING_INTERVAL, false); | ||||
|                 }, POLLING_INTERVAL, 0, false); | ||||
|  | ||||
|                 // ...and stop polling when we're destroyed. | ||||
|                 $scope.$on('$destroy', function () { | ||||
|   | ||||
| @@ -32,10 +32,11 @@ define( | ||||
|                 mockPlainDocument, | ||||
|                 mockHead, | ||||
|                 mockElement, | ||||
|                 testBundle, | ||||
|                 loader; | ||||
|  | ||||
|             beforeEach(function () { | ||||
|                 var testBundle = { | ||||
|                 testBundle = { | ||||
|                     path: "a/b", | ||||
|                     resources: "c" | ||||
|                 }; | ||||
| @@ -72,6 +73,40 @@ define( | ||||
|                 expect(mockElement.setAttribute) | ||||
|                     .toHaveBeenCalledWith('href', "a/b/c/d.css"); | ||||
|             }); | ||||
|  | ||||
|             describe("for themed stylesheets", function () { | ||||
|                 var testTheme = "test-theme"; | ||||
|  | ||||
|                 beforeEach(function () { | ||||
|                     testStyleSheets = [{ | ||||
|                         stylesheetUrl: "themed.css", | ||||
|                         bundle: testBundle, | ||||
|                         theme: testTheme | ||||
|                     }, { | ||||
|                         stylesheetUrl: "bad-theme.css", | ||||
|                         bundle: testBundle, | ||||
|                         theme: 'bad-theme' | ||||
|                     }]; | ||||
|  | ||||
|                     loader = new StyleSheetLoader( | ||||
|                         testStyleSheets, | ||||
|                         mockDocument, | ||||
|                         testTheme | ||||
|                     ); | ||||
|                 }); | ||||
|  | ||||
|                 it("includes matching themes", function () { | ||||
|                     expect(mockElement.setAttribute) | ||||
|                         .toHaveBeenCalledWith('href', "a/b/c/themed.css"); | ||||
|                 }); | ||||
|  | ||||
|                 it("excludes mismatching themes", function () { | ||||
|                     expect(mockElement.setAttribute) | ||||
|                         .not.toHaveBeenCalledWith('href', "a/b/c/bad-theme.css"); | ||||
|                 }); | ||||
|             }); | ||||
|  | ||||
|  | ||||
|         }); | ||||
|     } | ||||
| ); | ||||
|   | ||||
| @@ -0,0 +1,98 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /*global define,Promise,describe,it,expect,beforeEach,waitsFor,jasmine*/ | ||||
|  | ||||
| define( | ||||
|     ["../src/UnsupportedBrowserWarning"], | ||||
|     function (UnsupportedBrowserWarning) { | ||||
|         "use strict"; | ||||
|  | ||||
|         var MOBILE_BROWSER = "Safari", | ||||
|             DESKTOP_BROWSER = "Chrome", | ||||
|             UNSUPPORTED_BROWSERS = [ | ||||
|                 "Firefox", | ||||
|                 "IE", | ||||
|                 "Opera", | ||||
|                 "Iceweasel" | ||||
|             ]; | ||||
|  | ||||
|         describe("The unsupported browser warning", function () { | ||||
|             var mockNotificationService, | ||||
|                 mockAgentService, | ||||
|                 testAgent; | ||||
|  | ||||
|             function instantiateWith(browser) { | ||||
|                 testAgent = "Mozilla/5.0 " + browser + "/12.34.56"; | ||||
|                 return new UnsupportedBrowserWarning( | ||||
|                     mockNotificationService, | ||||
|                     mockAgentService | ||||
|                 ); | ||||
|             } | ||||
|  | ||||
|             beforeEach(function () { | ||||
|                 testAgent = "chrome"; | ||||
|                 mockNotificationService = jasmine.createSpyObj( | ||||
|                     "notificationService", | ||||
|                     [ "alert" ] | ||||
|                 ); | ||||
|                 mockAgentService = jasmine.createSpyObj( | ||||
|                     "agentService", | ||||
|                     [ "isMobile", "isBrowser" ] | ||||
|                 ); | ||||
|                 mockAgentService.isBrowser.andCallFake(function (substr) { | ||||
|                     substr = substr.toLowerCase(); | ||||
|                     return testAgent.toLowerCase().indexOf(substr) !== -1; | ||||
|                 }); | ||||
|             }); | ||||
|  | ||||
|             [ false, true ].forEach(function (isMobile) { | ||||
|                 var deviceType = isMobile ? "mobile" : "desktop", | ||||
|                     goodBrowser = isMobile ? MOBILE_BROWSER : DESKTOP_BROWSER, | ||||
|                     badBrowsers = UNSUPPORTED_BROWSERS.concat([ | ||||
|                         isMobile ? DESKTOP_BROWSER : MOBILE_BROWSER | ||||
|                     ]); | ||||
|  | ||||
|                 describe("on " + deviceType + " devices", function () { | ||||
|                     beforeEach(function () { | ||||
|                         mockAgentService.isMobile.andReturn(isMobile); | ||||
|                     }); | ||||
|  | ||||
|                     it("is not shown for " + goodBrowser, function () { | ||||
|                         instantiateWith(goodBrowser); | ||||
|                         expect(mockNotificationService.alert) | ||||
|                             .not.toHaveBeenCalled(); | ||||
|                     }); | ||||
|  | ||||
|                     badBrowsers.forEach(function (badBrowser) { | ||||
|                         it("is shown for " + badBrowser, function () { | ||||
|                             instantiateWith(badBrowser); | ||||
|                             expect(mockNotificationService.alert) | ||||
|                                 .toHaveBeenCalled(); | ||||
|                         }); | ||||
|                     }); | ||||
|                 }); | ||||
|             }); | ||||
|  | ||||
|         }); | ||||
|     } | ||||
| ); | ||||
|  | ||||
| @@ -67,21 +67,13 @@ define( | ||||
|                 mockScope.ngModel = { testField: 12321 }; | ||||
|                 mockScope.field = "testField"; | ||||
|                 mockScope.structure = { format: "someFormat" }; | ||||
|                 mockScope.ngBlur = jasmine.createSpy('blur'); | ||||
|  | ||||
|                 controller = new DateTimeFieldController( | ||||
|                     mockScope, | ||||
|                     mockFormatService | ||||
|                 ); | ||||
|             }); | ||||
|  | ||||
|             it("updates models from user-entered text", function () { | ||||
|                 var newText = "1977-05-25 17:30:00"; | ||||
|  | ||||
|                 mockScope.textValue = newText; | ||||
|                 fireWatch("textValue", newText); | ||||
|                 expect(mockScope.ngModel.testField) | ||||
|                     .toEqual(mockFormat.parse(newText)); | ||||
|                 expect(mockScope.textInvalid).toBeFalsy(); | ||||
|                 fireWatch("ngModel[field]", mockScope.ngModel.testField); | ||||
|             }); | ||||
|  | ||||
|             it("updates text from model values", function () { | ||||
| @@ -91,12 +83,55 @@ define( | ||||
|                 expect(mockScope.textValue).toEqual("1977-05-25 17:30:00"); | ||||
|             }); | ||||
|  | ||||
|             describe("when valid text is entered", function () { | ||||
|                 var newText; | ||||
|  | ||||
|                 beforeEach(function () { | ||||
|                     newText = "1977-05-25 17:30:00"; | ||||
|                     mockScope.textValue = newText; | ||||
|                     fireWatch("textValue", newText); | ||||
|                 }); | ||||
|  | ||||
|                 it("updates models from user-entered text", function () { | ||||
|                     expect(mockScope.ngModel.testField) | ||||
|                         .toEqual(mockFormat.parse(newText)); | ||||
|                     expect(mockScope.textInvalid).toBeFalsy(); | ||||
|                 }); | ||||
|  | ||||
|                 it("does not indicate a blur event", function () { | ||||
|                     expect(mockScope.ngBlur).not.toHaveBeenCalled(); | ||||
|                 }); | ||||
|             }); | ||||
|  | ||||
|             describe("when a date is chosen via the date picker", function () { | ||||
|                 var newValue; | ||||
|  | ||||
|                 beforeEach(function () { | ||||
|                     newValue = 12345654321; | ||||
|                     mockScope.pickerModel.value = newValue; | ||||
|                     fireWatch("pickerModel.value", newValue); | ||||
|                 }); | ||||
|  | ||||
|                 it("updates models", function () { | ||||
|                     expect(mockScope.ngModel.testField).toEqual(newValue); | ||||
|                 }); | ||||
|  | ||||
|                 it("fires a blur event", function () { | ||||
|                     expect(mockScope.ngBlur).toHaveBeenCalled(); | ||||
|                 }); | ||||
|             }); | ||||
|  | ||||
|             it("exposes toggle state for date-time picker", function () { | ||||
|                 expect(mockScope.picker.active).toBe(false); | ||||
|             }); | ||||
|  | ||||
|             describe("when user input is invalid", function () { | ||||
|                 var newText, oldValue; | ||||
|                 var newText, oldText, oldValue; | ||||
|  | ||||
|                 beforeEach(function () { | ||||
|                     newText = "Not a date"; | ||||
|                     oldValue = mockScope.ngModel.testField; | ||||
|                     oldText = mockScope.textValue; | ||||
|                     mockScope.textValue = newText; | ||||
|                     fireWatch("textValue", newText); | ||||
|                 }); | ||||
| @@ -112,6 +147,11 @@ define( | ||||
|                 it("does not modify user input", function () { | ||||
|                     expect(mockScope.textValue).toEqual(newText); | ||||
|                 }); | ||||
|  | ||||
|                 it("restores valid text values on request", function () { | ||||
|                     mockScope.restoreTextValue(); | ||||
|                     expect(mockScope.textValue).toEqual(oldText); | ||||
|                 }); | ||||
|             }); | ||||
|  | ||||
|             it("does not modify valid but irregular user input", function () { | ||||
|   | ||||
| @@ -91,6 +91,39 @@ define( | ||||
|                     .toHaveBeenCalledWith("ngModel", jasmine.any(Function)); | ||||
|             }); | ||||
|  | ||||
|             describe("when changes are made via form entry", function () { | ||||
|                 beforeEach(function () { | ||||
|                     mockScope.ngModel = { | ||||
|                         outer: { start: DAY * 2, end: DAY * 3 }, | ||||
|                         inner: { start: DAY * 2.25, end: DAY * 2.75 } | ||||
|                     }; | ||||
|                     mockScope.formModel = { | ||||
|                         start: DAY * 10000, | ||||
|                         end: DAY * 11000 | ||||
|                     }; | ||||
|                     // These watches may not exist, but Angular would fire | ||||
|                     // them if they did. | ||||
|                     fireWatchCollection("formModel", mockScope.formModel); | ||||
|                     fireWatch("formModel.start", mockScope.formModel.start); | ||||
|                     fireWatch("formModel.end", mockScope.formModel.end); | ||||
|                 }); | ||||
|  | ||||
|                 it("does not immediately make changes to the model", function () { | ||||
|                     expect(mockScope.ngModel.outer.start) | ||||
|                         .not.toEqual(mockScope.formModel.start); | ||||
|                     expect(mockScope.ngModel.outer.end) | ||||
|                         .not.toEqual(mockScope.formModel.end); | ||||
|                 }); | ||||
|  | ||||
|                 it("updates model bounds on request", function () { | ||||
|                     mockScope.updateBoundsFromForm(); | ||||
|                     expect(mockScope.ngModel.outer.start) | ||||
|                         .toEqual(mockScope.formModel.start); | ||||
|                     expect(mockScope.ngModel.outer.end) | ||||
|                         .toEqual(mockScope.formModel.end); | ||||
|                 }); | ||||
|             }); | ||||
|  | ||||
|             describe("when dragged", function () { | ||||
|                 beforeEach(function () { | ||||
|                     mockScope.ngModel = { | ||||
|   | ||||
| @@ -0,0 +1,95 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /*global define,Promise,describe,it,expect,beforeEach,waitsFor,jasmine*/ | ||||
|  | ||||
| define( | ||||
|     ["../../src/directives/MCTSplitPane"], | ||||
|     function (MCTSplitPane) { | ||||
|         'use strict'; | ||||
|  | ||||
|         var JQLITE_METHODS = [ | ||||
|                 'on', | ||||
|                 'addClass', | ||||
|                 'children', | ||||
|                 'eq' | ||||
|             ]; | ||||
|  | ||||
|         describe("The mct-split-pane directive", function () { | ||||
|             var mockParse, | ||||
|                 mockLog, | ||||
|                 mockInterval, | ||||
|                 mctSplitPane; | ||||
|  | ||||
|             beforeEach(function () { | ||||
|                 mockParse = jasmine.createSpy('$parse'); | ||||
|                 mockLog = | ||||
|                     jasmine.createSpyObj('$log', ['warn', 'info', 'debug']); | ||||
|                 mockInterval = jasmine.createSpy('$interval'); | ||||
|                 mockInterval.cancel = jasmine.createSpy('mockCancel'); | ||||
|                 mctSplitPane = new MCTSplitPane( | ||||
|                     mockParse, | ||||
|                     mockLog, | ||||
|                     mockInterval | ||||
|                 ); | ||||
|             }); | ||||
|  | ||||
|             it("is only applicable as an element", function () { | ||||
|                 expect(mctSplitPane.restrict).toEqual("E"); | ||||
|             }); | ||||
|  | ||||
|             describe("when its controller is applied", function () { | ||||
|                 var mockScope, | ||||
|                     mockElement, | ||||
|                     testAttrs, | ||||
|                     mockChildren, | ||||
|                     controller; | ||||
|  | ||||
|                 beforeEach(function () { | ||||
|                     mockScope = | ||||
|                         jasmine.createSpyObj('$scope', ['$apply', '$watch', '$on']); | ||||
|                     mockElement = | ||||
|                         jasmine.createSpyObj('element', JQLITE_METHODS); | ||||
|                     testAttrs = {}; | ||||
|                     mockChildren = | ||||
|                         jasmine.createSpyObj('children', JQLITE_METHODS); | ||||
|  | ||||
|                     mockElement.children.andReturn(mockChildren); | ||||
|                     mockChildren.eq.andReturn(mockChildren); | ||||
|                     mockChildren[0] = {}; | ||||
|  | ||||
|                     controller = mctSplitPane.controller[3]( | ||||
|                         mockScope, | ||||
|                         mockElement, | ||||
|                         testAttrs | ||||
|                     ); | ||||
|                 }); | ||||
|  | ||||
|                 it("sets an interval which does not trigger digests", function () { | ||||
|                     expect(mockInterval.mostRecentCall.args[3]).toBe(false); | ||||
|                 }); | ||||
|  | ||||
|             }); | ||||
|  | ||||
|         }); | ||||
|  | ||||
|     } | ||||
| ); | ||||
| @@ -19,8 +19,10 @@ | ||||
|     "directives/MCTPopup", | ||||
|     "directives/MCTResize", | ||||
|     "directives/MCTScroll", | ||||
|     "directives/MCTSplitPane", | ||||
|     "services/Popup", | ||||
|     "services/PopupService", | ||||
|     "services/UrlService", | ||||
|     "StyleSheetLoader" | ||||
|     "StyleSheetLoader", | ||||
|     "UnsupportedBrowserWarning" | ||||
| ] | ||||
|   | ||||
| @@ -43,6 +43,7 @@ define( | ||||
|             var userAgent = $window.navigator.userAgent, | ||||
|                 matches = userAgent.match(/iPad|iPhone|Android/i) || []; | ||||
|  | ||||
|             this.userAgent = userAgent; | ||||
|             this.mobileName = matches[0]; | ||||
|             this.$window = $window; | ||||
|         } | ||||
| @@ -91,6 +92,18 @@ define( | ||||
|             return !this.isPortrait(); | ||||
|         }; | ||||
|  | ||||
|         /** | ||||
|          * Check if the user agent matches a certain named device, | ||||
|          * as indicated by checking for a case-insensitive substring | ||||
|          * match. | ||||
|          * @param {string} name the name to check for | ||||
|          * @returns {boolean} true if the user agent includes that name | ||||
|          */ | ||||
|         AgentService.prototype.isBrowser = function (name) { | ||||
|             name = name.toLowerCase(); | ||||
|             return this.userAgent.toLowerCase().indexOf(name) !== -1; | ||||
|         }; | ||||
|  | ||||
|         return AgentService; | ||||
|     } | ||||
| ); | ||||
|   | ||||
| @@ -85,7 +85,7 @@ define( | ||||
|             function link(scope, element, attrs, ctrl, transclude) { | ||||
|                 if (deviceMatches(attrs.mctDevice)) { | ||||
|                     transclude(function (clone) { | ||||
|                         element.parent().append(clone); | ||||
|                         element.replaceWith(clone); | ||||
|                     }); | ||||
|                 } | ||||
|             } | ||||
|   | ||||
| @@ -81,6 +81,13 @@ define( | ||||
|                 expect(agentService.isPortrait()).toBeTruthy(); | ||||
|                 expect(agentService.isLandscape()).toBeFalsy(); | ||||
|             }); | ||||
|  | ||||
|             it("allows for checking browser type", function () { | ||||
|                 testWindow.navigator.userAgent = "Chromezilla Safarifox"; | ||||
|                 agentService = new AgentService(testWindow); | ||||
|                 expect(agentService.isBrowser("Chrome")).toBe(true); | ||||
|                 expect(agentService.isBrowser("Firefox")).toBe(false); | ||||
|             }); | ||||
|         }); | ||||
|     } | ||||
| ); | ||||
|   | ||||
| @@ -26,13 +26,12 @@ define( | ||||
|     function (MCTDevice) { | ||||
|         "use strict"; | ||||
|  | ||||
|         var JQLITE_METHODS = [ 'parent', 'append' ]; | ||||
|         var JQLITE_METHODS = [ 'replaceWith' ]; | ||||
|  | ||||
|         describe("The mct-device directive", function () { | ||||
|             var mockAgentService, | ||||
|                 mockTransclude, | ||||
|                 mockElement, | ||||
|                 mockParent, | ||||
|                 mockClone, | ||||
|                 testAttrs, | ||||
|                 directive; | ||||
| @@ -48,11 +47,8 @@ define( | ||||
|                 ); | ||||
|                 mockTransclude = jasmine.createSpy("$transclude"); | ||||
|                 mockElement = jasmine.createSpyObj(name, JQLITE_METHODS); | ||||
|                 mockParent = jasmine.createSpyObj(name, JQLITE_METHODS); | ||||
|                 mockClone = jasmine.createSpyObj(name, JQLITE_METHODS); | ||||
|  | ||||
|                 mockElement.parent.andReturn(mockParent); | ||||
|  | ||||
|                 mockTransclude.andCallFake(function (fn) { | ||||
|                     fn(mockClone); | ||||
|                 }); | ||||
| @@ -65,6 +61,15 @@ define( | ||||
|                 directive = new MCTDevice(mockAgentService); | ||||
|             }); | ||||
|  | ||||
|             function expectInclusion() { | ||||
|                 expect(mockElement.replaceWith) | ||||
|                     .toHaveBeenCalledWith(mockClone); | ||||
|             } | ||||
|  | ||||
|             function expectExclusion() { | ||||
|                 expect(mockElement.replaceWith).not.toHaveBeenCalled(); | ||||
|             } | ||||
|  | ||||
|             it("is applicable at the attribute level", function () { | ||||
|                 expect(directive.restrict).toEqual("A"); | ||||
|             }); | ||||
| @@ -80,54 +85,54 @@ define( | ||||
|             it("restricts element inclusion for mobile devices", function () { | ||||
|                 testAttrs.mctDevice = "mobile"; | ||||
|                 link(); | ||||
|                 expect(mockParent.append).not.toHaveBeenCalled(); | ||||
|                 expectExclusion(); | ||||
|  | ||||
|                 mockAgentService.isMobile.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).toHaveBeenCalledWith(mockClone); | ||||
|                 expectInclusion(); | ||||
|             }); | ||||
|  | ||||
|             it("restricts element inclusion for tablet devices", function () { | ||||
|                 testAttrs.mctDevice = "tablet"; | ||||
|                 mockAgentService.isMobile.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).not.toHaveBeenCalled(); | ||||
|                 expectExclusion(); | ||||
|  | ||||
|                 mockAgentService.isTablet.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).toHaveBeenCalledWith(mockClone); | ||||
|                 expectInclusion(); | ||||
|             }); | ||||
|  | ||||
|             it("restricts element inclusion for phone devices", function () { | ||||
|                 testAttrs.mctDevice = "phone"; | ||||
|                 mockAgentService.isMobile.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).not.toHaveBeenCalled(); | ||||
|                 expectExclusion(); | ||||
|  | ||||
|                 mockAgentService.isPhone.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).toHaveBeenCalledWith(mockClone); | ||||
|                 expectInclusion(); | ||||
|             }); | ||||
|  | ||||
|             it("restricts element inclusion for desktop devices", function () { | ||||
|                 testAttrs.mctDevice = "desktop"; | ||||
|                 mockAgentService.isMobile.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).not.toHaveBeenCalled(); | ||||
|                 expectExclusion(); | ||||
|  | ||||
|                 mockAgentService.isMobile.andReturn(false); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).toHaveBeenCalledWith(mockClone); | ||||
|                 expectInclusion(); | ||||
|             }); | ||||
|  | ||||
|             it("restricts element inclusion for portrait orientation", function () { | ||||
|                 testAttrs.mctDevice = "portrait"; | ||||
|                 link(); | ||||
|                 expect(mockParent.append).not.toHaveBeenCalled(); | ||||
|                 expectExclusion(); | ||||
|  | ||||
|                 mockAgentService.isPortrait.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).toHaveBeenCalledWith(mockClone); | ||||
|                 expectInclusion(); | ||||
|             }); | ||||
|  | ||||
|             it("restricts element inclusion for landscape orientation", function () { | ||||
| @@ -135,11 +140,11 @@ define( | ||||
|                 mockAgentService.isLandscape.andReturn(false); | ||||
|                 mockAgentService.isPortrait.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).not.toHaveBeenCalled(); | ||||
|                 expectExclusion(); | ||||
|  | ||||
|                 mockAgentService.isLandscape.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).toHaveBeenCalledWith(mockClone); | ||||
|                 expectInclusion(); | ||||
|             }); | ||||
|  | ||||
|             it("allows multiple device characteristics to be requested", function () { | ||||
| @@ -148,17 +153,17 @@ define( | ||||
|                 testAttrs.mctDevice = "portrait mobile"; | ||||
|                 link(); | ||||
|                 // Neither portrait nor mobile, not called | ||||
|                 expect(mockParent.append).not.toHaveBeenCalled(); | ||||
|                 expectExclusion(); | ||||
|  | ||||
|                 mockAgentService.isPortrait.andReturn(true); | ||||
|                 link(); | ||||
|  | ||||
|                 // Was portrait, but not mobile, so no | ||||
|                 expect(mockParent.append).not.toHaveBeenCalled(); | ||||
|                 expectExclusion(); | ||||
|  | ||||
|                 mockAgentService.isMobile.andReturn(true); | ||||
|                 link(); | ||||
|                 expect(mockParent.append).toHaveBeenCalledWith(mockClone); | ||||
|                 expectInclusion(); | ||||
|             }); | ||||
|         }); | ||||
|     } | ||||
|   | ||||
| @@ -1,12 +1,18 @@ | ||||
| { | ||||
|   "name": "Espresso", | ||||
|   "description": "Espresso theme: dark and rich", | ||||
|   "extensions": { | ||||
|     "stylesheets": [ | ||||
|       { | ||||
|         "stylesheetUrl": "css/theme-espresso.css", | ||||
|         "priority": 1000 | ||||
|       } | ||||
|     ] | ||||
|   } | ||||
| } | ||||
|     "name": "Espresso", | ||||
|     "description": "Espresso theme: dark and rich", | ||||
|     "extensions": { | ||||
|         "stylesheets": [ | ||||
|             { | ||||
|                 "stylesheetUrl": "css/theme-espresso.css", | ||||
|                 "priority": 1000 | ||||
|             } | ||||
|         ], | ||||
|         "constants": [ | ||||
|             { | ||||
|                 "key": "THEME", | ||||
|                 "value": "espresso" | ||||
|             } | ||||
|         ] | ||||
|     } | ||||
| } | ||||
|   | ||||
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							| @@ -1,12 +1,18 @@ | ||||
| { | ||||
|   "name": "Sonw", | ||||
|   "description": "Snow theme: light and cool", | ||||
|   "extensions": { | ||||
|     "stylesheets": [ | ||||
|       { | ||||
|         "stylesheetUrl": "css/theme-snow.css", | ||||
|         "priority": 1000 | ||||
|       } | ||||
|     ] | ||||
|   } | ||||
| } | ||||
|     "name": "Snow", | ||||
|     "description": "Snow theme: light and cool", | ||||
|     "extensions": { | ||||
|         "stylesheets": [ | ||||
|             { | ||||
|                 "stylesheetUrl": "css/theme-snow.css", | ||||
|                 "priority": 1000 | ||||
|             } | ||||
|         ], | ||||
|         "constants": [ | ||||
|             { | ||||
|                 "key": "THEME", | ||||
|                 "value": "snow" | ||||
|             } | ||||
|         ] | ||||
|     } | ||||
| } | ||||
|   | ||||
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							| @@ -73,6 +73,14 @@ $colorInputFg: $colorBodyFg; | ||||
| $colorFormText: pushBack($colorBodyFg, 10%); | ||||
| $colorInputIcon: pushBack($colorBodyFg, 25%); | ||||
|  | ||||
| // Inspector | ||||
| $colorInspectorBg: pullForward($colorBodyBg, 5%); | ||||
| $colorInspectorFg: $colorBodyFg; | ||||
| $colorInspectorPropName: pushBack($colorBodyFg, 20%); | ||||
| $colorInspectorPropVal: pullForward($colorInspectorFg, 15%); | ||||
| $colorInspectorSectionHeaderBg: pullForward($colorInspectorBg, 5%); | ||||
| $colorInspectorSectionHeaderFg: pullForward($colorInspectorBg, 40%); | ||||
|  | ||||
| // Status colors, mainly used for messaging and item ancillary symbols | ||||
| $colorStatusFg: #fff; | ||||
| $colorStatusDefault: #ccc; | ||||
| @@ -89,14 +97,6 @@ $shdwStatusIc: rgba(white, 0.8) 0 0px 5px; | ||||
| $colorSelectBg: #ddd; | ||||
| $colorSelectFg: $colorBodyFg; | ||||
|  | ||||
| // Inspector | ||||
| $colorInspectorBg: pullForward($colorBodyBg, 5%); | ||||
| $colorInspectorFg: $colorBodyFg; | ||||
| $colorInspectorPropName: pushBack($colorBodyFg, 20%); | ||||
| $colorInspectorPropVal: pullForward($colorInspectorFg, 15%); | ||||
| $colorInspectorSectionHeaderBg: pullForward($colorInspectorBg, 5%); | ||||
| $colorInspectorSectionHeaderFg: pullForward($colorInspectorBg, 40%); | ||||
|  | ||||
| // Limits and staleness colors// | ||||
| $colorTelemFresh: pullForward($colorBodyFg, 20%); | ||||
| $colorTelemStale: pushBack($colorBodyFg, 20%); | ||||
|   | ||||
| @@ -1,4 +1,4 @@ | ||||
| @mixin containerSubtle($bg: $colorBodyBg, $fg: $colorBodyFg) { | ||||
| @mixin containerSubtle($bg: $colorBodyBg, $fg: $colorBodyFg, $hover: false) { | ||||
| 	@include containerBase($bg, $fg); | ||||
| 	@include boxShdw($shdwBtns); | ||||
| } | ||||
|   | ||||
| @@ -2,6 +2,11 @@ | ||||
|     "name": "Open MCT Web Core", | ||||
|     "description": "Defines core concepts of Open MCT Web.", | ||||
|     "sources": "src", | ||||
|     "configuration": { | ||||
|         "paths": { | ||||
|             "uuid": "uuid" | ||||
|         } | ||||
|     }, | ||||
|     "extensions": { | ||||
|         "versions": [ | ||||
|             { | ||||
| @@ -33,7 +38,7 @@ | ||||
|                 "provides": "objectService", | ||||
|                 "type": "provider", | ||||
|                 "implementation": "objects/DomainObjectProvider.js", | ||||
|                 "depends": [ "modelService", "capabilityService", "$q" ] | ||||
|                 "depends": [ "modelService", "instantiate" ] | ||||
|             }, | ||||
|             { | ||||
|                 "provides": "capabilityService", | ||||
| @@ -67,8 +72,7 @@ | ||||
|                     "persistenceService", | ||||
|                     "$q", | ||||
|                     "now", | ||||
|                     "PERSISTENCE_SPACE", | ||||
|                     "ADDITIONAL_PERSISTENCE_SPACES" | ||||
|                     "PERSISTENCE_SPACE" | ||||
|                 ] | ||||
|             }, | ||||
|             { | ||||
| @@ -92,7 +96,7 @@ | ||||
|                 "provides": "actionService", | ||||
|                 "type": "provider", | ||||
|                 "implementation": "actions/ActionProvider.js", | ||||
|                 "depends": [ "actions[]" ] | ||||
|                 "depends": [ "actions[]", "$log" ] | ||||
|             }, | ||||
|             { | ||||
|                 "provides": "actionService", | ||||
| @@ -110,6 +114,12 @@ | ||||
|                 "type": "provider", | ||||
|                 "implementation": "views/ViewProvider.js", | ||||
|                 "depends": [ "views[]", "$log" ] | ||||
|             }, | ||||
|             { | ||||
|                 "provides": "identifierService", | ||||
|                 "type": "provider", | ||||
|                 "implementation": "identifiers/IdentifierProvider.js", | ||||
|                 "depends": [ "PERSISTENCE_SPACE" ] | ||||
|             } | ||||
|         ], | ||||
|         "types": [ | ||||
| @@ -178,7 +188,8 @@ | ||||
|             { | ||||
|                 "key": "persistence", | ||||
|                 "implementation": "capabilities/PersistenceCapability.js", | ||||
|                 "depends": [ "persistenceService", "PERSISTENCE_SPACE" ] | ||||
|                 "depends": [ "persistenceService", "identifierService", | ||||
|                     "notificationService", "$q" ] | ||||
|             }, | ||||
|             { | ||||
|                 "key": "metadata", | ||||
| @@ -193,6 +204,11 @@ | ||||
|                 "key": "delegation", | ||||
|                 "implementation": "capabilities/DelegationCapability.js", | ||||
|                 "depends": [ "$q" ] | ||||
|             }, | ||||
|             { | ||||
|                 "key": "instantiation", | ||||
|                 "implementation": "capabilities/InstantiationCapability.js", | ||||
|                 "depends": [ "$injector", "identifierService" ] | ||||
|             } | ||||
|         ], | ||||
|         "services": [ | ||||
| @@ -207,12 +223,18 @@ | ||||
|             }, | ||||
|             { | ||||
|                 "key": "topic", | ||||
|                 "implementation": "services/Topic.js" | ||||
|                 "implementation": "services/Topic.js", | ||||
|                 "depends": [ "$log" ] | ||||
|             }, | ||||
|             { | ||||
|                 "key": "contextualize", | ||||
|                 "implementation": "services/Contextualize.js", | ||||
|                 "depends": [ "$log" ] | ||||
|             }, | ||||
|             { | ||||
|                 "key": "instantiate", | ||||
|                 "implementation": "services/Instantiate.js", | ||||
|                 "depends": [ "capabilityService" ] | ||||
|             } | ||||
|         ], | ||||
|         "roots": [ | ||||
| @@ -229,11 +251,18 @@ | ||||
|             { | ||||
|                 "key": "PERSISTENCE_SPACE", | ||||
|                 "value": "mct" | ||||
|             }, | ||||
|             } | ||||
|         ], | ||||
|         "licenses": [ | ||||
|             { | ||||
|                 "key": "ADDITIONAL_PERSISTENCE_SPACES", | ||||
|                 "value": [], | ||||
|                 "description": "An array of additional persistence spaces to load models from." | ||||
|                 "name": "Math.uuid.js", | ||||
|                 "version": "1.4", | ||||
|                 "description": "Unique identifer generation (code adapted.)", | ||||
|                 "author": "Robert Kieffer", | ||||
|                 "website": "https://github.com/broofa/node-uuid", | ||||
|                 "copyright": "Copyright (c) 2010 Robert Kieffer", | ||||
|                 "license": "license-mit", | ||||
|                 "link": "http://opensource.org/licenses/MIT" | ||||
|             } | ||||
|         ] | ||||
|     } | ||||
|   | ||||
| @@ -39,9 +39,11 @@ define( | ||||
|          * @imeplements {ActionService} | ||||
|          * @constructor | ||||
|          */ | ||||
|         function ActionProvider(actions) { | ||||
|         function ActionProvider(actions, $log) { | ||||
|             var self = this; | ||||
|  | ||||
|             this.$log = $log; | ||||
|  | ||||
|             // Build up look-up tables | ||||
|             this.actions = actions; | ||||
|             this.actionsByKey = {}; | ||||
| @@ -74,6 +76,7 @@ define( | ||||
|             var context = (actionContext || {}), | ||||
|                 category = context.category, | ||||
|                 key = context.key, | ||||
|                 $log = this.$log, | ||||
|                 candidates; | ||||
|  | ||||
|             // Instantiate an action; invokes the constructor and | ||||
| @@ -103,12 +106,31 @@ define( | ||||
|             // appliesTo method of given actions (if defined), and | ||||
|             // instantiate those applicable actions. | ||||
|             function createIfApplicable(actions, context) { | ||||
|                 return (actions || []).filter(function (Action) { | ||||
|                     return Action.appliesTo ? | ||||
|                         Action.appliesTo(context) : true; | ||||
|                 }).map(function (Action) { | ||||
|                     return instantiateAction(Action, context); | ||||
|                 }); | ||||
|                 function isApplicable(Action) { | ||||
|                     return Action.appliesTo ? Action.appliesTo(context) : true; | ||||
|                 } | ||||
|  | ||||
|                 function instantiate(Action) { | ||||
|                     try { | ||||
|                         return instantiateAction(Action, context); | ||||
|                     } catch (e) { | ||||
|                         $log.error([ | ||||
|                             "Could not instantiate action", | ||||
|                             Action.key, | ||||
|                             "due to:", | ||||
|                             e.message | ||||
|                         ].join(" ")); | ||||
|                         return undefined; | ||||
|                     } | ||||
|                 } | ||||
|  | ||||
|                 function isDefined(action) { | ||||
|                     return action !== undefined; | ||||
|                 } | ||||
|  | ||||
|                 return (actions || []).filter(isApplicable) | ||||
|                     .map(instantiate) | ||||
|                     .filter(isDefined); | ||||
|             } | ||||
|  | ||||
|             // Match actions to the provided context by comparing "key" | ||||
|   | ||||
							
								
								
									
										77
									
								
								platform/core/src/capabilities/InstantiationCapability.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										77
									
								
								platform/core/src/capabilities/InstantiationCapability.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,77 @@ | ||||
| /***************************************************************************** | ||||
|  * Open MCT Web, Copyright (c) 2014-2015, United States Government | ||||
|  * as represented by the Administrator of the National Aeronautics and Space | ||||
|  * Administration. All rights reserved. | ||||
|  * | ||||
|  * Open MCT Web is licensed under the Apache License, Version 2.0 (the | ||||
|  * "License"); you may not use this file except in compliance with the License. | ||||
|  * You may obtain a copy of the License at | ||||
|  * http://www.apache.org/licenses/LICENSE-2.0. | ||||
|  * | ||||
|  * Unless required by applicable law or agreed to in writing, software | ||||
|  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||||
|  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||||
|  * License for the specific language governing permissions and limitations | ||||
|  * under the License. | ||||
|  * | ||||
|  * Open MCT Web includes source code licensed under additional open source | ||||
|  * licenses. See the Open Source Licenses file (LICENSES.md) included with | ||||
|  * this source code distribution or the Licensing information page available | ||||
|  * at runtime from the About dialog for additional information. | ||||
|  *****************************************************************************/ | ||||
| /*global define,Promise*/ | ||||
|  | ||||
| define( | ||||
|     ['../objects/DomainObjectImpl'], | ||||
|     function (DomainObjectImpl) { | ||||
|         'use strict'; | ||||
|  | ||||
|         /** | ||||
|          * Implements the `instantiation` capability. This allows new domain | ||||
|          * objects to be instantiated. | ||||
|          * | ||||
|          * @constructor | ||||
|          * @memberof platform/core | ||||
|          * @param $injector Angular's `$injector` | ||||
|          * @implements {Capability} | ||||
|          */ | ||||
|         function InstantiationCapability($injector, identifierService, domainObject) { | ||||
|             this.$injector = $injector; | ||||
|             this.identifierService = identifierService; | ||||
|             this.domainObject = domainObject; | ||||
|         } | ||||
|  | ||||
|         /** | ||||
|          * Instantiate a new domain object with the provided model. | ||||
|          * | ||||
|          * This domain object will have been simply instantiated; it will not | ||||
|          * have been persisted, nor will it have been added to the | ||||
|          * composition of the object which exposed this capability. | ||||
|          * | ||||
|          * @param {object} the model for the new domain object | ||||
|          * @returns {DomainObject} the new domain object | ||||
|          */ | ||||
|         InstantiationCapability.prototype.instantiate = function (model) { | ||||
|             var parsedId = | ||||
|                     this.identifierService.parse(this.domainObject.getId()), | ||||
|                 space = parsedId.getDefinedSpace(), | ||||
|                 id = this.identifierService.generate(space); | ||||
|  | ||||
|             // Lazily initialize; instantiate depends on capabilityService, | ||||
|             // which depends on all capabilities, including this one. | ||||
|             this.instantiateFn = this.instantiateFn || | ||||
|                 this.$injector.get("instantiate"); | ||||
|  | ||||
|             return this.instantiateFn(model, id); | ||||
|         }; | ||||
|  | ||||
|         /** | ||||
|          * Alias of `instantiate`. | ||||
|          * @see {platform/core.CreationCapability#instantiate} | ||||
|          */ | ||||
|         InstantiationCapability.prototype.invoke = | ||||
|             InstantiationCapability.prototype.instantiate; | ||||
|  | ||||
|         return InstantiationCapability; | ||||
|     } | ||||
| ); | ||||
Some files were not shown because too many files have changed in this diff Show More
		Reference in New Issue
	
	Block a user