mirror of
https://github.com/nasa/openmct.git
synced 2025-06-14 21:28:12 +00:00
[Example] Add new example bundle
Add an example bundle containing custom extensions, which can be recognized by extensions from another bundle. WTD-518.
This commit is contained in:
@ -8,6 +8,10 @@ define(
|
||||
function () {
|
||||
"use strict";
|
||||
|
||||
var HAS_EXTENSIONS = "A directive loaded these example extensions.",
|
||||
NO_EXTENSIONS = "A directive tried to load example extensions," +
|
||||
" but found none.";
|
||||
|
||||
/**
|
||||
*
|
||||
* @constructor
|
||||
@ -15,9 +19,9 @@ define(
|
||||
function ExampleDirective(examples) {
|
||||
// Build up a template from example extensions
|
||||
var template = examples.length > 0 ?
|
||||
"A directive loaded these example extensions:<ul>" :
|
||||
"This came from a directive.<ul>";
|
||||
HAS_EXTENSIONS : NO_EXTENSIONS;
|
||||
|
||||
template += "<ul>"
|
||||
examples.forEach(function (e) {
|
||||
template += "<li>" + e.text + "</li>";
|
||||
});
|
||||
|
Reference in New Issue
Block a user