Downloaded WoodMac Learn templates for the first time. Added some tasks for WML. Re-downloaded SPS to reference some code. SPS's app says all templates were last uploaded in April 18 2025. Last local changes (my hunch is downloaded) on my machine is May 13, 2025.

This commit is contained in:
Norm Rasmussen
2025-07-07 09:42:08 -04:00
parent 85ffb9a4f3
commit 1980bd456d
254 changed files with 8454 additions and 0 deletions

View File

@ -0,0 +1,66 @@
<div class="np-hidden-mobile">
<p>{% t .description %}</p>
<p>{% t .requirements %}</p>
</div>
<img
alt=""
class="np-account-avatar-image"
src="{{ form.gravatar_url }}?s=200"
id="{{version}}_gravatar_img"
{% unless form.use_gravatar? %}style="display: none"{% endunless %}
/>
<img
alt=""
class="np-account-avatar-image"
src="{{ form.secure_custom_avatar_url }}"
id="{{version}}_custom_avatar_img"
{% if form.use_gravatar? %}style="display: none"{% endif %}
/>
<div class="np-account-avatar-choice">
<div class="np-form-field">
<label class="radio radio-before np-input-label" for="{{version}}_learner_use_gravatar_true">
<span class="radio__input">
<input
id="{{version}}_learner_use_gravatar_true"
name="learner[use_gravatar]"
type="radio"
value="true"
{% if form.use_gravatar? %}checked{% endif %}
/>
<span class="np-button-color radio__control"></span>
</span>
<span class="radio__label">
{% t .use_gravatar %}
</span>
</label>
</div>
<div class="np-form-field">
<label class="radio radio-before np-input-label" for="{{version}}_learner_use_gravatar_false">
<span class="radio__input">
<input
id="{{version}}_learner_use_gravatar_false"
name="learner[use_gravatar]"
type="radio"
value="false"
{% unless form.use_gravatar? %}checked{% endunless %}
/>
<span class="np-button-color radio__control"></span>
</span>
<span class="radio__label">
{% t .upload_custom_photo %}
</span>
</label>
</div>
<div>
<button
id="{{version}}_upload_avatar"
type="button"
class="np-button np-button-secondary" {% if form.use_gravatar? %}style="visibility: hidden"{% endif %}
>
{% t .upload %}
</button>
</div>
</div>

View File

@ -0,0 +1,19 @@
<form class="np-form" action="{{ form.options.action }}" method="post" id="desktop_edit_learner" novalidate>
<input type="hidden" name="_method" value="{{ form.options.http_method }}">
{% form_authenticity_token %}
<div class="np-card">
<div class="np-card-container np-card-padding">
<div class="row">
<div class="col-sm-7 np-account-form">
{% render "account_form", form: form, version: "desktop" %}
<button type="submit" class="np-button np-button-big np-button-large-font np-form-action">
{% t shared.account.save %}
</button>
</div>
<div class="col-sm-5 np-account-avatar">
{% include "account_avatar", version: "desktop" %}
</div>
</div>
</div>
</div>
</form>

View File

@ -0,0 +1,139 @@
<div class="np-resource-title">
{% t .header %}
</div>
<div class="np-form-field {% if form.errors contains 'email' %}np-account-form-field-error{% endif %}">
<label class="np-input-label" for="{{version}}_learner_email">{% t shared.email %} *</label>
<input
{% if form.options.invite? %} disabled {% endif %}
autofocus="autofocus"
class="np-input"
id="{{version}}_learner_email"
name="learner[email]"
type="email"
value="{{ form.email }}"
/>
</div>
<div class="np-form-field {% if form.errors contains 'first_name' %}np-account-form-field-error{% endif %}">
<label class="np-input-label" for="{{version}}_learner_first_name">
{% t shared.first_name %} *
</label>
<input
class="np-input"
id="{{version}}_learner_first_name"
name="learner[first_name]"
value="{{ form.first_name }}"
/>
</div>
<div class="np-form-field {% if form.errors contains 'last_name' %}np-account-form-field-error{% endif %}">
<label class="np-input-label" for="{{version}}_learner_last_name">
{% t shared.last_name %} *
</label>
<input
class="np-input"
id="{{version}}_learner_last_name"
name="learner[last_name]"
value="{{ form.last_name }}"
/>
</div>
<div class="np-form-field {% if form.errors contains 'display_name' %}np-account-form-field-error{% endif %}">
<label class="np-input-label" for="{{version}}_learner_display_name">
{% t .display_name %}
</label>
<input
class="np-input"
id="{{version}}_learner_display_name"
name="learner[display_name]"
value="{{ form.display_name }}"
/>
</div>
{% unless form.options.invite? %}
<div class="np-form-field {% if form.errors contains 'current_password' %}np-account-form-field-error{% endif %}">
<label class="np-input-label" for="{{version}}_learner_current_password">
{% t .current_password %} *
</label>
<input
class="np-input"
id="{{version}}_learner_current_password"
name="learner[current_password]"
type="password"
/>
</div>
<div class="np-form-field {% if form.errors contains 'password' %}np-account-form-field-error{% endif %}">
<label class="np-input-label" for="{{version}}_learner_password">
{% t .new_password %} *
</label>
<input
class="np-input"
id="{{version}}_learner_password"
name="learner[password]"
type="password"
/>
</div>
<div class="np-form-field {% if form.errors contains 'password_confirmation' %}np-account-form-field-error{% endif %}">
<label class="np-input-label" for="{{version}}_learner_password_confirmation">
{% t .confirm_new_password %} *
</label>
<input
class="np-input"
id="{{version}}_learner_password_confirmation"
name="learner[password_confirmation]"
type="password"
/>
</div>
{% endunless %}
{% if form.options.invite? %}
<div class="np-form-field {% if form.errors contains 'password' %}np-account-form-field-error{% endif %}">
<label class="np-input-label" for="{{version}}_learner_password">
{% t shared.password %} *
</label>
<input
class="np-input"
id="{{version}}_learner_password"
name="learner[password]"
type="password"
/>
</div>
{% if form.terms_of_service_required? %}
<div class="np-form-field terms-of-service {% if form.errors contains 'terms_of_service_accepted' %}np-account-form-field-error{% endif %}">
<input
id="{{version}}_learner_terms_of_service"
name="learner[terms_of_service_accepted]"
type="checkbox"
/>
<div class="label">
{% t .terms_of_service %}
<a
target="_blank"
href={{ form.terms_of_service_url }}
>
{% t .terms_link %}
</a>
</div>
</div>
{% else %}
<div class="np-margin-top">
<span class="np-form-terms ">
{% t .terms %}
<a
class="np-form-link np-button-color"
target="_blank"
href={{ form.terms_of_service_url }}
>
{% t .terms_link %}
</a>
</span>
</div>
{% endif %}
<input
id="{{version}}_invite_token"
name="learner[token]"
value="{{ form.invite_token }}"
type="hidden"
/>
{% endif %}

View File

@ -0,0 +1,17 @@
<form class="np-form" action="{{ form.options.action }}" method="post" id="mobile_edit_learner" novalidate>
<input type="hidden" name="_method" value="{{ form.options.http_method }}">
{% form_authenticity_token %}
<div class="np-card np-account-form">
<div class="np-card-container np-card-padding">
{% render "account_form", form: form, version: "mobile" %}
</div>
</div>
<div class="np-card np-account-avatar">
<div class="np-card-container np-card-padding">
{% include "account_avatar", version: "mobile" %}
</div>
</div>
<button type="submit" class="np-button np-button-big np-button-large-font np-form-action">
{% t shared.account.save %}
</button>
</form>

View File

@ -0,0 +1,23 @@
{% capture settings_path %}{% route account %}{% endcapture %}
{% capture transcript_path %}{% route transcript %}{% endcapture %}
{% if current_person.signed_in? %}
{% unless current_school.sso_active? %}
<nav class="np-tabs np-account-tabs">
<div class="np-tabs-content">
<div class="np-tab{% if page.path == settings_path %} np-tab-active{% endif %}">
<a class="np-tab-link" href="{{ settings_path}}">
{% t .profile_settings %}
</a>
<div class="np-tab-indicator np-button-background-color"></div>
</div>
<div class="np-tab{% if page.path == transcript_path %} np-tab-active{% endif %}">
<a class="np-tab-link" href="{{ transcript_path }}">
{% t .transcript %}
</a>
<div class="np-tab-indicator np-button-background-color"></div>
</div>
</div>
</nav>
{% endunless %}
{% endif %}

View File

@ -0,0 +1,72 @@
<div class="np-card" categories="{% for category in course.categories %}{{category.name}}${% endfor %}">
<div class="np-card-container">
{% if course.ribbon %}
<div class="np-card-ribbon">
{{ course.ribbon }}
</div>
{% endif %}
<img
class="np-card-image"
alt="{{ course.name }}"
src="{{ course.image_url }}"
>
{% if course.properties.duration %}
<div class="np-duration-overlay">
<strong>{{ course.properties.duration }}</strong> mins
<div></div>
</div>
{% endif %}
<div class="np-card-content np-card-content-vertical np-card-padding">
<div class="np-duration">
{{ course.activities_count }} Activities
</div>
<h3 class="np-card-content-title">
{{ course.name }}
</h3>
<div class="np-card-content-subtitle">
{{ course.instructor_names }}
</div>
<div class="np-card-content-footer">
<div class="np-card-content-progress np-button-color">
{{course.progress}}%
{% if course.progress == 100 %}
Complete
{% elsif course.progress == 0 %}
Not started
{% else %}
In progress
{% endif %}
</div>
{% capture course_path %}{% route course, id: course.id %}{% endcapture %}
{% if course.has_to_restart? %}
{% include "course_version_outdated_popup", path: course_path %}
{% endif %}
<a class="np-button np-button-wide" href="{{ course_path }}">
{% t shared.view %}
</a>
</div>
</div>
</div>
</div>
<style>
.np-duration{
font-weight: 600;
}
.np-duration-overlay{
position: absolute;
top: 10px;
left: 10px;
color: #fff;
padding: 5px 10px;
border-radius: 5px;
font-size: 15px;
font-weight: 600;
background-color: #010063;
}
.np-duration-label{
font-size: 15px;
}
</style>

View File

@ -0,0 +1,120 @@
<div class="card-feature">
<div class="card-feature-image-container">
<img class="card-feature-image" src="{{ course.image_url }}" alt="{{ course.name }}">
{% if course.properties.duration %}
<div class="np-duration-overlay">
<strong>{{ course.properties.duration }}</strong> mins
<div></div>
</div>
{% endif %}
{% if course.activities_count %}
<div class="np-activities-overlay">
<strong>{{ course.activities_count }}</strong> activities
</div>
{% endif %}
</div>
<div class="card-feature-content-container">
<div class="card-feature-heading">
{{ course.name }}
</div>
<div class="card-feature-desc">
{{course.full_description}}
</div>
<div class="card-feature-btn-container">
{% capture course_path %}{% route course, id: course.id %}{% endcapture %}
<a href="{{ course_path }}" class="card-feature-btn">Start
<i class="fas fa-arrow-right"></i>
</a>
</div>
</div>
</div>
<style>
.card-feature {
display: flex;
background: #fff;
width: 100%;
margin-bottom: 20px;
}
.card-feature-image {
width: 100%;
}
.card-feature-content-container {
padding: 20px;
width: 100%;
}
.card-feature-content-container {
padding: 20px;
width: 100%;
display: flex;
flex-direction: column;
justify-content: space-between;
}
.card-feature-btn {
text-decoration: none;
color: #01005F;
background: #B0EB9F;
padding: 10px 20px;
font-family: "arial", "marope";
}
.card-feature-btn-container {
display: flex;
justify-content: end;
}
.card-feature-desc{
margin-bottom: 135px;
font-family: "arial", "marope";
color: #1E1E1E;
}
.card-feature-heading{
color: #010063;
font-family: "arial", "marope";
font-weight: bold;
font-size: 1.5rem;
}
.card-feature-btn i {
font-weight: normal;
}
.card-feature-image-container{
position: relative;
width: 100%;
}
.np-duration-overlay{
position: absolute;
top: 10px;
left: 10px;
color: #fff;
padding: 5px 10px;
border-radius: 5px;
font-size: 20px;
font-weight: 600;
background-color: #010063;
}
.np-activities-overlay{
position: absolute;
color: #fff;
padding: 5px 10px;
border-radius: 5px;
font-size: 20px;
font-weight: 600;
right: 20px;
top: 14px;
background-color: #010063;
}
@media (max-width: 768px) {
.card-feature {
flex-direction: column;
}
}
</style>

View File

@ -0,0 +1,76 @@
<div class="np-card np-no-horizontal-padding learning-path-card" categories="{% for category in learning_path.categories %}{{category.name}},{% endfor %}">
<div class="np-card-container">
<div class="np-learning-path">
<img
alt="{{ learning_path.name }}"
class="np-card-image np-learning-path-image"
src="{{ learning_path.image_url }}"
/>
<div class="np-card-text-wrapper">
<div class="np-hidden-desktop np-card-header">
<div class="np-card-header-type">{% t shared.learning_path.title %}</div>
<div class="np-hidden-desktop np-card-header-items-count">
{{ learning_path.items.count }} {% t .items %}
</div>
</div>
<div class="np-hidden-mobile np-card-header">
<div class="np-card-header-type">Learning path</div>
</div>
<div class="np-card-content np-card-padding np-card-content-vertical">
<h3 class="np-card-content-title">
{{ learning_path.name }}
</h3>
<div class="np-card-content-subtitle">
Instructors:
{{ learning_path.instructor_names }}
</div>
<div class="np-hidden-mobile np-card-content-description lp-desc">
{{ learning_path.description }}
</div>
<div class="np-hidden-mobile np-card-content-progress
np-button-color">
{% t shared.progress, count: learning_path.progress %}
</div>
<div class="np-hidden-mobile np-card-progress-bar-container">
<div
style="width: {{ learning_path.progress }}%"
class="np-button-background-color np-card-progress-bar">
</div>
</div>
<div class="np-card-content-footer">
<div class="np-hidden-desktop np-card-content-progress
np-button-color">
{% t shared.progress, count: learning_path.progress %}
</div>
<a class="np-button" href="{% route learning_path, id: learning_path.id %}">
{% t shared.view %}
</a>
<span class="np-hidden-mobile np-learning-path-items">
<img src="" alt="">
<span class="np-learning-path-items-count">
{{ learning_path.items.count }} {% t .items %}
</span>
</span>
</div>
</div>
</div>
</div>
</div>
</div>
<style>
.np-resource-title{
color: #010063;
}
.np-resource-subtitle{
color: #01005F;
font-size: 23px;
}
</style>

