Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
title: 'Please Input Code',
scrollbar: false,
area: ['400px', '300px'],
moveOut: true,
moveType: 1
}, function (value, index) {
service_1.DataStore.socket.emit('key', value);
// layer.msg(value); //得到value
layer.close(index);
});
};
NavComponent = __decorate([
core_1.Component({
selector: 'nav',
template: "<div class="\"nav\"">\n <ul>\n <li><a><img height="\"26px\"/" src="\"./imgs/logo.png\""></a>\n </li>\n <li k="index">\n <a>{{v.name}}</a>\n <ul>\n <li>\n <a>{{vv.name}}</a>\n <a id="\"{{vv.id}}\"">{{vv.name}}</a>\n </li>\n </ul>\n </li>\n </ul>\n</div>",
directives: [router_deprecated_1.ROUTER_DIRECTIVES, common_1.NgClass]
}),
__metadata('design:paramtypes', [service_1.AppService, core_2.Logger])
], NavComponent);
return NavComponent;
}());
exports.NavComponent = NavComponent;
});
// route the user to a view based on presence of access token
if (auth.isUserAuthenticated) {
// access token exists...display the users files
router.navigate(["/Home"]);
}
else {
// access token doesn't exist, so the user needs to login
router.navigate(["/Login"]);
}
}
App = __decorate([
core_1.Component({
selector: "graph-app",
templateUrl: __dirname + "/view-main.html",
directives: [router_deprecated_1.ROUTER_DIRECTIVES, profile_1.Profile]
}),
router_deprecated_1.RouteConfig([
{ name: "Default", path: "", redirectTo: ["Login"] },
{ name: "Home", component: home_1.Home, path: "/home" },
{ name: "Login", component: login_1.Login, path: "/login" },
{ name: "Files", component: files_1.Files, path: "/files" },
{ name: "Groups", component: groups_1.Groups, path: "/groups" },
{ name: "Contacts", component: contacts_1.Contacts, path: "/contacts" },
{ name: "Mails", component: mails_1.Mails, path: "/mails" },
{ name: "Notes", component: notes_1.Notes, path: "/notes" },
{ name: "Tasks", component: tasks_1.Tasks, path: "/tasks" },
{ name: "Trending", component: trending_1.Trending, path: "/trending" },
{ name: "Users", component: users_1.Users, path: "/users" },
]),
__metadata('design:paramtypes', [http_1.Http, router_deprecated_1.Router, authHelper_1.AuthHelper])
], App);
};
ItemListComponent.prototype.onRatingClicked = function (message) {
this.pageTitle = 'Item List: ' + message;
};
ItemListComponent.prototype.addItemToCart = function (item) {
this.cart.itemExists(item, function (service, item) {
service.addItem(item).subscribe(function (items) { return console.log("Added to Cart"); }, function (error) { return console.log(error); });
});
};
ItemListComponent = __decorate([
core_1.Component({
selector: 'list-item',
templateUrl: 'app/item-list/item-list.component.html',
styleUrls: ['app/item-list/item-list.component.css'],
pipes: [item_filter_pipe_1.ItemFilterPipe],
directives: [star_component_1.StarComponent, form_component_1.FormComponent, router_deprecated_1.ROUTER_DIRECTIVES],
providers: [item_service_1.ItemService, cart_service_1.CartService]
}),
__metadata('design:paramtypes', [item_service_1.ItemService, auth_service_1.AuthService, (typeof (_a = typeof cart_service_1.CartService !== 'undefined' && cart_service_1.CartService) === 'function' && _a) || Object])
], ItemListComponent);
return ItemListComponent;
var _a;
}());
exports.ItemListComponent = ItemListComponent;
return _user.Username;
}
else
return 'Account';
};
AppRoot.prototype.logout = function () {
this.membershipService.logout()
.subscribe(function (res) {
localStorage.removeItem('user');
}, function (error) { return console.error('Error: ' + error); }, function () { });
};
AppRoot = __decorate([
core_1.Component({
selector: 'photogallery-app',
templateUrl: './app/app.html',
directives: [router_deprecated_1.ROUTER_DIRECTIVES, common_1.CORE_DIRECTIVES]
}),
router_deprecated_1.RouteConfig(routes_1.APP_ROUTES),
__metadata('design:paramtypes', [membershipService_1.MembershipService, common_2.Location])
], AppRoot);
return AppRoot;
}());
exports.AppRoot = AppRoot;
}
_this.getShopItems(true);
}, function (error) { return console.log(error); });
};
ShopItemListComponent.prototype.addToCart = function (item) {
this.cart.itemExists(item, function (service, item) {
service.addItem(item).subscribe(function (items) { return console.log("Added to Cart"); }, function (error) { return console.log(error); });
});
};
ShopItemListComponent = __decorate([
core_1.Component({
selector: 'list-item',
templateUrl: 'app/shop/shop-item-list/shop-item-list.component.html',
styleUrls: ['app/shop/shop-item-list/shop-item-list.component.css'],
pipes: [shop_item_filter_pipe_1.ItemFilterPipe],
directives: [shop_item_form_component_1.FormComponent, router_deprecated_1.ROUTER_DIRECTIVES],
providers: [shop_service_1.ShopService, cart_service_1.CartService]
}),
__metadata('design:paramtypes', [shop_service_1.ShopService, auth_service_1.AuthService, cart_service_1.CartService])
], ShopItemListComponent);
return ShopItemListComponent;
}());
exports.ShopItemListComponent = ShopItemListComponent;
var AppComponent = (function () {
function AppComponent() {
this.title = 'Phosphor';
}
AppComponent = __decorate([
core_1.Component({
selector: 'my-app',
template: "\n \n ",
styleUrls: ['app/css/app.component.css'],
directives: [router_deprecated_1.ROUTER_DIRECTIVES],
providers: [
router_deprecated_1.ROUTER_PROVIDERS,
]
}),
router_deprecated_1.RouteConfig([
{
path: '/',
name: 'Dashboard',
component: dashboard_component_1.DashboardComponent,
useAsDefault: true
}
]),
__metadata('design:paramtypes', [])
], AppComponent);
return AppComponent;
}());
var AppComponent = (function () {
function AppComponent() {
this.DataStore = service_1.DataStore;
}
AppComponent = __decorate([
core_1.Component({
selector: 'body',
template: "<nav></nav>\n<span style="\"display:none\"" id="\"liuzheng\"">liuzheng</span>\n",
directives: [nav_1.NavComponent, router_deprecated_1.ROUTER_DIRECTIVES],
providers: [service_1.AppService, router_deprecated_1.ROUTER_PROVIDERS]
}),
router_deprecated_1.RouteConfig([
{ path: '/login', name: 'Login', component: login_1.LoginComponent },
{ path: '/', name: 'Index', component: IndexComponent },
{ path: '/aaa', name: 'Aaaa', component: IndexComponent },
{ path: '/bifrost', name: 'WorkboardComponent', component: WorkboardComponent },
{ path: '/hostedit', name: 'HostEdit', component: hostedit_1.HostEditComponent },
]),
__metadata('design:paramtypes', [])
], AppComponent);
return AppComponent;
}());
exports.AppComponent = AppComponent;
var AppComponent = (function () {
function AppComponent(auth) {
this.auth = auth;
}
AppComponent.prototype.login = function () {
this.auth.login();
};
AppComponent = __decorate([
core_1.Component({
selector: 'app-content',
directives: [router_deprecated_1.ROUTER_DIRECTIVES, shop_item_list_component_1.ShopItemListComponent, cart_item_list_component_1.ItemCartComponent],
providers: [router_deprecated_1.ROUTER_PROVIDERS, http_1.HTTP_PROVIDERS, auth_service_1.AuthService],
template: "\n\t\t<nav class="\"navbar">\n\t <div class="\"container\"">\n\t <div class="\"navbar-header\"">\n\t <button aria-controls="\"navbar\"" aria-expanded="\"false\"" data-target="\"#navbar\"" data-toggle="\"collapse\"" class="\"navbar-toggle" type="\"button\"">\n\t <span class="\"sr-only\"">Toggle navigation</span>\n\t <span class="\"icon-bar\""></span>\n\t <span class="\"icon-bar\""></span>\n\t <span class="\"icon-bar\""></span>\n\t </button>\n\t <a href="\"#\"" class="\"navbar-brand\"">\n\t \t<span aria-hidden="\"true\"" class="\"glyphicon">Cartify</span>\n\t </a>\n\t </div>\n\t <div class="\"navbar-collapse" id="\"navbar\"">\n\t <form class="\"navbar-form">\n\t <button class="\"btn">\n\t <span aria-hidden="\"true\"" class="\"glyphicon"></span> Sign In\n\t </button>\n\t <button class="\"btn">\n\t <span aria-hidden="\"true\"" class="\"glyphicon"></span> Sign Out\n\t </button>\n\t </form>\n\t </div>\n\t </div>\n\t </nav>\n\t <div class="\"container\"">\n\t \t<div class="\"starter-template\"">\n\t \t\t<br><br><br>\n\t \t\t\n\t \t</div>\n\t </div>\n\t",
}),
router_deprecated_1.RouteConfig([
{ path: '/items', name: 'Items', component: shop_item_list_component_1.ShopItemListComponent, useAsDefault: true },
{ path: '/item/:id', name: 'Detail', component: shop_item_detail_component_1.ShopItemDetailComponent },
{ path: '/cart/:customerId', name: 'Cart', component: cart_item_list_component_1.ItemCartComponent }
]),
__metadata('design:paramtypes', [auth_service_1.AuthService])
], AppComponent);
return AppComponent;
}());
exports.AppComponent = AppComponent;
}
VgDemo.prototype.ngOnInit = function () {
var _this = this;
this.router.subscribe(function () {
_this.activeView = _this.location.path();
});
};
VgDemo = __decorate([
core_1.Component({
selector: 'vg-demo',
templateUrl: 'src/app.html',
styles: [
"\n :host {\n display: block;\n margin: 0 auto;\n max-width: 1200px;\n font-family: \"Helvetica Neue\", Helvetica, Arial, sans-serif;\n }\n\n :host header {\n padding: 10px 30px;\n color: white;\n background-color: #507EB3;\n z-index: 1;\n position: relative;\n }\n\n :host aside {\n width: 250px;\n height: 100%;\n position: fixed;\n top: 0;\n padding-top: 100px;\n color: white;\n background-color: #507EB3;\n }\n\n :host aside nav {\n width: 100%;\n color: white;\n background-color: #507EB3;\n }\n\n :host aside nav ul {\n padding: 0;\n list-style-type: none;\n }\n\n :host aside nav ul li a {\n text-decoration: none;\n color: #ffffff;\n font-size: 1.2em;\n width: calc(100% - 20px);\n display: inline-block;\n padding: 10px;\n }\n\n :host aside nav ul li a:hover {\n color: #507EB3;\n background-color: white;\n text-decoration: none;\n }\n\n :host aside nav ul li a.router-link-active {\n color: #507EB3;\n background-color: white;\n text-decoration: none;\n }\n\n :host section {\n padding-left: 280px;\n padding-right: 30px;\n margin: auto;\n }\n\n :host section .router-container {\n margin: 0 auto;\n }\n "
],
directives: [
router_deprecated_1.ROUTER_DIRECTIVES
]
}),
router_deprecated_1.RouteConfig([
{ path: '/single-media-player', name: 'SingleMediaPlayer', component: single_media_player_1.SingleMediaPlayer, useAsDefault: true },
{ path: '/multiple-media-player', name: 'MultipleMediaPlayer', component: multiple_media_player_1.MultipleMediaPlayer },
{ path: '/audio-player', name: 'AudioPlayer', component: audio_player_1.AudioPlayer },
{ path: '/bound-player', name: 'BoundPlayer', component: bound_player_1.BoundPlayer },
{ path: '/cue-points-player', name: 'CuePointsPlayer', component: cue_points_player_1.CuePointsPlayer },
{ path: '/video-360', name: 'Video360Player', component: video_360_player_1.Video360Player },
{ path: '/video-vr', name: 'VideoVrPlayer', component: video_vr_player_1.VideoVrPlayer },
{ path: '/**', redirectTo: ['SingleMediaPlayer'] }
]),
__metadata('design:paramtypes', [router_deprecated_1.Router, common_1.Location])
], VgDemo);
return VgDemo;
}());