Skip to content

Commit

Permalink
Reworked landing page to emphasize editor / dashboard.
Browse files Browse the repository at this point in the history
  • Loading branch information
Lomilar committed Apr 22, 2019
1 parent 0928c3e commit 9dfc106
Show file tree
Hide file tree
Showing 7 changed files with 193 additions and 28 deletions.
66 changes: 66 additions & 0 deletions src/main/webapp/cass-ui-concept-editor-ctr.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
<!doctype html>
<html class="no-js" lang="en" dir="ltr">

<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>CaSS Concept Editor</title>
<link rel="stylesheet" href="css/jquery-ui.min.css">
<link rel="stylesheet" href="css/foundation.min.css">
<link rel="stylesheet" href="css/font-awesome.min.css">
<link rel="stylesheet" href="css/cass-ui.css">
</head>

<body>
<div>
<!-- MAIN MENU -->
<div class="sticky" data-sticky data-margin-top="0">
<div id="main-menu">
<div class="grid-container full">
<!-- Mobile menu -->
<div class="title-bar" data-responsive-toggle="animated-menu" data-hide-for="medium">
<button class="menu-icon" type="button" data-toggle></button>
<div class="title-bar-title">Menu</div>
</div>
<div class="top-bar" id="animated-menu" data-animate="hinge-in-from-top hinge-out-from-top">
<div class="top-bar-left">
<ul class="dropdown menu" data-dropdown-menu>
<li class="menu-text"><a title="CaSS Home" href="cass-ui-home.html"><img src="img/CASS-Logo-website-white_3.png"></a></li>
</ul>
</div>
<div class="top-bar-right">
<ul class="dropdown menu" data-dropdown-menu>
<li><a title="CaSS Explorer Home" onclick="goToCassUiHomePage()"><i class="fa fa-home" aria-hidden="true"></i></a></li>
<li>
<a href="#"><i class="fa fa-user-circle"></i> <span id="cassUiLoggedInName"></span></a>
<ul class="menu vertical">
<li><a onclick="logoutCassUi()">Logout</a></li>
</ul>
</li>
</ul>
</div>
</div>
</div>
</div>
</div>
<!--END MAIN MENU -->

<!--CONTENTS-->
<div class="cassUiIframeContainer">
<iframe id="prfExpIFrame" class="cassUiIframe" style="background-color:white;"></iframe>
</div>
<!--END CONTENTS-->

</div>

<script src="js/vendor/jquery.js"></script>
<script src="js/vendor/foundation.js"></script>
<script src="js/cass/cass.min.js"></script>
<script src="js/util/cass-ui-util.js"></script>
<script src="js/util/cass-ui-session-util.js"></script>
<script src="js/page/cass-ui-concept-editor-ctr.js"></script>

</body>

</html>
2 changes: 1 addition & 1 deletion src/main/webapp/cass-ui-editor-ctr.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>CaSS Editor</title>
<title>CaSS Competency Editor</title>
<link rel="stylesheet" href="css/jquery-ui.min.css">
<link rel="stylesheet" href="css/foundation.min.css">
<link rel="stylesheet" href="css/font-awesome.min.css">
Expand Down
72 changes: 46 additions & 26 deletions src/main/webapp/cass-ui-home.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ <h2> CaSS Profiles</h2>
<div class="welcome-card-body">
<p> Explore a unique and detailed view of an individual</p>
<ul>
<li>Build CaSS Profiles</li>
<li>View CaSS Profiles</li>
<li>Validate Skills Assertions</li>
<li>Analyze Profile</li>
<li>Export and Share</li>
Expand Down Expand Up @@ -145,39 +145,26 @@ <h2> CaSS Gap Analysis</h2>
</div>
</div>

<div id="welcome-more-stuff-wrapper">
<a onclick="goToVLRC()" title="Demonstrate a lightweight CaSS Enabled learning environment with the VLRC">
Virtual Learning Resource Center</a> &bull;
<a onclick="goToEditor()" title="Create, import, and edit frameworks of competencies">
CaSS Editor</a> &bull;
<a onclick="goToDocs()" title="Learn more about how CaSS works">
High Level Documentation</a> &bull;
<a onclick="goToDevdocs()" title="Learn how to build apps or integrate with CaSS">
Technical Documentation</a>
</div>

<!--
<div class="grid-container" style="display: none;">
<div class="grid-container">
<div class="grid-x grid-margin-x grid-margin-y" style="justify-content: center;">