View File

@ -0,0 +1,111 @@
<div class="np-card np-card-training-event">
<div class="np-card-container">
<div class="np-card-content-training-event">
<h3 class="np-card-content-title">
{{ training_event.title }}
</h3>
<div class="np-card-content-subtitle">
<i class="far {{ training_event.event_type_icon }} np-training-session-icon"></i>
<span class="event-type">{% t shared.event_types, key: training_event.event_type %}</span>
<span class="np-card-training-sessions-separator">•</span>
<i class="np-card-training-sessions-icon far fa-calendar-star"></i>
<span class="np-card-training-sessions-label">
{% t .sessions, count: training_event.sessions.size %}
</span>
</div>
<div class="np-card-training-session">
<div class="np-card-training-session-date">
<div class="np-button-background-color np-card-training-session-date-bar"></div>
<div class="np-card-training-session-date-label">
<div class="np-card-training-session-date-day">
{{ training_event.sessions.first.day }}
</div>
<div>
<div class="np-card-training-session-date-month">
{{ training_event.sessions.first.month }}
</div>
<div class="np-card-training-session-date-year">
{{ training_event.sessions.first.year }}
</div>
</div>
</div>
<div class="training-session-time-container">
<i class="fal fa-clock np-button-color np-training-session-icon"></i>
<div class="time-container">
<time>{{ training_event.sessions.first.time_period }}</time>
<div class="zone">{{ training_event.sessions.first.time_zone }}</div>
</div>
</div>
</div>
</div>
</div>
<div class="np-card-content np-card-content-vertical np-card-content-training-event">
<div class="card-training-sessions-bts-container">
{% if training_event.event_type == 'in_person' %}
<div class="event-btn-container">
<a
class="event-btn"
href="{% route training_session, id: training_event.sessions.first.id %}"
>
View event details
</a>
</div>
<div class="event-btn-container">
<form
action="{{ training_event.sessions.first.cta.url }}"
method="post"
>
{% form_authenticity_token %}
{% if training_event.sessions.first.cta.undo? %}
<input type="hidden" name="_method" value="delete" />
{% endif %}
{% if training_event.sessions.first.cta.label %}
<button
type="submit"
class="
event-btn register-btn
"
>
{{ training_event.sessions.first.cta.label }}
</button>
{% endif %}
</form>
</div>
{% else %}
<div class="event-btn-container">
<a
class="event-btn"
href="{{training_event.sessions.first.session_url}}"
target="_blank"
>
View event details
</a>
</div>
<div class="event-btn-container">
<form
action="{{ training_event.sessions.first.cta.url }}"
method="post"
>
{% form_authenticity_token %}
{% if training_event.sessions.first.cta.undo? %}
<input type="hidden" name="_method" value="delete" />
{% endif %}
{% if training_event.sessions.first.cta.label %}
<button
type="submit"
class="
event-btn register-btn
"
>
{{ training_event.sessions.first.cta.label }}
</button>
{% endif %}
</form>
</div>
{% endif %}
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,114 @@
{% assign available_categories = '' %}
{% for course in courses.in_catalog %}
{% for category in course.categories %}
{% unless available_categories contains category.name %}
{% assign available_categories = available_categories | append: category.name | append: '$' %}
{% endunless %}
{% endfor %}
{% endfor %}
{% assign cats = available_categories | split: '$' %}
<div class="category-courses-wrapper">
{% for category in cats %}
<div class="catalog-category-wrapper" id="{{category}}">
<div class="category-heading" onclick="toggleDropdown(this)" data-expanded="false"">
{{category}} <span class="dropdown-arrow">â–Ľ</span>
</div>
<div class="category-courses course-items-container">
{% for course in courses.in_catalog %}
{% for cat in course.categories %}
{% if cat.name == category %}
<div class="category-cards-wrapper course-item-wrapper">
{% include 'cards_course' %}
</div>
{% endif %}
{% endfor %}
{% endfor %}
</div>
</div>
{% endfor %}
</div>
<style>
.category-courses {
display: grid;
grid-template-columns: repeat(3,1fr);
gap: 20px;
}
.category-cards-wrapper {
display: flex;
}
.category-heading {
background-color: #0A23F5;
margin-bottom: 15px;
width: 100%;
cursor: pointer;
display: flex;
align-items: center;
justify-content: space-between;
color: #fff;
font-size: 1.5rem;
}
.catalog-category-wrapper {
margin: 40px 0;
}
@media (max-width: 768px) {
.category-courses{
display: flex;
flex-direction: column;
}
.np-resource-title{
font-size: 1.75rem;
}
.np-resource-subtitle{
font-size: 1.2rem;
width: 100%;
}
}
</style>
<script>
function sortAlphabetically() {
const categories = Array.from(document.querySelectorAll(".catalog-category-wrapper"));
categories.sort((a, b) => a.id.localeCompare(b.id));
const parent = categories[0].parentNode;
categories.forEach(category => parent.appendChild(category));
}
document.addEventListener("DOMContentLoaded", function() {
sortAlphabetically();
function setCourseItemsVisibility(container) {
const items = container.querySelectorAll(".course-item-wrapper");
const isExpanded = container.previousElementSibling.getAttribute("data-expanded") === "true";
items.forEach((item, index) => {
item.style.display = (index < 3 || isExpanded) ? "block" : "none";
});
}
window.toggleDropdown = function(element) {
const container = element.nextElementSibling;
if (container && container.classList.contains("course-items-container")) {
const isExpanded = element.getAttribute("data-expanded") === "true";
element.setAttribute("data-expanded", !isExpanded);
setCourseItemsVisibility(container);
element.querySelector(".dropdown-arrow").textContent = isExpanded ? "â–Ľ" : "â–˛";
}
};
document.querySelectorAll(".course-items-container").forEach(container => {
setCourseItemsVisibility(container);
});
});
</script>

View File

@ -0,0 +1,4 @@
<div class="col-xs-12 col-md-4 spacing-clear">
{% include "certificates_verification" %}
{% include "certificates_metadata" %}
</div>

View File

@ -0,0 +1,59 @@
<div class="np-card spacing-clear">
<div class="np-card-container padding-spacing-8">
<div class="row np-certificate-metadata-row">
<div class="col-xs-6 col-md-6">
<p class="np-certificate-metadata-title" >
{% t .learner %}
</p>
</div>
<div class="col-xs-6 col-md-6">
<p class="np-certificate-metadata-value">
{{certificate.learner_name}}
</p>
</div>
</div>
<div class="line"></div>
{% if certificate.issuer_name_enabled? %}
<div class="row np-certificate-metadata-row">
<div class="col-xs-6 col-md-6">
<p class="np-certificate-metadata-title">
{% t .issued_by %}
</p>
</div>
<div class="col-xs-6 col-md-6">
<p class="np-certificate-metadata-value">
{{ certificate.issuer_name }}
</p>
</div>
</div>
<div class="line"></div>
{% endif %}
<div class="row np-certificate-metadata-row">
<div class="col-xs-6 col-md-6">
<p class="np-certificate-metadata-title" >
{% t .issued_on %}
</p>
</div>
<div class="col-xs-6 col-md-6">
<p class="np-certificate-metadata-value">
{{ certificate.issue_date }}
</p>
</div>
</div>
<div class="line"></div>
<div class="row np-certificate-metadata-row">
<div class="col-xs-6 col-md-6">
<p class="np-certificate-metadata-title" >
{% t .expires_on %}
</p>
</div>
<div class="col-xs-6 col-md-6">
<p class="np-certificate-metadata-value">
{{ certificate.expiration_date_translation }}
</p>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,35 @@
<script type="text/javascript">
const resizeIframe = () => {
const combinedPadding = 16;
const previewIframe = document.getElementById("previewIframe");
const previewIFrameCard = document.getElementById("previewIFrameCard");
const templateInPreviewContainer = previewIframe.contentWindow.document.querySelector('.np-certificate-container');
const previewIframeContentHeight = templateInPreviewContainer.offsetHeight;
const previewIframeContentWidth = templateInPreviewContainer.offsetWidth;
const certificateRatio = previewIframeContentHeight / previewIframeContentWidth;
templateInPreviewContainer.style.margin = 0;
previewIFrameCard.style.height = `${previewIFrameCard.offsetWidth * certificateRatio}px`;
const scaledIframeWidth = previewIFrameCard.offsetWidth - combinedPadding;
const scaledIframeHeight = scaledIframeWidth * certificateRatio;
const scale = scaledIframeHeight / previewIframeContentHeight;
previewIframe.style.transform = `scale(${scale})`;
}
window.onresize = resizeIframe;
</script>
<div class="col-xs-12 col-md-8 np-certificate-iframe-container">
<div class="np-card spacing-clear">
<div id="previewIFrameCard" class="np-card-container np-certificate-card">
<iframe
id="previewIframe"
onload="resizeIframe()"
class="np-certificate-iframe-preview"
srcdoc="{{ certificate.certificate_template_html }}"
></iframe>
</div>
</div>
</div>

View File

@ -0,0 +1,44 @@
<div class="top-bar np-certificate-top-bar-spacing">
<div class="top-bar__container uk-container uk-container-center uk-padding-horizontal np-max-width">
<div class="top-bar__col">
<h2 class="np-certificate-title" >
{{certificate.certificate_name}}
</h2>
</div>
<div class="button-container np-certificate-button-container">
{% if certificate.linkedin_sharing_enabled and current_person.signed_in? and certificate.learner_uuid == current_person.id %}
<a
class="np-button np-certificate-button np-certificate-button-secondary"
href="{{certificate.linkedin_share_url}}"
target="_blank"
>
<i class="fab fa-linkedin np-certificate-share-icon"></i>
{% t .share %}
</a>
{% endif %}
<button
id="print"
type="button"
class="np-button np-certificate-button np-certificate-button-secondary np-certificate-button-print"
>
{% t .print %}
</button>
{% if certificate.generating_pdf %}
<div class="np-button np-certificate-button np-certificate-button-primary np-certificate-spinner-container">
<i class="loader fad fa-spinner-third fa-spin np-certificate-spinner-icon np-button-font-color"></i>
</div>
{% else %}
<a
href="{{ certificate.download_url }}"
aria-label="{% t .download %}"
target="_blank"
rel="noopener noreferrer"
download
class="np-button np-certificate-button np-certificate-button-primary np-button-font-color"
>
{% t .download %}
</a>
{% endif %}
</div>
</div>
</div>

View File

@ -0,0 +1,15 @@
<div class="np-card spacing-clear np-certificate-verification-card">
<div class="np-card-container np-certificate-verification-container">
<div class="np-certificate-verification-icon-container np-certificate-verification-icon-container-{{certificate.verification_status}}">
<i class="far fa-{{certificate.verification_icon}} np-certificate-verification-icon"></i>
</div>
<div class="np-certificate-verification-info-container">
<h2 class="np-certificate-verification-info-status spacing-clear">
{{certificate.verification_title}}
</h2>
<p class="np-certificate-verification-info-description spacing-clear">
{{certificate.verification_description}}
</p>
</div>
</div>
</div>

View File

@ -0,0 +1,4 @@
<i class="far fa-lock-alt np-course-outline-content-activity-icon-locked"></i>
<span class="np-course-outline-content-activity-title">
{{ activity.title }}
</span>

View File

@ -0,0 +1,15 @@
{% if course.enrolled? %}
<a
href="{% route activity_viewer,
id: activity.id,
course_id: params.course_id,
learning_path_id: params.learning_path_id
%}" class="{{ class }}"
>
{{ activity.title }}
</a>
{% else%}
<span class="{{ class }}">
{{ activity.title }}
</span>
{% endif %}

View File

@ -0,0 +1,10 @@
<h3 class="np-card-heading">
Course categories
</h3>
<div class="np-flex">
{% for category in course.categories %}
<div class="np-content-categories-content-item">
{{ category.name }}
</div>
{% endfor %}
</div>

View File

@ -0,0 +1,6 @@
<h3 class="np-card-heading">
About the course
</h3>
<div class="np-card-text">
{{ course.full_description }}
</div>

View File

@ -0,0 +1,42 @@
<div class="np-card-container">
<div class="np-resource-header np-course-header np-card-padding-large">
{% include "course_header" %}
</div>
<div class="np-divider"></div>
<div class="row np-course-content np-card-padding-dynamic">
<div class="col-xs-12 col-sm-6">
<img
src="{{ course.image_url }}"
class="np-top-image np-top-image-spacing"
alt="{{ course.name }}"
/>
{% include "course_description" %}
<div class="course-time-container">
<h3 class="np-card-heading">{{course.properties.duration}} min</h3>
</div>
{% if course.categories.any? %}
<div class="np-card-content-divider">
{% include "course_categories" %}
</div>
{% endif %}
{% if course.instructors.any? %}
<div class="np-card-content-divider">
{% include "course_instructors" %}
</div>
{% endif %}
{% if course.events.any? %}
<div class="np-card-content-divider">
{% include "course_events" %}
</div>
{% endif %}
</div>
<div class="np-grid-spacing col-xs-12 col-sm-6">
<div class="np-top-cta">
{% include "course_progress_and_cta" %}
</div>
{% include "course_outline" %}
</div>
</div>
</div>

View File

@ -0,0 +1,28 @@
<h3 class="np-card-heading">
{% t .header %}
</h3>
<div class="np-flex-column">
{% for event in course.events %}
<div class="np-course-events-content-item">
<div class="np-course-events-content-date np-button-background-color">
<div class="np-course-events-content-month">
{{ event.sessions.first.abbreviated_month }}
</div>
<div class="np-course-events-content-day">
{{ event.sessions.first.day }}
</div>
</div>
<div class="np-course-events-content-details">
<div class="np-course-events-content-name">
{{ event.title }}
</div>
<div class="np-course-events-content-type np-text-light">
{% t shared.event_types, key: event.event_type %}
</div>
<div class="np-course-events-content-time np-button-color">
{{ event.sessions.first.time_period }} {{ event.sessions.first.time_zone }}
</div>
</div>
</div>
{% endfor %}
</div>

View File

@ -0,0 +1,16 @@
<div class="np-top-vocabulary np-text-title np-text-muted">
Course
<img class="overview-logo" src="https://s3.us-east-1.amazonaws.com/static.northpass.com/Woodmack/Sun-nav+icons/woodmac+icon+2.png" alt="">
</i>
</div>
<div class="np-top-title">
<a href="/app/catalog" class="np-back-button back-button" aria-label="{% t shared.go_back %}">
<i class="far fa-arrow-left np-hidden-mobile np-icon-back"></i>
</a>
{{ course.name }}
</div>
<img
src="{{ course.image_url }}"
class="np-top-image np-hidden-desktop"
alt="{{ course.name }}"
/>

