From 1e76f3cfe42a4fb2178318f9c29c5e7952a8be28 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Mon, 17 Mar 2014 01:23:13 -0400 Subject: [PATCH] change user flyout to panel --- dashboard-ui/scripts/site.js | 35 +++++++++++++++-------------------- 1 file changed, 15 insertions(+), 20 deletions(-) diff --git a/dashboard-ui/scripts/site.js b/dashboard-ui/scripts/site.js index 03818daba0..d0d81f627a 100644 --- a/dashboard-ui/scripts/site.js +++ b/dashboard-ui/scripts/site.js @@ -463,40 +463,35 @@ var Dashboard = { Dashboard.getCurrentUser().done(function (user) { - var html = '
'; + var html = '
'; - html += 'Close'; + html += '

'; - html += '
'; - html += '

' + user.Name + '

'; - html += '
'; + if (user.PrimaryImageTag) { + var imageUrl = ApiClient.getUserImageUrl(user.Id, { - html += '
'; + width: 60, + tag: user.PrimaryImageTag, + type: "Primary" - html += '

'; + }); - var imageUrl = user.PrimaryImageTag ? ApiClient.getUserImageUrl(user.Id, { + html += ''; + } - height: 400, - tag: user.PrimaryImageTag, - type: "Primary" + html += user.Name; + html += '

'; - }) : "css/images/userflyoutdefault.png"; - - html += ''; - html += '

'; - - html += '

View Profile'; + html += '

Preferences'; html += '

'; - html += '
'; html += '
'; $(document.body).append(html); - $('#userFlyout').popup({ positionTo: context }).trigger('create').popup("open").on("popupafterclose", function () { + $('#userFlyout').panel({}).trigger('create').panel("open").on("panelafterclose", function () { - $(this).off("popupafterclose").remove(); + $(this).off("panelafterclose").remove(); }); }); },