<div id="vlrc-card" onclick="goToVLRC()" class="two-dp-shadow small-12 medium-4 large-4 cell">
<div class="welcome-card-header-wrapper">
<div class="dblq">
<div class="i-wrapper black">
<div class="i-wrapper blue">
<i class="fa fa-book"></i>
</div>
</div>
<div class="dbl3">
<h2> Virtual Learning Resource Center</h2>
<h2> CaSS Dashboard</h2>
</div>
</div>
<div class="welcome-card-body">
<p> Demonstrate a lightweight CaSS Enabled learning environment with the VLRC</p>
<p> Track competence and make assertions about yourself and others.</p>
<ul>
<li>Discover competency aligned resources</li>
<li>View your timeline</li>
<li>Find and align resources to competencies</li>
<li>See view counts and rate resources</li>
<li>Make claims and attach evidence</li>
</ul>
<div class="link-icon-container">
<i class="fa fa-chevron-right card-link-icon"></i>
Expand All @@ -188,29 +175,52 @@ <h2> Virtual Learning Resource Center</h2>
<div id="editor-card" onclick="goToEditor()" class="two-dp-shadow small-12 medium-4 large-4 cell">
<div class="welcome-card-header-wrapper">
<div class="dblq">
<div class="i-wrapper black">
<div class="i-wrapper maroon">
<i class="fa fa-pencil"></i>
</div>
</div>
<div class="dbl3">
<h2> CaSS Editor</h2>
<h2> CaSS Competency Editor</h2>
</div>
</div>
<div class="welcome-card-body">
<p> Create, import, and edit frameworks of competencies</p>
<ul>
<li>Link competencies in frameworks</li>
<li>Get URLs to reference in learning systems</li>
<li>Export frameworks in myriad standards</li>
<li>Export frameworks</li>
</ul>
<div class="link-icon-container">
<i class="fa fa-chevron-right card-link-icon"></i>
</div>
</div>
</div>

<div id="concept-editor-card" onclick="goToConceptEditor()" class="two-dp-shadow small-12 medium-4 large-4 cell">
<div class="welcome-card-header-wrapper">
<div class="dblq">
<div class="i-wrapper teal">
<i class="fa fa-pencil"></i>
</div>
</div>
<div class="dbl3">
<h2> CaSS Concept Editor</h2>
</div>
</div>
<div class="welcome-card-body">
<p> Create, import, and edit schemes of concepts</p>
<ul>
<li>Link concepts in schemes</li>
<li>Get URLs to reference in learning systems</li>
<li>Export concept schemes</li>
</ul>
<div class="link-icon-container">
<i class="fa fa-chevron-right card-link-icon"></i>
</div>
</div>
</div>

<div id="docs-card" onclick="goToDocs()" class="two-dp-shadow small-12 medium-4 large-4 cell">
<div id="docs-card" onclick="goToDocs()" style="display:none;" class="two-dp-shadow small-12 medium-4 large-4 cell">
<div class="welcome-card-header-wrapper">
<div class="dblq">
<div class="i-wrapper black">
Expand All @@ -235,7 +245,7 @@ <h2> CaSS High Level Documentation</h2>
</div>
</div>

<div id="devdocs-card" onclick="goToDevdocs()" class="two-dp-shadow small-12 medium-4 large-4 cell">
<div id="devdocs-card" onclick="goToDevdocs()" style="display:none;" class="two-dp-shadow small-12 medium-4 large-4 cell">
<div class="welcome-card-header-wrapper">
<div class="dblq">
<div class="i-wrapper black">
Expand Down Expand Up @@ -263,7 +273,17 @@ <h2> CaSS Technical Documentation</h2>

</div>
</div>
-->

<div id="welcome-more-stuff-wrapper">
<a onclick="goToVLRC()" style="display:none;" title="Demonstrate a lightweight CaSS Enabled learning environment with the VLRC">
Virtual Learning Resource Center</a> <span style="display:none;">&bull;</span>
<a onclick="goToEditor()" style="display:none;" title="Create, import, and edit frameworks of competencies">
CaSS Editor</a> <span style="display:none;">&bull;</span>
<a onclick="goToDocs()" title="Learn more about how CaSS works">
High Level Documentation</a> &bull;
<a onclick="goToDevdocs()" title="Learn how to build apps or integrate with CaSS">
Technical Documentation</a>
</div>