View File

@ -0,0 +1,22 @@
<h3 class="np-card-heading">
Course instructor
</h3>
<div class="np-flex">
{% for instructor in course.instructors %}
<div class="np-content-instructors-content-item">
<img
src="{{ instructor.avatar_url }}"
class="np-content-instructors-content-image"
alt="{{ instructor.name }}"
/>
<div class="np-content-instructors-content-description">
<div class="np-content-instructors-content-name">
{{ instructor.name }}
</div>
<div class="np-content-instructors-content-info np-text-light">
{{ instructor.title }}
</div>
</div>
</div>
{% endfor %}
</div>

View File

@ -0,0 +1,40 @@
<div class="np-card-container np-card-padding-large">
{% include "course_header" %}
<div class="np-top-cta">
{% include "course_progress_and_cta" %}
</div>
</div>
{% if course.progress == 0 %}
<div class="np-card-container np-card-padding np-card-spacing">
{% include "course_description" %}
</div>
<div class="np-card-container np-card-padding np-card-spacing">
{% include "course_outline" %}
</div>
{% else %}
<div class="np-card-container np-card-padding np-card-spacing">
{% include "course_outline" %}
</div>
<div class="np-card-container np-card-padding np-card-spacing">
{% include "course_description" %}
</div>
{% endif %}
{% if course.categories.any? %}
<div class="np-card-container np-card-padding np-card-spacing">
{% include "course_categories" %}
</div>
{% endif %}
{% if course.instructors.any? %}
<div class="np-card-container np-card-padding np-card-spacing">
{% include "course_instructors" %}
</div>
{% endif %}
{% if course.events.any? %}
<div class="np-card-container np-card-padding np-card-spacing">
{% include "course_events" %}
</div>
{% endif %}

View File

@ -0,0 +1,40 @@
<div class="np-course-outline">
<div class="np-text-title np-course-outline-title">
{% t .header, key: current_school.course_vocabulary %}
</div>
<div class="np-course-outline-content">
<ol class="np-course-outline-content-section">
{% for section in course.sections %}
<li class="np-course-outline-content-section-list">
<div class="np-course-outline-content-section-name np-text-title-bold np-text-title-bold">
{{ section.name }}
</div>
<ol class="np-course-outline-content-activity">
{% for activity in section.activities %}
<li class="np-course-outline-content-activity-list">
{% if activity.completed? %}
<i class="fas fa-circle np-course-outline-content-activity-icon np-button-color"></i>
{% if activity.locked? %}
{% include "course_activity_locked" %}
{% else %}
{% include "course_activity_unlocked", class: "np-course-outline-content-activity-link-completed" %}
{% endif %}
<div class="np-button-background-color np-course-outline-content-activity-list-bar"></div>
{% else %}
<i class="far fa-circle np-course-outline-content-activity-icon"></i>
{% if activity.locked? %}
{% include "course_activity_locked" %}
{% else %}
{% include "course_activity_unlocked", class: "np-course-outline-content-activity-link" %}
{% endif %}
<div class="np-course-outline-content-activity-list-bar"></div>
{% endif %}
</li>
{% endfor %}
</ol>
</li>
{% endfor %}
</ol>
</div>
</div>

View File

@ -0,0 +1,53 @@
<div class="np-top-cta-progress-content">
<div class="np-top-cta-progress-title np-text-title">
{% t .header %}
</div>
<div class="np-progress-bar-container">
<div
style="width: {{ course.progress }}%"
class="np-button-background-color np-card-progress-bar">
</div>
</div>
<div class="np-top-cta-progress-text
{% if course.completed? %} np-color-success {% else %} np-button-color {% endif %}
">
{{course.progress}}%
{% if course.progress == 100 %}
Complete
{% elsif course.progress == 0 %}
Not started
{% else %}
In progress
{% endif %}
</div>
</div>
{% if course.learner_can_retake? %}
<form action="{% route course_retake, id: course.id %}" method="POST">
{% form_authenticity_token %}
<button type="submit" class="np-top-button np-button-font-color np-button np-button-big">
{% t .retake, key: current_school.course_vocabulary %}
</button>
</form>
{% else %}
<a
class="np-top-button np-button-font-color np-button np-button-big course-big-btn"
{% if course.enrolled? %}
href="{% route course_viewer, course_id: course.id, learning_path_id: params.learning_path_id %}"
{% else %}
href="{% route course_enrollment, code: course.enrollment_code %}"
{% endif %}
>
{% if course.enrolled? == false %}
{% t shared.enroll %}
{% elsif course.started? == false %}
{% t shared.course.start, key: current_school.course_vocabulary %}
{% elsif course.completed? %}
{% t shared.course.view, key: current_school.course_vocabulary %}
{% else %}
{% t shared.continue %}
{% endif %}
</a>
{% endif %}

View File

@ -0,0 +1,7 @@
{% if courses.include_courses_to_restart? %}
<div role="alert" class="np-alert np-alert-global np-alert-info">
<div class="np-alert-container uk-container uk-container-center">
{% t .content %}
</div>
</div>
{% endif %}

View File

@ -0,0 +1,33 @@
<div class="np-course-version-outdated-popup np-popup">
<div class="np-popup-positioner">
<i
class="np-course-version-outdated-popup-trigger fas fa-exclamation-circle"
data-toggle-class-on-target="np-popup-tooltip--visible"
data-toggle-target-parent=".np-popup-tooltip"
data-toggle-outside
></i>
<div
class="np-popup-tooltip"
role="tooltip"
aria-hidden="true"
>
<header class="np-popup-header">
<i class="np-popup-header-icon fas fa-exclamation-circle"></i>
<h3 class="np-popup-header-title">
{% t .title %}
</h3>
</header>
<div class="np-popup-body">
<h4>{% t .body.header %}</h4>
<p>{% t .body.content %}</p>
<a
class="np-popup-body-button"
href="{{ path }}"
>
{% t .body.button %}
</a>
</div>
<div class="np-popup-tail"></div>
</div>
</div>
</div>

View File

@ -0,0 +1,16 @@
{% if courses.in_catalog.any? %}
<div class="np-catalog-courses row row-with-thumbnails">
{% for course in courses.in_catalog %}
<div class="col-xs-12 col-md-6 col-lg-4 np-stretch-content">
{% include "cards_course" with course %}
</div>
{% endfor %}
</div>
{% else %}
{% capture message %}
{% t shared.zero_state.courses.catalog,
key: current_school.course_vocabulary
%}
{% endcapture %}
{% include "courses_zero_state", message: message %}
{% endif %}

View File

@ -0,0 +1,16 @@
{% if courses.enrolled.any? %}
<div class="row row-with-thumbnails">
{% for course in courses.enrolled %}
<div class="{{ class }}">
{% include "cards_course" with course %}
</div>
{% endfor %}
</div>
{% else %}
{% capture message %}
{% t shared.zero_state.courses.index,
key: current_school.course_vocabulary
%}
{% endcapture %}
{% include "courses_zero_state", message: message %}
{% endif %}

View File

@ -0,0 +1,6 @@
<div class="np-dashboard-resources-container">
<div class="np-zero-state-text">
{{ message }}
</div>
<img class="np-zero-state-courses" alt="{{ message }}" />
</div>

View File

@ -0,0 +1,21 @@
{% assign enrolled_events = 0 %}
{% for training_event in training_events.enrolled %}
{% assign enrolled_events = enrolled_events | plus: 1 %}
{% endfor %}
<div class="np-dashboard-resources-events">
{% if enrolled_events > 0 %}
<section>
<h2>Your Enrolled Training Events</h2>
{% for training_event in training_events.enrolled %}
{% include "cards_training_event" with training_event %}
{% endfor %}
</section>
{% endif %}
<section>
<h2>Upcoming Training Events</h2>
{% for available_event in training_events.available %}
{% include "cards_training_event" with available_event %}
{% endfor %}
</section>
</div>

View File

@ -0,0 +1,10 @@
<input
id={{value}}
name={{ name }}
value={{ value }}
type="checkbox"
{% if selected %} checked="checked" {% endif %}
/>
<label for={{value}}>
{{label}}
</label>

View File

@ -0,0 +1,49 @@
<div class="np-filter">
<div class="dropdown">
<button
class="np-button dropdown-button"
data-toggle-class="is-open"
data-toggle-escape
data-toggle-outside
data-toggle-target-next
type="button"
>
All Courses <i class=" far fa-solid fa-angle-down"></i>
</button>
<div class="dropdown-menu" data-test="modal">
<form method="get">
{%
include "filter_select",
filters: filters,
key: key,
label: label
%}
<button
class="np-button dropdown-button-apply"
data-toggle-trigger-off
type="submit"
>
{% t shared.filters.apply %}
</button>
</form>
</div>
</div>
</div>
<style>
.dropdown-button {
background-color: #ffffff!important;
color: #01005F;
}
.far {
font-weight: 400;
font-size: 20px;
margin-left: 25px;
}
</style>

View File

@ -0,0 +1,22 @@
{% if params.q %}
<input type="hidden" name="q" value="{{ params.q }}">
{% endif %}
<label class="dropdown-label" for="filter[category_uuid][in][]">
{{ label }}
</label>
<select
class="np-filter-select"
multiple
name="filter[{{ key }}][in][]"
>
{% for filter in filters %}
<option
value="{{ filter.value }}"
{% if filter.selected? %} selected="selected" {% endif %}
>
{{ filter.name }}
</option>
{% endfor %}
</select>

View File

@ -0,0 +1,140 @@
{% assign available_categories = '' %}
{% for course in courses.in_catalog %}
{% for category in course.categories %}
{% unless available_categories contains category.name %}
{% assign available_categories = available_categories | append: category.name | append: '$' %}
{% endunless %}
{% endfor %}
{% endfor %}
{% assign cats = available_categories | split: '$' %}
<div class="lp-filter-wrapper">
<div class="filter-container">
<div class="filter" id="filterToggle">Filter</div>
</div>
<div class="filter-content" id="filterContent">
{% for category in cats %}
{% if category != '' %}
<div class="filter-option">
<input class="filter-checkbox" value="{{ category }}" type="checkbox" onchange="filterCourses()">
<label class="filter-name" for="">{{ category }}</label>
</div>
{% endif %}
{% endfor %}
</div>
</div>
<style>
.lp-filter-wrapper {
position: relative;
width: 100%;
color: #000;
border-radius: 4px;
display: flex;
justify-content: end;
margin-bottom: 20px;
}
.filter-checkbox {
width: 20px;
height: 20px;
}
.filter-container {
position: relative;
}
.filter {
background-color: #d9dfe2;
padding: 10px 20px;
cursor: pointer;
width: 100%;
text-align: center;
border-radius: 4px;
color: #305263;
font-size: 14px;
font-weight: 700;;
}
.filter-content {
position: absolute;
top: 100%;
width: 250px;
background-color: #fff;
border: 1px solid #ccc;
border-radius: 4px;
display: none;
flex-direction: column;
gap: 10px;
max-height: 0;
overflow: hidden;
transition: max-height 0.4s ease, width 0.4s ease;
z-index: 111;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
padding: 5px;
margin-top: 5px;
}
.filter-option {
padding: 10px;
display: flex;
align-items: end;
gap: 10px;
}
.filter-active .filter-content {
display: flex;
max-height: 500px;
width: 250px;
}
</style>
<script>
document.getElementById("filterToggle").addEventListener("click", function() {
const filterWrapper = document.querySelector('.lp-filter-wrapper');
filterWrapper.classList.toggle("filter-active");
});
function filterCourses() {
const checkedCategories = Array.from(document.querySelectorAll('.filter-checkbox:checked')).map(checkbox => checkbox.value);
const sections = document.querySelectorAll('.catalog-category-wrapper');
sections.forEach(section => {
const sectionId = section.id;
const isVisible = checkedCategories.some(category => sectionId.includes(category));
section.style.display = isVisible || checkedCategories.length === 0 ? 'block' : 'none';
});
}
</script>
<style>
.course-item {
margin-bottom: 16px;
padding: 12px;
border: 1px solid #ddd;
display: block;
}
.category-cards-wrapper {
display: flex;
}
.category-heading {
background-color: #0A23F5;
padding: 10px;
color: #fff;
font-size: 1.5rem;
margin-bottom: 10px;
}
.category-filter-wrapper {
background: #F5F5F5;
padding: 15px;
border-radius: 8px;
margin-bottom: 20px;
}
.filter-name {
margin-left: 5px;
font-size: 14px;
}
</style>

View File

@ -0,0 +1,111 @@
{% assign available_learning_path_categories = '' %}
{% for learning_path in learning_paths.available %}
{% for category in learning_path.categories %}
{% unless available_learning_path_categories contains category.name %}
{% assign available_learning_path_categories = available_learning_path_categories | append: category.name | append: '$' %}
{% endunless %}
{% endfor %}
{% endfor %}
{% assign learning_path_cats = available_learning_path_categories | split: '$' %}
<div class="lp-filter-wrapper">
<div class="filter-container">
<div class="filter" id="filterToggle">Filter</div>
</div>
<div class="filter-content" id="filterContent">
{% for category in learning_path_cats %}
{% if category != '' %}
<div class="filter-option">
<input class="filter-checkbox" value="{{ category }}" type="checkbox" onchange="filterLearningPaths()">
<label class="filter-name">{{ category }}</label>
</div>
{% endif %}
{% endfor %}
</div>
</div>
<!--
<div class="learning-paths-list"></div>
{% for learning_path in learning_paths.available %}
<div class="learning-path-card" data-categories="{% for category in learning_path.categories %}{{ category.name | downcase }}{% if forloop.last == false %},{% endif %}{% endfor %}">
<p>{{ learning_path.name }}</p>
</div>
{% endfor %}
</div>-->
<style>
.lp-filter-wrapper {
position: relative;
width: 100%;
color: #000;
border-radius: 4px;
display: flex;
justify-content: end;
margin-bottom: 20px;
}
.filter-checkbox {
width: 20px;
height: 20px;
}
.filter-container {
position: relative;
}
.filter {
background-color: #d9dfe2;
padding: 10px 20px;
cursor: pointer;
width: 100%;
text-align: center;
border-radius: 4px;
color: #305263;
font-size: 14px;
font-weight: 700;
}
.filter-content {
position: absolute;
top: 100%;
width: 250px;
background-color: #fff;
border: 1px solid #ccc;
border-radius: 4px;
display: none;
flex-direction: column;
gap: 10px;
max-height: 0;
overflow: hidden;
transition: max-height 0.4s ease, width 0.4s ease;
z-index: 111;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
padding: 5px;
margin-top: 5px;
}
.filter-option {
padding: 10px;
display: flex;
align-items: end;
gap: 10px;
}
.filter-active .filter-content {
display: flex;
max-height: 500px;
width: 250px;
}
</style>
<script>
document.getElementById("filterToggle").addEventListener("click", function() {
const filterWrapper = document.querySelector('.lp-filter-wrapper');
filterWrapper.classList.toggle("filter-active");
});
function filterLearningPaths() {
const checkedCategories = Array.from(document.querySelectorAll('.filter-checkbox:checked')).map(checkbox => checkbox.value.toLowerCase());
const learningPaths = document.querySelectorAll('.learning-path-card');
learningPaths.forEach(path => {
const pathCategories = path.getAttribute('categories').toLowerCase().split(',');
const isVisible = checkedCategories.some(category => pathCategories.includes(category));
path.style.display = isVisible || checkedCategories.length === 0 ? 'block' : 'none';
});
}
</script>

