Skip to content

Commit

Permalink
Updates fix #359. Change treatment to primary button
Browse files Browse the repository at this point in the history
  • Loading branch information
profmikegreene committed Mar 25, 2022
1 parent 1bc3793 commit b726886
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 17 deletions.
17 changes: 11 additions & 6 deletions library/src/morpheus-master/js/duke-lib.js
Original file line number Diff line number Diff line change
Expand Up @@ -255,17 +255,22 @@ if (document.querySelector(".Mrphs-headerLogo--institution")) {
///////////////////////////////////////////////////
// #359 Add Conversations survey to tool
///////////////////////////////////////////////////

function dukeAddConversationsSurvey(){
// await document.hasOwnProperty('sakai');
if ( 'conversations' in window.sakai.translations ) {
const surveyContainer = document.createElement("div");
surveyContainer.id = "duke-conversations-survey";
const classes = ["duke-conversations-survey", "sak-banner-success-inline"];
const classes = ["duke-conversations-survey"];
surveyContainer.classList.add(...classes);
surveyContainer.innerHTML = `<a href="https://duke.qualtrics.com/jfe/form/SV_064tXBcRDJv3T7w">Share your experience with Conversations!</a>`;
let placement = document.querySelector(".Mrphs-sakai-conversations .Mrphs-toolTitleNav");
placement.prepend(surveyContainer);
surveyContainer.innerHTML = `<a target="_blank" title="Complete this survey to share your experience with Conversations." href="https://duke.qualtrics.com/jfe/form/SV_064tXBcRDJv3T7w">Share your Conversations experience with us!<span class="fa fa-external-link"></span></a>`;
let placement = document.querySelector(".Mrphs-siteHierarchy");
placement.append(surveyContainer);
placement.style.flexDirection = "row";
placement.style.alignItems = "center";
document.querySelector(".Mrphs-hierarchy--sites").style.maxWidth = "70%";
let placementLink = document.querySelector(".Mrphs-hierarchy--sites a");
placementLink.style.textOverflow = "ellipsis";
placementLink.style.overflow = "hidden";
placementLink.style.whiteSpace = "nowrap";
}
}

Expand Down
26 changes: 15 additions & 11 deletions library/src/morpheus-master/sass/_duke-all-overrides.scss
Original file line number Diff line number Diff line change
Expand Up @@ -1557,16 +1557,20 @@ div.progress-stat {

// duke-359 Conversations survey banner
#duke-conversations-survey {
padding: 8px 8px 8px 50px;
@media only screen and (min-width: 800px) {

margin-top:-48px;
}
}
.Mrphs-sakai-conversations .Mrphs-toolTitleNav {
justify-content: flex-end;
align-content: center;
align-items: center;
flex-direction: row;
flex-wrap: nowrap;
a {
@include sakai_primary_button();
display: block;
text-overflow: ellipsis;
overflow: hidden;
white-space: nowrap;

.fa {
margin-left: 8px;
}
}

@media only screen and (max-width: 640px) {
min-width: 27%;
}
}

0 comments on commit b726886

Please sign in to comment.