</div>
Expand Down
3 changes: 3 additions & 0 deletions src/main/webapp/css/cass-ui.css
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,7 @@ canvas {
#framework-card,
#gap-card,
#vlrc-card,
#concept-editor-card,
#editor-card,
#docs-card,
#devdocs-card {
Expand Down Expand Up @@ -467,6 +468,7 @@ li {
#framework-card,
#gap-card,
#vlrc-card,
#concept-editor-card,
#editor-card,
#docs-card,
#devdocs-card {
Expand Down Expand Up @@ -507,6 +509,7 @@ li {
#framework-card,
#gap-card,
#vlrc-card,
#concept-editor-card,
#editor-card,
#docs-card,
#devdocs-card {
Expand Down
71 changes: 71 additions & 0 deletions src/main/webapp/js/page/cass-ui-concept-editor-ctr.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
//**************************************************************************************************
// CASS UI Profile Explorer Functions
//**************************************************************************************************

//**************************************************************************************************
// Constants

const ADD_CEASN_DATA_FIELDS = false;
const CEASN_FIELD_TOGGLE = "ceasnDataFields=true";

const PRF_EXP_IFRAME = "#prfExpIFrame";
const PRF_EXP_IFRAME_SOURCE = "cass-editor/index.html?concepts=true&tlaProfile=true&user=wait&editIframe=true";

const WAITING_MESSAGE = "waiting";
const INIT_FWK_EXP_MESSAGE = "initFrameworkExplorer";

const INIT_IDENTITY_ACTION = "identity";

const CASSUI_FWK_EXP_PAGE = "cass-ui-concept-editor-ctr.html";

//**************************************************************************************************
// Variables

//**************************************************************************************************
// Page Functions
//**************************************************************************************************

function handleInitFrameworkExplorerMessage(frameworkId) {
debugMessage("handleInitFrameworkExplorerMessage storing framework id: " + frameworkId);
storeFrameworkToExploreInfo(frameworkId);
location.replace(CASSUI_FWK_EXP_PAGE);
}

function sendIdentityInitializeMessage() {
$(PRF_EXP_IFRAME)[0].contentWindow.postMessage(JSON.stringify({
action: INIT_IDENTITY_ACTION,
identity: loggedInPpkPem
}), window.location.origin);
}

$(PRF_EXP_IFRAME).ready(function () {
$(window).on("message", function (event) {
if (event.originalEvent.data.message == WAITING_MESSAGE) {
sendIdentityInitializeMessage();
} else if (event.originalEvent.data.message == INIT_FWK_EXP_MESSAGE) {
handleInitFrameworkExplorerMessage(event.originalEvent.data.frameworkId);
}
});
});

function getEditorIframeSourceLink() {
var ifs = PRF_EXP_IFRAME_SOURCE;
if (ADD_CEASN_DATA_FIELDS) ifs += "&" + CEASN_FIELD_TOGGLE;
ifs += "&origin="+ window.location.origin + "&server=" + selectedServer;
debugMessage("Opening cass concept editor iFrame with: " + ifs);
return ifs;
}

function init() {
loadCassUiSessionState();
$(PRF_EXP_IFRAME).attr("src", getEditorIframeSourceLink());
setCassUiMainMenuUserName();
}

//**************************************************************************************************
// Document on ready
//**************************************************************************************************

$(document).ready(function () {
init();
});
5 changes: 5 additions & 0 deletions src/main/webapp/js/page/cass-ui-home.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const CASSUI_PRF_EXP_PAGE = "cass-ui-profile-exp-ctr.html";
const CASSUI_GAP_ANL_PAGE = "cass-ui-gap-analysis-ctr.html";
const CASSUI_VLRC_PAGE = "cass-ui-vlrc-exp-ctr.html";
const CASSUI_EDITOR_PAGE = "cass-ui-editor-ctr.html";
const CASSUI_CONCEPT_EDITOR_PAGE = "cass-ui-concept-editor-ctr.html";

//**************************************************************************************************
// Variables
Expand Down Expand Up @@ -38,6 +39,10 @@ function goToEditor() {
location.replace(CASSUI_EDITOR_PAGE);
}

function goToConceptEditor() {
location.replace(CASSUI_CONCEPT_EDITOR_PAGE);
}

function goToDocs() {
location.assign("https://docs.cassproject.org");
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/webapp/js/page/cass-ui-login.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const CASSUI_LOGIN_PW = "#cassUiLoginPassword";
const CASSUI_LOGIN_NAME = "#cassUiLoginName";
const CASSUI_LOGIN_EMAIL = "#cassUiLoginEmail";
const CASSUI_LOGIN_BTN = "#cassUiLoginBtn";
const CASSUI_LOGIN_BTN = "#cassUiCreateBtn";
const CASSUI_CREATE_BTN = "#cassUiCreateBtn";
const CASSUI_LOGIN_BUSY_CTR = "#cassUiLoginBusyCtr";
const CASSUI_LOGIN_ERR_CTR = "#cassUiLoginErrorCtr";
const CASSUI_LOGIN_ERR_TXT = "#cassUiLoginErrorText";
Expand Down

0 comments on commit 9dfc106

Please sign in to comment.