View File

@ -0,0 +1,82 @@
<footer class="np-footer">
<div class="np-footer-top">
{% if website_footer.show_navigation_links? %}
<div class="np-footer-navigation">
<ul class="np-footer-navigation-list">
{% for website_navigation in navigations.footer_navigations %}
<li class="np-footer-navigation-item">
<a
class="np-footer-navigation-link np-button-color"
href="{{ website_navigation.path }}"
{% if website_navigation.external? %} target="_blank" {% endif %}
>
{% if website_navigation.name == "Learning Paths"%}
Learning paths
{% else %}
{{ website_navigation.name }}
{% endif %}
</a>
</li>
{% endfor %}
</ul>
</div>
{% endif %}
{% if current_school.logo_url %}
<h2 class="np-footer-logo">
<a href="{% route home %}">
<img
alt="{{ current_school.name }}"
class="np-footer-logo-image"
src="{{ current_school.logo_url }}"
/>
</a>
</h2>
{% else %}
<div class="np-school-name np-header-font-color">
{{ current_school.name }}
</div>
{% endif %}
</div>
<div class="np-footer-bottom">
<nav class="np-footer-social-links">
{% if website_footer.show_social_media_links? %}
<ul class="np-footer-social-links-list">
{% for social_media_link in website_footer.social_media_links %}
<li class="np-footer-social-links-item">
<a
class="np-footer-social-links-link np-button-color"
href="{{ social_media_link.link }}"
target="_blank" title="{{ social_media_link.name }}"
>
<i class="np-footer-social-links-icon
np-button-color
fab fa-{{ social_media_link.name }}"
></i>
</a>
</li>
{% endfor %}
</ul>
{% endif %}
</nav>
{% if website_footer.show_customer_service_email? and
website_footer.school_customer_service_email
%}
<div class="np-footer-support">
<div class="np-footer-support-item np-footer-support-help">
{% t .need_help %}
</div>
<div class="np-footer-support-item np-footer-support-email">
{% t .email %}
</div>
<a
class="np-footer-support-item np-footer-support-link np-button-color"
href="mailto:{{ website_footer.school_customer_service_email }}"
>
{{ website_footer.school_customer_service_email }}
</a>
</div>
{% endif %}
</div>
</footer>

View File

@ -0,0 +1,82 @@
{% styles default %}
{% styles colors %}
{% styles custom %}
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Manrope:wght@200..800&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap" rel="stylesheet">
<script>
function changeEventRegisterBtnText() {
const buttons = document.querySelectorAll('.register-btn');
buttons.forEach((button) => {
if (button.innerText == "Register") {
button.innerText = 'Add to my dashboard'
} else if (button.innerText == "Unregister") {
button.innerText = 'Remove from my dashboard'
}
})
}
function changeBackBtnUrl() {
const backBtn = document.getElementsByClassName('back-button')[0];
const previousUrl = document.referrer;
let currentUrl = window.location.href;
let newUrl = ''
if (previousUrl.includes('activities')) {
newUrl = '/app/dashboard'
} else if (currentUrl === previousUrl || previousUrl.includes('summary')) {
newUrl = '/app/dashboard'
}
else {
newUrl = previousUrl;
}
if (backBtn) {
backBtn.href = newUrl;
}
}
function limitLpDescription() {
const elements = document.querySelectorAll(".lp-desc");
elements.forEach(element => {
const originalText = element.textContent.trim();
if (originalText.length > 250) {
const shortenedText = originalText.slice(0, 250) + "...";
element.textContent = shortenedText;
}
});
}
function changeTextTransform() {
const eventType = document.querySelectorAll('.event-type');
const startContentBtn = document.querySelector('.lp-big-btn');
const startContentBtnCourse = document.querySelector('.course-big-btn');
if (startContentBtn && startContentBtn.innerText === 'Start Path') {
startContentBtn.innerText = 'Start path';
}
if (startContentBtnCourse && startContentBtnCourse.innerText === 'Start Course') {
startContentBtnCourse.innerText = 'Start course';
}
eventType.forEach((event) => {
if (event.innerText === 'Online Event') {
event.innerText = 'Online event'
}
})
}
document.addEventListener("DOMContentLoaded", (event) => {
changeBackBtnUrl();
limitLpDescription();
changeEventRegisterBtnText();
changeTextTransform();
});
</script>

View File

@ -0,0 +1,238 @@
<header class="np-header np-header-color">
<div class="np-header-content">
<div class="np-hidden-desktop np-header-mobile-menu-nav">
{% if current_person.signed_in? %}
<button
data-toggle-class="np-hidden"
class="np-header-mobile-menu-nav-button fal fa-times np-hidden np-header-font-color"
data-toggle-target=".np-header-mobile-avatar-menu,
.np-header-mobile-menu-content, .np-main, .np-footer"
></button>
<button
data-test="open-mobile-menu"
data-toggle-class="np-hidden"
class="np-header-mobile-menu-nav-button np-header-mobile-avatar-menu"
data-toggle-target=".fa-times, .np-header-mobile-menu-content, .np-main, .np-footer"
>
<i class="fal fa-bars avatar-icon"></i>
</button>
{% endif %}
</div>
{% if current_school.logo_url %}
<h1 class="np-header-logo">
<a href="{% route home %}">
<img
alt="{{ current_school.name }}"
class="np-header-logo-image"
src="{{ current_school.logo_url }}"
/>
</a>
</h1>
{% else %}
<a href="{% route home %}" class="np-school-name np-header-font-color">
{{ current_school.name }}
</a>
{% endif %}
<div class="header-right">
<div class="header-link-container"></div>
<a class="header-link" href="/app">Home</a>
<a class="header-link" href="/app/dashboard">Dashboard</a>
<a class="header-link" href="/app/catalog" >Courses</a>
<a class="header-link" href="/app/learning_paths" >Learning paths</a>
<a class="header-link" href="/app/training_events">Events</a>
<a class="header-link" href="https://www.woodmac.com/about/contact-us/">Help</a>
</div>
</div>
<div class="np-hidden-mobile np-header-desktop-nav">
<ul class="np-header-desktop-nav-list">
{% for website_navigation in navigations.header_navigations_external %}
<li class= "np-header-desktop-nav-item">
<a
href="{{ website_navigation.path }}"
class="np-header-desktop-nav-link np-header-font-color"
target="_blank"
>
{{ website_navigation.name }}
</a>
</li>
{% endfor %}
</ul>
</div>
{% if current_person.signed_in? %}
<div class="np-hidden-mobile np-header-search np-header-search-expanded">
<form action="{% route search %}" method="get" data-test="desktop-search">
<input
aria-label="{% t .search %}"
class="np-header-search-input np-header-font-background-color"
type="text"
name="q"
placeholder="{% t .search %}"
/>
<i class="np-header-search-icon far fa-search"></i>
</form>
</div>
<div class="np-hidden-mobile np-header-avatar">
<button
class="np-header-avatar-button"
data-test="open-desktop-menu"
data-toggle-class-on-target="np-hidden"
data-toggle-target=".np-header-avatar-tooltip"
data-toggle-outside
>
<img
alt="{{ current_person.name }}"
class="np-header-avatar-image"
src="{{ current_person.avatar_url }}"
>
</button>
<div class="np-header-avatar-tooltip np-hidden" role="tooltip">
<span class="np-header-avatar-tooltip-arrow-up"></span>
<div class="np-header-avatar-tooltip-learner">
<div class="np-header-avatar-tooltip-learner-name">
{{ current_person.name }}
</div>
<div class="np-header-avatar-tooltip-learner-email">
{{ current_person.email }}
</div>
</div>
<nav class="np-header-avatar-tooltip-navigation">
{% unless current_school.sso_active? %}
<a
class="np-header-avatar-tooltip-navigation-link"
href="{% route account %}"
>
{% t .profile_settings %}
</a>
{% endunless %}
{% if current_person.signed_in? %}
<a
class="np-header-avatar-tooltip-navigation-link"
href="{% route transcript %}"
>
{% t .transcript %}
</a>
{% endif %}
<a
class="np-header-avatar-tooltip-navigation-link np-danger"
href="{% route logout %}"
>
{% t .sign_out %}
</a>
</nav>
</div>
</div>
{% else %}
<a
class="np-header-sign-in np-header-desktop-nav-link np-header-font-color"
aria-label="{% t shared.sign_in %}"
href="{% route login %}"
>
{% t shared.sign_in %}
</a>
{% endif %}
</div>
</header>
<div class="np-hidden-desktop">
<div class="np-header-mobile-menu-content np-hidden">
{% if current_person.signed_in? %}
<img
alt="{{ current_person.name }}"
class="np-header-mobile-menu-content-avatar"
src="{{ current_person.avatar_url }}"
/>
<div class="np-header-mobile-menu-content-name">
{{ current_person.name }}
</div>
{% endif %}
<div class="np-header-mobile-menu-content-nav">
<form
class="np-header-search"
data-test="mobile-search"
method="get"
action="{% route search %}"
>
<input
aria-label="{% t .search %}"
class="np-header-search-input"
type="text"
name="q"
placeholder="{% t .search %}"
/>
<i class="np-header-search-icon far fa-search"></i>
</form>
{% for website_navigation in navigations.header_navigations %}
<a
href="{{ website_navigation.path }}"
class="np-header-mobile-menu-content-button"
{% if website_navigation.external? %} target="_blank" {% endif %}
>
{{ website_navigation.name }}
</a>
{% endfor %}
<a href="/app/catalog" class="np-header-mobile-menu-content-button">Courses</a>
<a href="https://www.woodmac.com/about/contact-us/" class="np-header-mobile-menu-content-button" target="_blank">Help</a>
<div class="np-header-mobile-menu-content-line"></div>
{% unless current_school.sso_active? %}
<a
class="np-header-mobile-menu-content-button"
href="{% route account %}"
>
{% t .profile_settings %}
</a>
{% endunless %}
{% if current_person.signed_in? %}
<a
class="np-header-mobile-menu-content-button"
href="{% route transcript %}"
>
{% t .transcript %}
</a>
{% endif %}
<a
class="np-header-mobile-menu-content-button np-danger"
href="{% route logout %}"
>
{% t .sign_out %}
</a>
</div>
</div>
</div>
{% include "messages" %}
<style>
.header-right{
display: flex;
align-items: center;
}
.header-link{
padding: 15px;
text-decoration: none;
font-family: "Arial", "Marope" ;
color: #01005F;
}
@media (max-width: 768px) {
.header-right {
display: none;
}
.np-header-logo-image{
height: 65px;
}
.fa-bars:before{
color: #0A23F5!important;
}
}
</style>

View File

@ -0,0 +1,17 @@
<header class="np-box-header np-header-color">
<a class="np-box-header-link" href="{% route home %}">
{% if current_school.logo_url %}
<img
alt="{{ current_school.name }}"
src="{{ current_school.logo_url }}"
class="np-box-header-logo"
/>
{% else %}
<span class="np-school-name np-header-font-color">
{{ current_school.name }}
</span>
{% endif %}
</a>
</header>
{% include "messages" %}

View File

@ -0,0 +1,5 @@
{% if learning_path.new_content_available? %}
{% include "learning_path_new_content_banner" %}
{% else %}
{% include "learning_path_completed_banner" %}
{% endif %}

View File

@ -0,0 +1,17 @@
{% if learning_path.has_certificate? %}
{% if learning_path.certificate_completed? %}
<div class="np-learning-path-outline-bar np-hidden-mobile"></div>
<a
class="np-learning-path-certificate-link"
href="{{ learning_path.certificate_link }}"
>
<div class="np-learning-path-certificate">
{% include "learning_path_certificate_content" %}
</div>
</a>
{% else %}
<div class="np-learning-path-certificate np-learning-path-certificate--inactive">
{% include "learning_path_certificate_content" %}
</div>
{% endif %}
{% endif %}

View File

@ -0,0 +1,19 @@
<div class="np-learning-path-certificate-content">
<div class="np-learning-path-certificate-avatar" role="img">
<i class="np-learning-path-certificate-avatar-icon fal fa-award"></i>
<h5 class="np-learning-path-certificate-avatar-title">
{% t .avatar_title %}
</h5>
</div>
<h4 class="np-learning-path-certificate-name">
{{ learning_path.certificate_name }}
</h4>
{% if learning_path.certificate_completed? %}
<time
class="np-learning-path-certificate-issue-date"
datetime="{{ learning_path.certificate_issue_date }}"
>
{{ learning_path.certificate_issue_date | date: "%B %d, %Y" }}
</time>
{% endif %}
</div>

View File

@ -0,0 +1,13 @@
<div class="np-learning-path-completed-banner np-learning-path-banner">
<img class="np-learning-path-banner-image" src="https://s3.amazonaws.com/static.northpass.com/images/stars-completed.svg"/>
<div class="np-learning-path-banner-content">
<h3 class="np-learning-path-banner-headline">{% t .headline %}</h3>
<p class="np-learning-path-banner-description">{% t .description %}</p>
<div class="np-learning-path-banner-actions">
{% if learning_path.certificate_link %}
<a href="{{ learning_path.certificate_link }}" class="np-learning-path-banner-action np-learning-path-banner-action--primary">{% t .actions.certificate %}</a>
{% endif %}
<a href="/app/courses" class="np-learning-path-banner-action np-learning-path-banner-action--secondary">{% t .actions.more_courses %}</a>
</div>
</div>
</div>

View File

@ -0,0 +1,56 @@
{% if learning_path.enrolled? and course.unlocked? %}
<div class="np-learning-path-outline-bar np-hidden-mobile"></div>
<a
class="np-learning-path-outline-item np-card-container"
href="{% route learning_path_course, learning_path_id: learning_path.id, id: course.id %}"
>
<div class="np-card-content np-card-padding">
<img
src="{{ item.image }}"
alt="{{ course.name }}"
class="np-learning-path-outline-course-image"
>
<div class="np-learning-path-outline-content">
<div class="np-learning-path-outline-name np-top-title">
{{ course.name }}
</div>
{% if course.instructors %}
<div class="np-learning-path-outline-caption">
{{ course.instructors }}
</div>
{% endif %}
<div class="np-learning-path-outline-progress
{% if course.completed? %} np-color-success {% else %} np-button-color {% endif %}
">
{% t shared.progress, count: course.progress %}
</div>
</div>
<i class="fas fa-chevron-right np-learning-path-outline-icon"></i>
{% if course.optional? %}
<div class="np-optional-ribbon">
{% t shared.optional %}
</div>
{% endif %}
</div>
</a>
{% else %}
<div class="np-learning-path-outline-item np-learning-path-outline-inactive-item np-card-container">
<div class="np-card-content np-card-padding">
<img
src="{{ item.image }}"
alt="{{ course.name }}"
class="np-learning-path-outline-course-image"
>
<div class="np-learning-path-outline-content">
<div class="np-learning-path-outline-name np-top-title">
{{ course.name }}
</div>
</div>
{% if course.optional? %}
<div class="np-optional-ribbon">
{% t shared.optional %}
</div>
{% endif %}
</div>
</div>
{% endif %}

View File

@ -0,0 +1,6 @@
<h3 class="np-card-heading">
About this learning path
</h3>
<div class="np-card-text">
{{ learning_path.description }}
</div>

View File

@ -0,0 +1,21 @@
<div class="row">
<div class="col-xs-12 col-sm-6">
<div class="np-card-container">
<img
src="{{ learning_path.image_url }}"
class="np-top-image"
alt="{{ learning_path.name }}"
/>
<div class="np-card-padding-dynamic">
{% include "learning_path_description" %}
{% include "learning_path_instructors" %}
</div>
</div>
</div>
<div class="col-xs-12 col-sm-6 np-grid-spacing">
<div class="np-top-cta">
{% include "learning_path_progress_and_cta" %}
</div>
{% include "learning_path_outline" %}
</div>
</div>

View File

@ -0,0 +1,12 @@
<div class="np-resource-header np-resource-header-card np-card-padding-large">
<div class="np-top-vocabulary np-text-title">
{% t shared.learning_path.title %}
<img class="overview-logo" src="https://s3.us-east-1.amazonaws.com/static.northpass.com/Woodmack/Sun-nav+icons/woodmac+icon+3.png" alt="">
</div>
<div class="np-top-title">
<a href="/app/learning_paths" class="np-back-button back-button" aria-label="{% t shared.go_back %}">
<i class="far fa-arrow-left np-icon-back"></i>
</a>
{{ learning_path.name }}
</div>
</div>

View File

@ -0,0 +1,2 @@
{% include "learning_path_desktop_header" %}
{% include "learning_path_desktop_content" %}

View File

@ -0,0 +1,26 @@
{% if learning_path.instructors.any? %}
<div class="np-card-content-divider">
<h3 class="np-card-heading">
{% t shared.instructors %}
</h3>
<div class="np-content-instructors-content row">
{% for instructor in learning_path.instructors %}
<div class="np-content-instructors-content-item col-xs-12 col-lg">
<img
src="{{ instructor.avatar_url }}"
class="np-content-instructors-content-image"
alt="{{ instructor.name }}"
>
<div class="np-content-instructors-content-description">
<div class="np-content-instructors-content-name">
{{ instructor.name }}
</div>
<div class="np-content-instructors-content-info np-text-light">
{{ instructor.title }}
</div>
</div>
</div>
{% endfor %}
</div>
</div>
{% endif %}

View File

@ -0,0 +1,19 @@
{% if learning_path.in_progress? %}
{% include "learning_path_outline" %}
<div class="np-card-container np-card-padding np-card-spacing">
{% include "learning_path_description" %}
</div>
{% else %}
<div class="np-card-container np-card-padding np-card-spacing">
{% include "learning_path_description" %}
</div>
<div class="np-card-spacing">
{% include "learning_path_outline" %}
</div>
{% endif %}
{% if learning_path.instructors.any? %}
<div class="np-card-container np-card-padding np-card-spacing">
{% include "learning_path_instructors" %}
</div>
{% endif %}

View File

@ -0,0 +1,17 @@
<div class="np-resource-header np-card-padding-vertical">
<div class="np-top-vocabulary np-text-title">
{% t shared.learning_path.title %}
<i class="far fa-road np-button-color np-learning-path-icon"></i>
</div>
<div class="np-top-title">
{{ learning_path.name }}
</div>
<img
src="{{ learning_path.image_url }}"
class="np-top-image"
alt="{{ learning_path.name }}"
/>
<div class="np-top-cta">
{% include "learning_path_progress_and_cta" %}
</div>
</div>

View File

@ -0,0 +1,2 @@
{% include "learning_path_mobile_header" %}
{% include "learning_path_mobile_content" %}

View File

@ -0,0 +1,12 @@
<div class="np-learning-path-new-content-banner np-learning-path-banner">
<div class="np-learning-path-banner-content">
<h3 class="np-learning-path-banner-headline">{% t .headline %}</h3>
<p class="np-learning-path-banner-description">{% t .description %}</p>
<div class="np-learning-path-banner-actions">
{% learning_path_next_step_button learning_path, class: "np-learning-path-banner-action np-learning-path-banner-action--primary" %}
{% if learning_path.certificate_link %}
<a href="{{ learning_path.certificate_link }}" class="np-learning-path-banner-action np-learning-path-banner-action--secondary">{% t .actions.view_certificate %}</a>
{% endif %}
</div>
</div>
</div>

View File

@ -0,0 +1,10 @@
<div class="np-learning-path-outline">
{% for item in learning_path.items %}
{% if item.course? %}
{% include "learning_path_course", course: item %}
{% elsif item.training_event? %}
{% include "learning_path_training_session", training_session: item %}
{% endif %}
{% endfor %}
{% include "learning_path_certificate" %}
</div>

View File

@ -0,0 +1,20 @@
{% if learning_path.enrolled? %}
<div class="np-top-cta-progress-content">
<div class="np-top-cta-progress-title np-text-title">
Learning path progress
</div>
<div class="np-progress-bar-container">
<div
style="width: {{ learning_path.progress }}%"
class="np-button-background-color np-card-progress-bar">
</div>
</div>
<div class="np-top-cta-progress-text
{% if learning_path.completed? %} np-color-success {% else %} np-button-color {% endif %}
">
{% t shared.progress, count: learning_path.progress %}
</div>
</div>
{% endif %}
{% learning_path_next_step_button learning_path, class: "np-top-button np-button-font-color np-button np-button-big lp-big-btn" %}

View File

@ -0,0 +1,3 @@
{% include "learning_path_desktop_header" %}
{% include "learning_path_banners" %}
{% include "learning_path_desktop_content" %}

View File

@ -0,0 +1,5 @@
<div class="np-card-padding">
{% include "learning_path_banners" %}
</div>
{% include "learning_path_mobile_header" %}
{% include "learning_path_mobile_content" %}

View File

@ -0,0 +1,53 @@
{% if learning_path.enrolled? and training_session.unlocked? %}
<div class="np-learning-path-outline-bar np-hidden-mobile"></div>
<a
class="np-learning-path-outline-item np-card-container"
href="{% route training_session, id: training_session.id %}"
>
<div class="np-card-content np-card-padding">
<div class="np-events-content-date np-button-background-color">
<div class="np-events-content-month">
{{ training_session.month }}
</div>
<div class="np-events-content-day">
{{ training_session.day }}
</div>
</div>
<div class="np-learning-path-outline-content">
<div class="np-learning-path-outline-name np-top-title">{{ training_session.name }}</div>
<div class="np-learning-path-outline-caption">{{ training_session.instructors }}</div>
<div class="np-events-content-time np-learning-path-outline-time np-button-color">
{{ training_session.time }} {{ training_session.time_zone }}
</div>
</div>
<i class="fas fa-chevron-right np-learning-path-outline-icon"></i>
{% if training_session.optional? %}
<div class="np-optional-ribbon">
{% t shared.optional %}
</div>
{% endif %}
</div>
</a>
{% else %}
<div class="np-learning-path-outline-item np-card-container np-learning-path-outline-inactive-item">
<div class="np-card-content np-card-padding">
<div class="np-events-content-date np-button-background-color">
<div class="np-events-content-month">
{{ training_session.month }}
</div>
<div class="np-events-content-day">
{{ training_session.day }}
</div>
</div>
<div class="np-learning-path-outline-content">
<div class="np-learning-path-outline-name np-top-title">{{ training_session.name }}</div>
<div class="np-learning-path-outline-caption">{{ training_session.caption }}</div>
</div>
{% if training_session.optional? %}
<div class="np-optional-ribbon">
{% t shared.optional %}
</div>
{% endif %}
</div>
</div>
{% endif %}

View File

@ -0,0 +1,14 @@
<div class="np-learning-paths-resources">
{% if items.any? %}
{% for learning_path in items %}
{% include "cards_learning_path" with learning_path %}
{% endfor %}
{% else %}
<div class="np-learning-paths-resources-container">
<div class="np-zero-state-text">
{% t .empty %}
</div>
<img class="np-zero-state-learning-paths" alt="{% t .empty %}" />
</div>
{% endif %}
</div>

View File

@ -0,0 +1,19 @@
{% if messages.alert.size > 0 %}
<div class="np-alert np-alert-error">
<div class="np-alert-wrapper">
{% for message in messages.alert %}
<div>{{ message }}</div>
{% endfor %}
</div>
</div>
{% endif %}
{% if messages.notice.size > 0 %}
<div class="np-alert np-alert-success">
<div class="np-alert-wrapper">
{% for message in messages.notice %}
<div>{{ message }}</div>
{% endfor %}
</div>
</div>
{% endif %}

View File

@ -0,0 +1,47 @@
<div class="progress-ring-wrapper">
<svg
class="progress-ring"
width="{{ size }}"
height="{{ size }}">
<circle
class="circle circle-bg"
stroke="{{ stroke_color_bg }}"
stroke-width="10"
fill="transparent"
r="52"
cx="60"
cy="60"
/>
<circle
class="circle circle-{{ name }}"
stroke="{{ stroke_color }}"
stroke-width="10"
fill="transparent"
r="52"
cx="60"
cy="60"
/>
<text x="50%" y="50%" text-anchor="middle" stroke="t#fff" stroke-width="1px" fill="{{ number_color }}" dy=".3em">
{{ count }}
</text>
</svg>
<h3 class="np-card-content-title progress-circle-label">
{{ name }}
</h3>
</div>
<script>
document.addEventListener("DOMContentLoaded", function() {
let circle = document.getElementsByClassName("circle-{{ name }}")[0];
let radius = circle.r.baseVal.value;
let circumference = radius * 2 * Math.PI;
circle.style.strokeDasharray = `${circumference} ${circumference}`;
circle.style.strokeDashoffset = `${circumference}`;
function setProgress(percent) {
circle.style.strokeDashoffset = circumference - percent * circumference;
}
setProgress('{{ count | divided_by: total }}')
})
</script>

View File

@ -0,0 +1,19 @@
<div class="np-card np-search-result">
<div class="np-card-container">
<div class="np-card-content">
<img
class="np-search-result-image"
alt="{{ result.name }}"
src="{{ result.image_url }}"
/>
<div class="np-search-result-content">
<div>
<a class="np-search-result-title" href="{{ result.path }}">
{{ result.name }}
</a>
</div>
<div class="np-search-result-snippet">{{ result.description }}</div>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,13 @@
<div class="np-card np-search-zero-state">
<div class="np-card-container">
<div class="np-card-content np-card-content-vertical np-search-zero-state-card">
<h3 class="np-search-zero-state-title">
{% t .nothing_found %}
</h3>
<div class="np-search-zero-state-subtitle">
{% t .empty %}
</div>
<div class="np-search-zero-state-image"></div>
</div>
</div>
</div>

View File

@ -0,0 +1,81 @@
<nav class="np-sub-navigation">
<div class="np-sub-navigation-content">
<!-- Dashboard -->
<div class="np-sub-navigation-content-item">
<a class="np-sub-navigation-content-item-link" href="/app/dashboard">
<img src="https://s3.us-east-1.amazonaws.com/static.northpass.com/Woodmack/Sun-nav+icons/Woodmac+-+icon+1.png" alt="Dashboard icon" class="sub-nav-icon">
Dashboard
</a>
<div class="np-sub-navigation-content-item-bar np-button-background-color"></div>
</div>
<!-- Courses -->
<div class="np-sub-navigation-content-item">
<a class="np-sub-navigation-content-item-link" href="/app/catalog">
<img src="https://s3.us-east-1.amazonaws.com/static.northpass.com/Woodmack/Sun-nav+icons/woodmac+icon+2.png" alt="Courses icon" class="sub-nav-icon">
Courses
</a>
<div class="np-sub-navigation-content-item-bar np-button-background-color"></div>
</div>
<!-- Learning Paths -->
<div class="np-sub-navigation-content-item">
<a class="np-sub-navigation-content-item-link" href="/app/learning_paths">
<img src="https://s3.us-east-1.amazonaws.com/static.northpass.com/Woodmack/Sun-nav+icons/woodmac+icon+3.png" alt="Learning Paths icon" class="sub-nav-icon">
Learning paths
</a>
<div class="np-sub-navigation-content-item-bar np-button-background-color"></div>
</div>
<!-- Instructor Led Events -->
<div class="np-sub-navigation-content-item">
<a class="np-sub-navigation-content-item-link" href="/app/training_events">
<img src="https://s3.us-east-1.amazonaws.com/static.northpass.com/Woodmack/Sun-nav+icons/icon.png" alt="Instructor Led Events icon" class="sub-nav-icon">
Instructor led events
</a>
<div class="np-sub-navigation-content-item-bar np-button-background-color"></div>
</div>
{% comment %}
<!-- Store -->
<div class="np-sub-navigation-content-item">
<a class="np-sub-navigation-content-item-link" href="#">
<img src="https://s3.us-east-1.amazonaws.com/static.northpass.com/Woodmack/Sun-nav+icons/woodmac+icon+5.png" alt="Store icon" class="sub-nav-icon">
Store
</a>
<div class="np-sub-navigation-content-item-bar np-button-background-color"></div>
</div>
{% endcomment %}
</div>
</nav>
<style>
.np-sub-navigation {
background: #fff;
margin-bottom: 16px;
padding: 32px 16px 32px 16px;
}
.np-sub-navigation-content-item-link{
color: #010063;
font-size: 16px;
height: 100%;
}
.np-sub-navigation-content{
justify-content: space-evenly;
}
.sub-nav-icon {
width: 100%;
height: 75px;
object-fit: contain;
}
@media (max-width: 768px) {
.sub-nav-icon{
height: 60px;
}
}
</style>

View File

@ -0,0 +1,8 @@
<div class="np-dashboard-resources">
{% if training_events.enrolled.any? %}
{% for training_event in training_events.enrolled limit: 1%}
{% include "cards_training_event" with training_event %}
{% endfor %}
{% endif %}
</div>

View File

@ -0,0 +1,69 @@
<div class="np-filter">
<div class="dropdown">
<button
class="np-button dropdown-button"
data-toggle-class="is-open"
data-toggle-escape
data-toggle-outside
data-toggle-target-next
type="button"
>
All events <i class=" far fa-solid fa-angle-down"></i>
</button>
<div class="dropdown-menu" data-test="modal">
<form method="get">
<span class="dropdown-label">
{% t shared.filters.by_event_type %}
</span>
<ul class="dropdown-checkboxes">
{% for event_type in training_events.filters.event_types %}
{% capture label %}
{% t shared.event_types, key: event_type.value %}
{% endcapture %}
<li>
{% include "filter_checkbox",
label: label,
name: event_type.name,
value: event_type.value
selected: event_type.selected?
%}
</li>
{% endfor %}
</ul>
{% capture label %}{% t shared.filters.by_course %}{% endcapture %}
{%
include "filter_select",
filters: training_events.filters.courses,
key: "courses_uuid",
label: label
%}
<button
class="np-button dropdown-button-apply"
data-toggle-trigger-off
type="submit"
>
{% t shared.filters.apply %}
</button>
</form>
</div>
</div>
</div>
<style>
.dropdown-button {
background-color: #ffffff!important;
color: #01005F;
}
.far {
font-weight: 400;
font-size: 20px;
margin-left: 25px;
}
</style>

View File

@ -0,0 +1,73 @@
<div class="np-dashboard-resources">
{% if training_events.available.any? %}
<div class="row row-with-thumbnails">
{% for training_event in training_events.available %}
<div class="col-xs-12 col-sm-6 col-lg-4 np-stretch-content">
{% include "cards_training_event" with training_event %}
</div>
{% endfor %}
</div>
{% else %}
{% include "training_events_zero_state" %}
{% endif %}
</div>
<script src="https://cdn.jsdelivr.net/npm/luxon@3.3.0/build/global/luxon.min.js"></script>
<script>
addEventListener("DOMContentLoaded", (event) => {
const timeZones = {
'-12': 'Etc/GMT+12',
'-11': 'Pacific/Pago_Pago',
'-10': 'Pacific/Honolulu',
'-09': 'America/Anchorage',
'-08': 'America/Los_Angeles',
'-07': 'America/Denver',
'-06': 'America/Chicago',
'-05': 'America/New_York',
'-04': 'America/Caracas',
'-03': 'America/Argentina/Buenos_Aires',
'-02': 'Atlantic/South_Georgia',
'-01': 'Atlantic/Azores',
'00': 'UTC',
'CET': 'CET',
'+01': 'Europe/Berlin',
'+02': 'Europe/Athens',
'+03': 'Europe/Moscow',
'+04': 'Asia/Dubai',
'+05': 'Asia/Karachi',
'+06': 'Asia/Almaty',
'+07': 'Asia/Bangkok',
'+08': 'Asia/Singapore',
'+09': 'Asia/Tokyo',
'+10': 'Australia/Sydney',
'+11': 'Pacific/Noumea',
'+12': 'Pacific/Auckland',
'+13': 'Pacific/Tongatapu',
'+14': 'Pacific/Kiritimati'
};
function formatTimeZone(offset) {
offset = offset.trim();
if (timeZones[offset]) {
return timeZones[offset];
}
try {
const zoneName = luxon.FixedOffsetZone.parseSpecifier(offset).name;
return `UTC${zoneName}`;
} catch {
return offset;
}
}
const offset = '+08';
const formattedZone = formatTimeZone(offset);
console.log(`Offset ${offset} to: ${formattedZone}`);
document.querySelectorAll('.zone').forEach((timeElement) => {
const offset = timeElement.textContent;
const formattedZone = formatTimeZone(offset);
timeElement.textContent = timeElement.textContent.replace(offset, formattedZone);
});
});
</script>

View File

@ -0,0 +1,9 @@
<div class="np-dashboard-resources-container">
<div class="np-zero-state-text">
{% t .empty %}
</div>
<img
class="np-zero-state-training-events"
alt="{% t .empty %}"
/>
</div>

View File

@ -0,0 +1,52 @@
<div class="dropdown dropdown-calendar">
<button
class="np-top-button np-button-font-color np-button np-button-big dropdown-calendar-button"
data-toggle-class="is-open"
data-toggle-escape
data-toggle-outside
data-toggle-target-next
type="button"
>
{% t .add_to_calendar %}
<i class="fas fa-chevron-down dropdown-calendar-button-chevron"></i>
</button>
<ul class="dropdown-calendar-menu">
<li class="dropdown-calendar-item">
<a
class="dropdown-calendar-item-element np-button-background-color-on-hover np-button-font-color-on-hover"
href="{{ training_session.google_calendar_url }}"
target="_blank"
>
{% t .google_calendar %}
</a>
</li>
<li class="dropdown-calendar-item">
<a
class="dropdown-calendar-item-element np-button-background-color-on-hover np-button-font-color-on-hover"
href="{{ training_session.outlook_calendar_url }}"
target="_blank"
>
{% t .outlook_calendar %}
</a>
</li>
<li class="dropdown-calendar-item">
<a
class="dropdown-calendar-item-element np-button-background-color-on-hover np-button-font-color-on-hover"
href="{{ training_session.outlook_office_calendar_url }}"
target="_blank"
>
{% t .office_calendar %}
</a>
</li>
<li class="dropdown-calendar-item">
<a
class="dropdown-calendar-item-element np-button-background-color-on-hover np-button-font-color-on-hover"
href="{{ training_session.ical_calendar_url }}"
target="_blank"
>
{% t .ical_calendar %}
</a>
</li>
</ul>
</div>

View File

@ -0,0 +1,53 @@
{% if training_session.approved? %}
{% comment %} <div class="np-training-session-cta-note">
<i class="far fa-check np-training-session-icon"></i>
{% t .registered %}
</div> {% endcomment %}
{% elsif training_session.pending? %}
<div class="np-training-session-cta-note np-training-session-cta-note-error">
{% t .pending %}
</div>
{% elsif training_session.denied? %}
<div class="np-training-session-cta-note np-training-session-cta-note-error">
{% t .denied %}
</div>
{% elsif training_session.too_late? %}
<div class="np-training-session-cta-note np-training-session-cta-note-error">
{% t .too_late %}
</div>
{% elsif training_session.no_seats? %}
<div class="np-training-session-cta-note np-training-session-cta-note-error">
{% t .no_seats %}
</div>
{% endif %}
<div class="np-training-session-cta">
<div class="np-training-session-cta-buttons">
<form
action="{% route training_session_registration, id: training_session.id %}"
method="post"
>
{% form_authenticity_token %}
{% if training_session.internal? and training_session.approved? %}
{% if features.training_events_google_calendar? %}
{% include "training_session_calendars" %}
<button type="submit" class="np-top-button np-button np-button-big np-button-secondary">
{% t .unregister %}
</button>
{% else %}
<button type="submit" class="np-top-button np-button-font-color np-button np-button-big">
{% t .unregister %}
</button>
{% endif %}
<input type="hidden" name="_method" value="delete" />
{% endif %}
{% if training_session.not_registered? %}
<button type="submit" class="np-top-button np-button np-button-big">
{% t .register %}
</button>
{% endif %}
</form>
</div>
</div>

View File

@ -0,0 +1,16 @@
<div class="np-card-training-session-date">
<div class="np-button-background-color np-card-training-session-date-bar"></div>
<div class="np-card-training-session-date-label">
<div class="np-card-training-session-date-day">
{{ training_session.day }}
</div>
<div>
<div class="np-card-training-session-date-month">
{{ training_session.month }}
</div>
<div class="np-card-training-session-date-year">
{{ training_session.year }}
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,6 @@
<h3 class="np-card-heading">
{% t .header %}
</h3>
<div class="np-card-text">
{{ training_event.description }}
</div>

View File

@ -0,0 +1,43 @@
<div class="np-resource-header np-resource-header-card np-card-padding-large">
{% include "training_session_header" %}
</div>
<div class="row np-training-session-row">
<div class="col-xs-12 col-sm-8">
<div class="np-card-container">
<div class="np-card-padding-large">
<div>
{% include "training_session_status" %}
{% include "training_session_date" %}
</div>
<div class="np-training-session-details">
{% include "training_session_details" %}
{% include "training_session_cta" %}
</div>
</div>
<div class="np-card-content-divider"></div>
<div class="np-card-padding-large">
{% include "training_session_description" %}
</div>
</div>
</div>
<div class="col-xs-12 col-sm-4 np-grid-spacing">
<div class="np-training-session-container">
<div class="np-training-session-sessions-title">
{% t shared.more_sessions %}
</div>
{% if training_event.sessions.size > 1 %}
{% include "training_session_more_sessions" %}
{% else %}
<div class="np-training-session-zero-state">
<img
alt="{% t .empty %}"
class="np-zero-state-training-sessions"
/>
<div class="np-training-session-zero-state-text">
{% t .empty %}
</div>
</div>
{% endif %}
</div>
</div>
</div>

View File

@ -0,0 +1,81 @@
<div class="np-training-session-info">
<div class="np-training-session-time">
<i class="fal fa-clock np-button-color np-training-session-icon"></i>
<time>{{ training_session.time_period }} {{ training_session.time_zone }}</time>
</div>
{% if training_session.approved? and training_session.location %}
<div class="np-training-session-location">
<i class="fal fa-map-marker-alt np-button-color np-training-session-icon"></i>
{{ training_session.location }}
</div>
{% endif %}
{% if training_session.approved? and training_session.session_url %}
<div class="np-training-session-location">
<i class="fal fa-map-marker-alt np-button-color np-training-session-icon"></i>
<a href="{{ training_session.session_url }}" class="np-button-color" target="_blank" >
{{ training_session.session_url }}
</a>
</div>
{% endif %}
</div>
<script src="https://cdn.jsdelivr.net/npm/luxon@3.3.0/build/global/luxon.min.js"></script>
<script>
const timeZones = {
'-12': 'Etc/GMT+12',
'-11': 'Pacific/Pago_Pago',
'-10': 'Pacific/Honolulu',
'-09': 'America/Anchorage',
'-08': 'America/Los_Angeles',
'-07': 'America/Denver',
'-06': 'America/Chicago',
'-05': 'America/New_York',
'-04': 'America/Caracas',
'-03': 'America/Argentina/Buenos_Aires',
'-02': 'Atlantic/South_Georgia',
'-01': 'Atlantic/Azores',
'00': 'UTC',
'CET': 'CET',
'+01': 'Europe/Berlin',
'+02': 'Europe/Athens',
'+03': 'Europe/Moscow',
'+04': 'Asia/Dubai',
'+05': 'Asia/Karachi',
'+06': 'Asia/Almaty',
'+07': 'Asia/Bangkok',
'+08': 'Asia/Singapore',
'+09': 'Asia/Tokyo',
'+10': 'Australia/Sydney',
'+11': 'Pacific/Noumea',
'+12': 'Pacific/Auckland',
'+13': 'Pacific/Tongatapu',
'+14': 'Pacific/Kiritimati'
};
function formatTimeZone(offset) {
offset = offset.trim();
if (timeZones[offset]) {
return timeZones[offset];
}
try {
const zoneName = luxon.FixedOffsetZone.parseSpecifier(offset).name;
return `UTC${zoneName}`;
} catch {
return `{{ training_session.time_zone }}`;
}
}
const offset = '+08';
const formattedZone = formatTimeZone(offset);
console.log(`Offset ${offset} to: ${formattedZone}`);
document.querySelectorAll('time').forEach((timeElement) => {
const offset = timeElement.textContent.split(' ').pop();
const formattedZone = formatTimeZone(offset);
timeElement.textContent = timeElement.textContent.replace(offset, formattedZone);
});
</script>

View File

@ -0,0 +1,10 @@
<div class="np-top-vocabulary np-text-title">
{% t shared.event_types, key: training_event.event_type %}
<i class="fal {{ training_event.event_type_icon }} np-button-color np-training-session-icon"></i>
</div>
<div class="np-top-title">
<a href="/app/training_events" class="np-back-button back-button" aria-label="{% t shared.go_back %}">
<i class="far fa-arrow-left np-hidden-mobile np-icon-back"></i>
</a>
{{ training_event.title }}
</div>

View File

@ -0,0 +1,27 @@
<div class="np-training-session-view">
<div class="np-training-session-view-header">
{% include "training_session_header" %}
</div>
<div class="np-card-container np-training-session-view-details np-card-padding np-card-spacing">
{% include "training_session_status" %}
{% include "training_session_date" %}
{% include "training_session_details" %}
<div class="np-card-padding-large">
{% include "training_session_cta" %}
</div>
{% include "training_session_description" %}
</div>
{% if training_event.sessions.size > 1 %}
<div class="np-card-spacing">
<div class="np-training-session-container">
<div class="np-training-session-sessions-title">
{% t shared.more_sessions %}
</div>
{% include "training_session_more_sessions" %}
</div>
</div>
{% endif %}
</div>

View File

@ -0,0 +1,3 @@
{% for session in training_event.sessions %}
{% include "training_session_tile", current_session: training_session %}
{% endfor %}

View File

@ -0,0 +1,6 @@
<div class="np-training-session-cta-note np-training-session-tile-badge np-training-session-tile-badge-{{ training_session.status.type }}" id="session-status">
{% if training_session.approved? %}
<i class="far fa-check np-training-session-icon"></i>
{% endif %}
{{ training_session.status.label }}
</div>

View File

@ -0,0 +1,24 @@
{% if current_session.id != session.id %}
<a
class="np-training-session-tile"
href="{% route training_session, id: session.id %}"
>
<div class="np-training-session-tile-header">
<i class="far fa-calendar-star np-training-session-tile-icon"></i>
<div class="np-training-session-tile-badge np-training-session-tile-badge-{{ session.status.type }}">
{{ session.status.label }}
</div>
</div>
<div class="np-training-session-tile-content">
<div>
<div class="np-training-session-tile-date">
{{ session.month }} {{ session.day }}, {{ session.year }}
</div>
<div class="np-training-session-tile-time">
{{ session.time_period }} {{ session.time_zone }}
</div>
</div>
<i class="fas fa-arrow-right np-training-session-tile-chevron"></i>
</div>
</a>
{% endif %}

View File

@ -0,0 +1,128 @@
{% assign ring_background_color = 'rgba(192, 220, 246, 0.6)' %}
{% assign ring_fill_color = '#0A23F5' %}
{% assign number_color = 'rgb(0, 0, 0)' %}
{% assign text_color = '#0274de' %}
{% assign background_color = 'white' %}
<div class="progress-card-wrapper">
<div class="progress-card">
{% if courses.enrolled.any? %}
{% assign countComplete = 0 %}
{% assign countInProgress = 0 %}
{% assign countNotStarted = 0 %}
{% assign countTotal = 0 | times: 1.0 %}
{% for course in courses.enrolled %}
{% assign countTotal = countTotal | plus: 1 %}
{% if course.progress == 100 %}
{% assign countComplete = countComplete | plus: 1 %}
{% endif %}
{% if course.progress > 0 and course.progress < 100 %}
{% assign countInProgress = countInProgress | plus: 1 %}
{% endif %}
{% if course.progress == 0 %}
{% assign countNotStarted = countNotStarted | plus: 1 %}
{% endif %}
{% endfor %}
<ul class="progress-circle-list">
<li>
{%
include "progress_circle",
name: 'Completed' ,
count: countComplete ,
total: countTotal,
size: "120",
stroke_color: ring_fill_color,
stroke_color_bg: ring_background_color,
text_color: text_color,
number_color: number_color
%}
</li>
<li>
{%
include "progress_circle",
name:'In progress' ,
count: countInProgress ,
total: countTotal,
size: "120",
stroke_color: ring_fill_color,
stroke_color_bg: ring_background_color,
text_color: text_color,
number_color: number_color
%}
</li>
</ul>
{% else %}
{% capture message %}
{% t shared.zero_state.courses.index,
key: current_school.course_vocabulary
%}
{% endcapture %}
{% include "courses_zero_state", message: message %}
{% endif %}
</div>
</div>
<style>
.progress-card {
border-radius: 8px;
background: {{ background_color }};
padding: 0;
display: flex;
margin-bottom: 2.187rem;
width: 100%;
}
.progress-circle-list {
padding: 0;
list-style-type: none !important;
justify-content: space-around;
display: inline-flex;
align-items: center;
max-width: 400px;
margin: auto;
}
.progress-ring-wrapper {
flex: 0;
flex-direction: column;
display: flex;
width: 100%;
padding: 1.5rem 1rem 1rem 1rem;
align-items: center;
}
.progress-ring circle {
stroke-linecap: round;
transition: stroke-dashoffset 0.35s;
transform: rotate(-90deg);
transform-origin: center;
}
.progress-ring text {
font-size:2rem;
}
.progress-circle-label {
color: #010063;
font-size: 0.875rem;
margin-top: 1rem;
}
@media (min-width:768px) {
.progress-ring-wrapper {
padding: 1.5rem 0.4rem 1rem 0.4rem;
}
.progress-circle-list {
flex-direction: column;
}
}
@media screen and (min-width: 1023px) {
.progress-circle-list {
flex-direction: row;
}
}
@media (min-width:1170px) {
.progress-ring text {
font-size: 2.5rem;
}
.progress-ring-wrapper {
padding: 1.5rem 1rem 1rem 1rem;
}
}
</style>

View File

@ -0,0 +1,15 @@
{% include "header" %}
{% include "account_tabs" %}
<main class="np-main np-subpage-container np-account">
<div class="np-hidden-desktop">
{% include "account_mobile_view", form: form %}
</div>
<div class="np-hidden-mobile np-flex np-flex-center">
{% include "account_desktop_view", form: form %}
</div>
</main>
{% include "footer" %}

View File

@ -0,0 +1,59 @@
<main class="np-box-container np-open-access">
<div class="np-box">
{% include "header_minimal" %}
<div class="np-box-content-container">
<form class="np-form np-box-content" action="{{ form.url }}" method="get" novalidate>
{% form_authenticity_token %}
<div class="np-form-headline">
{% t shared.welcome_to_school, school_name: current_school.name %}
</div>
<div class="np-form-subheadline">
{% t .headline, key: current_school.course_vocabulary %}
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_first_name">
{% t shared.first_name %}
</label>
<input
class="np-input"
autofocus="autofocus"
type="text"
name="first_name"
id="learner_first_name"
value="{{ form.first_name }}"
/>
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_last_name">
{% t shared.last_name %}
</label>
<input
class="np-input"
type="text"
name="last_name"
id="learner_last_name"
value="{{ form.last_name }}"
/>
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_email">
{% t shared.email_address %}
</label>
<input
class="np-input"
type="text"
name="email"
id="learner_email"
value="{{ form.email }}"
/>
</div>
<input
type="submit"
name="commit"
value="{% t shared.enter %}"
class="np-button np-button-big np-form-action"
/>
</form>
</div>
</div>
</main>

View File

@ -0,0 +1,59 @@
<main class="np-box-container np-open-access">
<div class="np-box">
{% include "header_minimal" %}
<div class="np-box-content-container">
<form class="np-form np-box-content" action="{{ form.url }}" method="get" novalidate>
{% form_authenticity_token %}
<div class="np-form-headline">
{% t shared.welcome_to_school, school_name: current_school.name %}
</div>
<div class="np-form-subheadline">
{% t .headline, key: current_school.course_vocabulary %}
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_employee_id">
{% t shared.employee_id %}
</label>
<input
class="np-input"
autofocus="autofocus"
type="text"
name="employee_id"
id="learner_employee_id"
value="{{ form.employee_id }}"
/>
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_first_name">
{% t shared.first_name %}
</label>
<input
class="np-input"
type="text"
name="first_name"
id="learner_first_name"
value="{{ form.first_name }}"
/>
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_last_name">
{% t shared.last_name %}
</label>
<input
class="np-input"
type="text"
name="last_name"
id="learner_last_name"
value="{{ form.last_name }}"
/>
</div>
<input
type="submit"
name="commit"
value="{% t shared.enter %}"
class="np-button np-button-big np-form-action"
/>
</form>
</div>
</div>
</main>

View File

@ -0,0 +1,40 @@
<main class="np-box-container np-open-access">
<div class="np-box">
{% include "header_minimal" %}
<div class="np-box-content-container">
<form class="np-form np-box-content" action="{{ form.url }}" method="get" novalidate>
<div class="np-form-headline"> {% t shared.welcome_to_school, school_name: current_school.name %} </div>
<div class="np-form-subheadline"> {% t .headline, key: current_school.course_vocabulary %} </div>
{% form_authenticity_token %}
<div class="np-form-field">
<label class="np-input-label" for="learner_last_name">
{% t shared.last_name %}
</label>
<input
class="np-input"
autofocus="autofocus"
type="text"
name="last_name"
id="learner_last_name"
value="{{ form.last_name }}"
/>
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_phone_number">
{% t shared.phone_number %}
</label>
<input
class="np-input"
type="text"
name="phone_number"
id="learner_phone_number"
value="{{ form.phone_number }}"
/>
</div>
<button type="submit" class="np-button np-button-big np-form-action">
{% t shared.enter %}
</button>
</form>
</div>
</div>
</main>

View File

@ -0,0 +1,74 @@
<main class="np-box-container np-open-access">
<div class="np-box">
{% include "header_minimal" %}
<div class="np-box-content-container">
<form class="np-form np-box-content" action="{{ form.url }}" method="get" novalidate>
<div class="np-form-headline"> {% t shared.welcome_to_school, school_name: current_school.name %} </div>
<div class="np-form-subheadline"> {% t .headline, key: current_school.course_vocabulary %} </div>
{% form_authenticity_token %}
<div class="np-form-field">
<label class="np-input-label" for="learner_email">
{% t shared.email_address %}
</label>
<input
class="np-input"
autofocus="autofocus"
type="email"
name="email"
id="learner_email"
value="{{ form.email }}"
/>
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_first_name">
{% t shared.first_name %}
</label>
<input
class="np-input"
type="text"
name="first_name"
id="learner_first_name"
value="{{ form.first_name }}"
/>
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_last_name">
{% t shared.last_name %}
</label>
<input
class="np-input"
type="text"
name="last_name"
id="learner_last_name"
value="{{ form.last_name }}"
/>
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_phone_number">
{% t shared.phone_number_optional %}
</label>
<input
class="np-input"
type="text"
name="phone_number"
id="learner_phone_number"
value="{{ form.phone_number }}"
/>
</div>
<div class="np-form-field np-open-access-terms">
<input type="hidden" name="terms" value="0" />
<input id="terms" type="checkbox" name="terms" value="1" />
<label for="terms" class="np-open-access-terms-checkbox">
{{ current_school.custom_terms }}
</label>
</div>
<input
type="submit"
name="commit"
value="{% t shared.enter %}"
class="np-button np-button-big np-form-action"
/>
</form>
</div>
</div>
</main>

View File

@ -0,0 +1,35 @@
{% include "header" %}
{% include "course_version_outdated_alert", courses: courses.in_catalog %}
<main class="np-main np-catalog np-subpage-container np-max-width">
<div class="np-catalog-header-wrapper">
<div class="np-catalog-header">
<div class="np-resource-title">Courses</div>
<div class="np-resource-subtitle">Empower your expertise: choose a course to master a Wood Mackenzie product or<br> expand your industry knowledge</div>
</div>
</div>
{% comment %} {% capture label %}{% t shared.filters.by_category %}{% endcapture %}
{% if courses.in_catalog.any? %}
{%
include "filter_dropdown",
filters: courses.filters,
key: "category_uuid",
label: label
%}
{% endif %} {% endcomment %}
{% include 'filters-catalog' %}
</div>
{% comment %} {% include "courses_catalog" %} {% endcomment %}
{% include "categories_courses" %}
</main>
{% include "footer" %}
<style>
.np-resource-subtitle{
color: #01005F;
font-size: 23px;
}
</style>

View File

@ -0,0 +1,10 @@
{% include "header" %}
<main class="np-main np-max-width np-page-container">
<div class="np-hidden-mobile" id="course-desktop">
{% include "course_desktop_view" %}
</div>
<div class="np-hidden-desktop" id="course-mobile">
{% include "course_mobile_view" %}
</div>
</main>
{% include "footer" %}

View File

@ -0,0 +1,10 @@
{% include "header" %}
{% include "course_version_outdated_alert", courses: courses.enrolled %}
<main class="np-main np-courses np-subpage-container np-max-width">
<div class="np-resource-title">
{% t shared.course_vocabulary.plural, key: current_school.course_vocabulary %}
</div>
<div class="np-resource-subtitle">{% t .headline, key: current_school.course_vocabulary %}</div>
{% include "courses_index", class: "col-xs-12 col-sm-6 col-lg-4 np-stretch-content" %}
</main>
{% include "footer" %}

View File

@ -0,0 +1,72 @@
{% assign not_started_flag = false %}
{% assign in_progress_flag = false %}
{% assign completed_flag = false %}
{% if courses.enrolled.any? %}
{% for course in courses.enrolled %}
{% if course.progress == 0 %}
{% assign not_started_flag = true %}
{% elsif course.progress > 0 and course.progress < 100 %}
{% assign in_progress_flag = true %}
{% else %}
{% assign completed_flag = true %}
{% endif %}
{% endfor %}
{% endif %}
{% if not_started_flag%}
<div class="role-quick-link-heading" style="color:red">
Not Started
</div>
<div class="row row-with-thumbnails">
{% for course in courses.enrolled %}
{% if course.progress == 0 %}
<div class="{{ class }}">
{% include "cards_course" with course %}
</div>
{% endif %}
{% endfor %}
</div>
{% endif %}
{% if in_progress_flag == true %}
<div class="role-quick-link-heading" style="color:#7319F2">
In Progress
</div>
<div class="row row-with-thumbnails">
{% for course in courses.enrolled %}
{% if course.progress > 0 and course.progress < 100%}
<div class="{{ class }}">
{% include "cards_course" with course %}
</div>
{% endif %}
{% endfor %}
</div>
{% endif %}
{% if completed_flag%}
<div class="role-quick-link-heading" style="color:green">
Completed
</div>
<div class="row row-with-thumbnails">
{% for course in courses.enrolled %}
{% if course.progress == 100 %}
<div class="{{ class }}">
{% include "cards_course" with course %}
</div>
{% endif %}
{% endfor %}
</div>
{% endif %}
<style>
.role-quick-link-heading {
font-size:20px!important;
font-weight: 600!important;
text-align: left;
padding-bottom: 15px;
}
</style>

View File

@ -0,0 +1,386 @@
{% assign enrolled_events = 0 %}
{% for training_event in training_events.enrolled %}
{% assign enrolled_events = enrolled_events | plus: 1 %}
{% endfor %}
{% include "header" %}
{% include "course_version_outdated_alert", courses: courses.enrolled %}
<div class="np-banner-container ">
<div class="banner-wrapper np-max-width">
<div class="np-banner-content">
<div class="dashboard-heading">Dashboard</div>
<div class="dashboard-greeting-text">
<p>Hi {{ current_person.first_name }}!</p>
<p>Continue where you left off or dive into <br>something new – your learning journey awaits!</p>
</div>
</div>
<div class="dashboard-stats">
<div class="dashboard-heading">
Course progress
</div>
{% include 'widget_course_progress' %}
</div>
<div class="dashboard-upcoming-events">
<div class="upcoming_events_heading">Upcoming events</div>
<div class="event-card" >
{% include "training_events_dashboard" %}
</div>
<div class="see-more-container"></div>
<button class="see-more-button" onclick="scrollToRegisteredEvents()">See more</button>
</div>
</div>
</div>
</div>
<main class="np-main np-dashboard np-subpage-container np-max-width">
{% assign in_progress_flag = false %}
{% assign not_started_flag = false %}
{% assign completed_flag = false %}
{% if courses.enrolled.any? %}
{% for course in courses.enrolled %}
{% if course.progress == 0 %}
{% assign not_started_flag = true %}
{% elsif course.progress > 0 and course.progress < 100 %}
{% assign in_progress_flag = true %}
{% else %}
{% assign completed_flag = true %}
{% endif %}
{% endfor %}
{% endif %}
<!-- In Progress Courses -->
{% if in_progress_flag %}
<div class="in-progress-container" onclick="toggleDropdown(this)" data-expanded="false">
<div class="role-quick-link-heading" >In progress courses</div> <span class="dropdown-arrow">â–Ľ</span>
</div>
<div class="category-courses course-items-container">
{% for course in courses.enrolled %}
{% if course.progress > 0 and course.progress < 100 %}
<div class="category-cards-wrapper course-item">
{% include "cards_course" with course %}
</div>
{% endif %}
{% endfor %}
</div>
{% endif %}
<!-- Not Started Courses -->
{% if not_started_flag %}
<div class="in-progress-container" onclick="toggleDropdown(this)" data-expanded="false">
<div class="role-quick-link-heading" >Available courses</div><span class="dropdown-arrow">â–Ľ</span>
</div>
<div class="category-courses course-items-container" >
{% for course in courses.enrolled %}
{% if course.progress == 0 %}
<div class="category-cards-wrapper course-item">
{% include "cards_course" with course %}
</div>
{% endif %}
{% endfor %}
</div>
{% endif %}
<!-- Completed Courses -->
{% if completed_flag %}
<div class="in-progress-container" onclick="toggleDropdown(this)" data-expanded="false">
<div class="role-quick-link-heading" >Completed courses</div><span class="dropdown-arrow">â–Ľ</span>
</div>
<div class="category-courses course-items-container">
{% for course in courses.enrolled %}
{% if course.progress == 100 %}
<div class="category-cards-wrapper course-item">
{% include "cards_course" with course %}
</div>
{% endif %}
{% endfor %}
</div>
{% endif %}
<!-- Registered Events -->
{% assign enrolled_events = 0 %}
{% for training_event in training_events.enrolled %}
{% assign enrolled_events = enrolled_events | plus: 1 %}
{% endfor %}
{% if enrolled_events > 0 %}
<div id="registered-events-section" class="in-progress-container" onclick="toggleDropdown(this)" data-expanded="false">
<div class="role-quick-link-heading">Upcoming events</div><span class="dropdown-arrow">â–Ľ</span>
</div>
<div class="category-courses course-items-container">
{% for training_event in training_events.enrolled %}
<div class="category-cards-wrapper course-item">
{% include "cards_training_event" %}
</div>
{% endfor %}
</div>
{% endif %}
</main>
{% include "footer" %}
<script>
function scrollToRegisteredEvents() {
document.getElementById("registered-events-section").scrollIntoView({ behavior: "smooth" });
}
document.addEventListener("DOMContentLoaded", function() {
function setCourseItemsVisibility(container) {
const items = container.querySelectorAll(".course-item");
const isExpanded = container.previousElementSibling.getAttribute("data-expanded") === "true";
items.forEach((item, index) => {
item.style.display = (index < 3 || isExpanded) ? "block" : "none";
});
}
window.toggleDropdown = function(element) {
const container = element.nextElementSibling;
if (container && container.classList.contains("course-items-container")) {
const isExpanded = element.getAttribute("data-expanded") === "true";
element.setAttribute("data-expanded", !isExpanded);
setCourseItemsVisibility(container);
element.querySelector(".dropdown-arrow").textContent = isExpanded ? "â–Ľ" : "â–˛";
}
};
document.querySelectorAll(".course-items-container").forEach(container => {
setCourseItemsVisibility(container);
});
});
</script>
<style>
.np-banner-container{
display: flex;
padding: 33px;
background-color: #EEEFEF;
margin-bottom: 20px;
align-items: flex-start;
gap: 20px;
justify-content: space-around;
}
.np-dashboard-resources{
border-radius: 16px;
}
.category-courses {
display: grid;
grid-template-columns: repeat(3,1fr);
gap: 20px;
margin-bottom: 40px;
}
@media (max-width: 768px) {
.category-courses{
display: flex;
flex-direction: column;
}
}
.banner-wrapper {
display: flex;
justify-content: space-between;
width: 100%;
gap: 30px;
}
.dashboard-heading{
font-size: 2.5rem;
color: #010063;
font-weight: 500;
}
.upcoming_events_heading {
font-size: 2.5rem;
color: #010063;
font-weight: 500;
padding-bottom: 25px;
}
.np-dashboard-resources-title{
font-size: 25px;
color: #0A23F5;
font-weight: bold;
padding-bottom: 25px;
text-transform: none;
}
.dashboard-greeting-text{
color: #01005F;
font-size: 22px;
}
.course-items-container {
width: 100%;
}
.progress-circles {
display: flex;
justify-content: space-between;
}
.progress-circle {
display: flex;
flex-direction: column;
align-items: center;
background-color: #FFFFFF;
padding: 20px;
border-radius: 50%;
width: 120px;
height: 120px;
justify-content: center;
border: 8px solid #B0B0B0;
}
.progress-count {
font-size: 32px;
font-weight: bold;
color: #333333;
}
.progress-label {
font-size: 14px;
color: #01005F;
margin-top: 5px;
}
.progress-card-wrapper {
margin-top: 20px;
}
.section-title{
color:#0A23F5;
}
.progress-circles-container{
padding: 40px;
background-color: #FFFFFF;
}
.progress-circles-container {
padding: 40px;
background-color: #FFFFFF;
border-radius: 15px;
}
.in-progress-container {
background-color: #0A23F5;
padding: 10px;
margin-bottom: 15px;
width: 100%;
cursor: pointer;
display: flex;
align-items: center;
justify-content: space-between;
}
.role-quick-link-heading {
font-size: 20px;
font-weight: 600;
color: #FFFFFF;
}
.dropdown-arrow {
font-size: 18px;
transition: transform 0.3s;
color: #fff;
}
.course-items {
overflow: hidden;
height: 500px;
transition: height 0.3s ease;
}
.course-items.show {
height: auto;
}
.hidden-course {
display: none;
}
.course-items.show .hidden-course {
display: block;
}
.see-more-button{
color: #fff;
background-color: #091ED3;
padding: 10px;
border-radius: 4px;
border: none;
}
@media (max-width: 768px) {
.banner-wrapper{
flex-direction: column;
}
}
</style>
<script>
addEventListener("DOMContentLoaded", (event) => {
const timeZones = {
'-12': 'Etc/GMT+12',
'-11': 'Pacific/Pago_Pago',
'-10': 'Pacific/Honolulu',
'-09': 'America/Anchorage',
'-08': 'America/Los_Angeles',
'-07': 'America/Denver',
'-06': 'America/Chicago',
'-05': 'America/New_York',
'-04': 'America/Caracas',
'-03': 'America/Argentina/Buenos_Aires',
'-02': 'Atlantic/South_Georgia',
'-01': 'Atlantic/Azores',
'00': 'UTC',
'CET': 'CET',
'+01': 'Europe/Berlin',
'+02': 'Europe/Athens',
'+03': 'Europe/Moscow',
'+04': 'Asia/Dubai',
'+05': 'Asia/Karachi',
'+06': 'Asia/Almaty',
'+07': 'Asia/Bangkok',
'+08': 'Asia/Singapore',
'+09': 'Asia/Tokyo',
'+10': 'Australia/Sydney',
'+11': 'Pacific/Noumea',
'+12': 'Pacific/Auckland',
'+13': 'Pacific/Tongatapu',
'+14': 'Pacific/Kiritimati'
};
function formatTimeZone(offset) {
offset = offset.trim();
if (timeZones[offset]) {
return timeZones[offset];
}
try {
const zoneName = luxon.FixedOffsetZone.parseSpecifier(offset).name;
return `UTC${zoneName}`;
} catch {
return offset;
}
}
const offset = '+08';
const formattedZone = formatTimeZone(offset);
console.log(`Offset ${offset} to: ${formattedZone}`);
document.querySelectorAll('.zone').forEach((timeElement) => {
const offset = timeElement.textContent;
const formattedZone = formatTimeZone(offset);
timeElement.textContent = timeElement.textContent.replace(offset, formattedZone);
});
});
</script>

View File

@ -0,0 +1,25 @@
<main class="np-box-container">
<div class="np-box">
{% include "header_minimal" %}
<div class="np-box-content-container">
<form class="np-form np-box-content" action="{% route forgot_password_create %}" method="post" novalidate>
{% form_authenticity_token %}
<div class="np-form-field">
<label class="np-input-label" for="learner_email">
{% t shared.email_address %}
</label>
<input
autofocus="autofocus"
class="np-input"
id="learner_email"
name="learner[email]"
type="email"
>
</div>
<button type="submit" class="np-button np-button-big np-button-large-font np-form-action">
{% t .button_label %}
</button>
</form>
</div>
</div>
</main>

View File

@ -0,0 +1,125 @@
{% include "header" %}
{% include "course_version_outdated_alert", courses: courses.featured %}
<main class="np-main np-homepage">
<div class="np-homepage-hero">
<img class="np-homepage-hero-image"
src="{{ homepage.artwork_url }}"
alt="{{ homepage.headline }}"
/>
<div class="np-homepage-hero-content">
<div class="np-homepage-headline np-header-font-color">
{{ homepage.headline }}
</div>
<div class="np-homepage-subheadline np-header-font-color">
{{ homepage.subheadline }}
</div>
</div>
</div>
{% include "sub_navigation" %}
<div class="np-featured-intro">
<p class="np-featured-text">
Discover your path: select a <strong>Course Category</strong> to start learning or go to <strong>Dashboard</strong> to pickup where you left off
</p>
</div>
<div class="np-homepage-featured np-max-width">
<div class="np-homepage-featured-text">
<div class="np-homepage-featured-headline">
Featured courses
</div>
<div class="np-homepage-subheadline">
{{ homepage.featured_courses_subheadline }}
</div>
</div>
{% if courses.featured.any? %}
<div class="np-homepage-featured-courses row">
{% for course in courses.featured %}
{% include "cards_course_featured" with course %}
{% endfor %}
</div>
{% else %}
<div class="np-homepage-featured-empty">
<div class="np-zero-state-text">
{% t .empty, key: current_school.course_vocabulary %}
</div>
<img
class="np-zero-state-courses"
alt="{% t .empty, key: current_school.course_vocabulary %}"
/>
</div>
{% endif %}
</div>
</main>
{% include "footer" %}
<style>
.np-homepage-hero .np-homepage-headline {
font-size: 35px;
color: #ffffff;
font-weight: normal;
font-family: "arial", "Marope";
}
.np-homepage-hero .np-homepage-subheadline{
font-size: 35px;
color: #ffffff!important;
font-weight: normal;
font-family: "arial", "Marope";
opacity: 1;
}
.np-homepage-hero-content {
padding: 36px 24px;
position: absolute;
text-align: left;
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
justify-content: end;
}
.np-featured-intro{
text-align: center;
color: #010063;
font-size: 22px;
}
.np-homepage-featured-headline{
color: #010063 !important;
font-size: 35px;
font-weight: bold;
font-family: "arial", "Marope";
}
@media (max-width: 1617px) and (min-width: 768px) {
.np-homepage-hero .np-homepage-headline {
font-size: 27px;
}
.np-homepage-hero .np-homepage-subheadline {
font-size: 28px;
}
}
@media (max-width: 768px) {
.np-homepage-hero .np-homepage-headline{
font-size: 30px;
}
.np-homepage-hero .np-homepage-subheadline {
font-size: 30px;
line-height: 2rem;
}
.np-homepage-hero-content {
text-align: left;
margin-right: 25px;
margin-top: 0;
}
}
</style>

View File

@ -0,0 +1,10 @@
{% include "header" %}
<main class="np-main np-max-width np-page-container">
<div class="np-hidden-mobile" id="learning-path-desktop">
{% include "learning_path_desktop_view" %}
</div>
<div class="np-hidden-desktop" id="learning-path-mobile">
{% include "learning_path_mobile_view" %}
</div>
</main>
{% include "footer" %}

View File

@ -0,0 +1,10 @@
{% include "header" %}
<main class="np-main np-max-width np-page-container">
<div class="np-hidden-mobile" id="learning-path-desktop">
{% include "learning_path_summary_desktop_view" %}
</div>
<div class="np-hidden-desktop" id="learning-path-mobile">
{% include "learning_path_summary_mobile_view" %}
</div>
</main>
{% include "footer" %}

View File

@ -0,0 +1,24 @@
{% include "header" %}
<main class="np-main np-learning-paths np-subpage-container np-max-width">
<div class="np-learning-paths-main">
<div class="np-resource-title">
{% t shared.learning_paths %}
</div>
<div class="np-resource-subtitle">
{% t .subtitle %}
</div>
<div class="lp-filter-container">
{% include 'filters_learning_paths' %}
</div>
{% include "learning_paths_index", items: learning_paths.available %}
</div>
</main>
{% include "footer" %}
<style>
@media (max-width: 768px) {
.np-resource-title{
font-size: 1.75rem;
}
}
</style>

View File

@ -0,0 +1,53 @@
<main class="np-main np-box-container">
<div class="np-box">
{% include "header_minimal" %}
<div class="np-box-content-container">
<form class="np-form np-box-content" action="{% route login %}" method="post" novalidate>
{% form_authenticity_token %}
<div class="np-form-field">
<label class="np-input-label" for="learner_email">
{% t shared.email_address %}
</label>
<input
class="np-input"
autofocus="autofocus"
type="email"
name="learner[email]"
id="learner_email"
>
</div>
<div class="np-form-field">
<label class="np-input-label" for="learner_password">
{% t shared.password %}
</label>
<input
class="np-input"
type="password"
name="learner[password]"
id="learner_password"
>
</div>
<button type="submit" class="np-button np-button-big np-button-large-font np-form-action">
{% t shared.sign_in %}
</button>
<a class="np-form-link np-button-color" href="{% route forgot_password_new %}">
{% t .forgot_password %}
</a>
{% if features.account_creation? %}
<a class="np-form-link np-button-color" href="{% route sign_up %}">
{% t shared.sign_up %}
</a>
{% endif %}
{% if features.request_access? %}
<a
class="np-form-link np-button-color"
target="_blank"
href="{{ current_school.request_access_link }}"
>
{{ current_school.request_access_label }}
</a>
{% endif %}
</form>
</div>
</div>
</main>

View File

@ -0,0 +1 @@
{% body %}

View File

@ -0,0 +1,10 @@
<main class="np-main np-max-width np-subpage-container">
<div class="np-homepage-featured-text">
<div class="np-homepage-headline">
{% t .header %}
</div>
</div>
<div class="np-homepage-featured-empty">
<img src="/images/404.svg">
</div>
</main>

Some files were not shown because too many files have changed in this diff Show More