diff --git a/packages/cxl-lumo-styles/scss/color.scss b/packages/cxl-lumo-styles/scss/color.scss index 38a224291..69eb2cb4d 100644 --- a/packages/cxl-lumo-styles/scss/color.scss +++ b/packages/cxl-lumo-styles/scss/color.scss @@ -58,6 +58,7 @@ html, --lumo-primary-color: hsl(355.8, 74.7%, 48%); --lumo-primary-color-2pct: hsla(355.8, 74.7%, 48%, 0.02); --lumo-primary-color-10pct: hsla(355.8, 74.7%, 48%, 0.1); + --lumo-primary-color-20pct: hsla(355.8, 74.7%, 48%, 0.2); --lumo-primary-color-50pct: hsla(355.8, 74.7%, 48%, 0.5); /** diff --git a/packages/cxl-lumo-styles/scss/global.scss b/packages/cxl-lumo-styles/scss/global.scss index a40c0b6ee..31f796aad 100644 --- a/packages/cxl-lumo-styles/scss/global.scss +++ b/packages/cxl-lumo-styles/scss/global.scss @@ -8,6 +8,7 @@ html { --cxl-wrap-padding: var(--lumo-space-m); --cxl-space-sm: 12px; --cxl-color-light-gray: hsla(0, 0%, 96%, 1); + --cxl-color-medium-gray: hsla(210, 20%, 96%, 1); --cxl-color-dark-gray: hsla(240, 1%, 24%, 1); --cxl-color-black: hsl(0, 0%, 0%); --cxl-color-black-50pct: hsla(0, 0%, 0%, 0.5); diff --git a/packages/cxl-lumo-styles/scss/themes/cxl-tabs-slider.scss b/packages/cxl-lumo-styles/scss/themes/cxl-tabs-slider.scss index a1678b7cf..8f1f6b9a7 100644 --- a/packages/cxl-lumo-styles/scss/themes/cxl-tabs-slider.scss +++ b/packages/cxl-lumo-styles/scss/themes/cxl-tabs-slider.scss @@ -68,8 +68,8 @@ } /** - * Theme "featured-course-slider" -*/ + * Theme "featured-course-slider" + */ :host([theme~="cxl-featured-course-slider"][orientation="horizontal"]) { position: relative; @@ -139,8 +139,8 @@ } /** - * Theme "cxl-course-slider" -*/ + * Theme "cxl-course-slider" + */ :host([theme~="cxl-course-slider"][theme~="minimal"]) { margin-top: calc(var(--lumo-space-s) * -1); @@ -217,8 +217,8 @@ } /** - * Theme "cxl-course-slider" and "cxl-category-accordion" -*/ + * Theme "cxl-course-slider" and "cxl-category-accordion" + */ :host([theme~="cxl-course-slider"][theme~="cxl-category-accordion"][theme~="minimal"]) { margin-left: calc(-1 * var(--lumo-space-m)); @@ -227,3 +227,26 @@ margin-left: calc(-1 * var(--lumo-space-l)); } } + +/** + * Theme "cxl-course-slider" and "cxl-slider-dashboard-header" + */ + +:host([theme~="cxl-course-slider"][theme~="cxl-slider-dashboard-header"][theme~="minimal"]) { + margin-left: calc(-1 * var(--lumo-space-m)); + + @media #{mq.$small} { + margin-left: calc(-1 * var(--lumo-space-l)); + } + + &::before, + &::after { + background: linear-gradient(270deg, var(--cxl-color-medium-gray) 0%, rgba(255, 255, 255, 0) 100%); + } +} + +:host([theme~="cxl-course-slider"][theme~="cxl-slider-dashboard-header"][theme~="portrait"]) { + ::slotted(vaadin-tab) { + width: auto; + } +} diff --git a/packages/cxl-ui/scss/cxl-base-card.scss b/packages/cxl-ui/scss/cxl-base-card.scss index 245656110..be1d35f68 100644 --- a/packages/cxl-ui/scss/cxl-base-card.scss +++ b/packages/cxl-ui/scss/cxl-base-card.scss @@ -119,7 +119,6 @@ display: flex; gap: var(--lumo-space-s); max-width: 100%; - min-height: 1.6em; } .attributes { diff --git a/packages/cxl-ui/scss/cxl-dashboard-header.scss b/packages/cxl-ui/scss/cxl-dashboard-header.scss index dbd8d8c94..6da4ba5a9 100644 --- a/packages/cxl-ui/scss/cxl-dashboard-header.scss +++ b/packages/cxl-ui/scss/cxl-dashboard-header.scss @@ -2,26 +2,52 @@ @use "~@conversionxl/cxl-lumo-styles/scss/mixins"; :host { + position: relative; + background-color: var(--cxl-color-medium-gray); + + &:before { + content: ''; + position: absolute; + top: 0; + bottom: 0; + left: 50%; + z-index: 0; + width: 100vw; + background-color: var(--cxl-color-medium-gray); + transform: translateX(-50%); + } + .container { - padding: 0 var(--lumo-space-m); - background-color: var(--cxl-color-light-gray); + position: relative; + padding: 0 var(--lumo-space-m) var(--lumo-space-l); + z-index: 1; + + @media #{mq.$medium} { + padding: calc(var(--lumo-space-m) * 2) var(--lumo-space-l); + } + } + + .updates { + position: relative; @media #{mq.$medium} { - padding: 0 var(--lumo-space-l); + position: absolute; + right: var(--lumo-space-l); + bottom: calc(100% + var(--lumo-space-m)); } } header { - margin-bottom: var(--lumo-space-l); + margin-bottom: var(--lumo-space-s); @media #{mq.$medium} { display: flex; - align-items: center; + align-items: flex-start; justify-content: space-between; - padding-top: var(--lumo-size-s); } .titles { + flex-shrink: 0; padding-top: var(--lumo-size-s); @media #{mq.$medium} { @@ -33,191 +59,98 @@ font-size: var(--lumo-font-size-xs); line-height: 1; text-transform: uppercase; + color: var(--cxl-color-black-50pct); } - .updates { - @media #{mq.$medium} { - order: 2; - padding-bottom: 0; - } + .title { + margin: 0; } - } - .icon-bell { - position: relative; - margin-right: 14px; - - &::after { - position: absolute; - top: 4px; - right: -7px; - display: flex; - align-items: center; - justify-content: center; - width: 12px; - height: 12px; - font-size: 8px; - font-weight: 700; - color: var(--lumo-tint); - content: attr(count); - background-color: var(--lumo-primary-color); - border: 2px solid var(--cxl-color-dark-gray); - border-radius: 100%; + h1.title { + padding-right: var(--lumo-space-m); + font-size: var(--lumo-font-size-xxxl); + font-weight: 900; + line-height: 1.4; } } - .title { - margin: 0; - font-size: var(--lumo-font-size-xxxl); - line-height: 1.4; - } - - .content { - padding-bottom: var(--lumo-space-l); + .header-flex { + display: flex; + justify-content: space-between; - @media #{mq.$large} { - padding-bottom: var(--lumo-space-xl); + @media #{mq.$medium} { + flex-direction: column; } - } - - .last-course { - margin-bottom: var(--lumo-space-l); @media #{mq.$large} { - display: flex; - } - - a { - display: flex; - flex: 1; - align-items: center; - justify-content: space-between; - padding: var(--lumo-space-m); - color: var(--lumo-body-text-color); - text-decoration: none; - background-color: var(--lumo-primary-contrast-color); - - > div { - display: flex; - flex-direction: column; - } - - .subtitle { - font-size: var(--lumo-font-size-xs); - line-height: 1; - color: var(--cxl-color-black-50pct); - text-transform: uppercase; - } - - .title { - margin-top: calc(var(--lumo-space-s) / 2); - font-size: var(--lumo-font-size-xl); - font-weight: 700; - line-height: 1.2; - } - - vaadin-icon { - flex-shrink: 0; - margin-left: var(--lumo-space-s); - color: var(--lumo-primary-color); - background: var(--lumo-shade-10pct); - border-radius: 100%; - } + flex-direction: row; } } - .progress { + .edit-roadmap { display: flex; - flex-direction: column; - justify-content: center; - padding: var(--lumo-space-m); - color: var(--lumo-body-text-color); - background-color: var(--cxl-color-light-gray); - } + align-items: center; + max-width: fit-content; + height: fit-content; + padding: 0 var(--lumo-space-s); + margin-left: var(--lumo-space-s); + color: var(--lumo-primary-color); + cursor: pointer; + background-color: var(--lumo-primary-contrast-color); + border-radius: var(--lumo-border-radius-s); - .courses { - display: flex; - flex-direction: column; - gap: var(--lumo-space-s); + @media #{mq.$medium} { + margin-left: 0; + } @media #{mq.$large} { - flex-direction: row; - gap: var(--lumo-space-m); + margin-left: var(--lumo-space-m); } - vaadin-button { - display: flex; - align-items: center; - justify-content: space-between; - height: var(--lumo-size-xl); - padding: var(--lumo-space-m); - line-height: 1.3; - cursor: pointer; - border-radius: var(--lumo-border-radius-s); - background-color: var(--lumo-primary-contrast-color); - - &::part(label) { - width: 100%; - padding-right: var(--lumo-space-l); - text-align: left; - } - - @media #{mq.$large} { - width: 100%; - } + .edit-roadmap-text-affix { + display: none; - vaadin-icon { - position: absolute; - right: var(--lumo-space-m); - color: var(--lumo-primary-color); - background-color: var(--lumo-tint-5pct); - border-radius: 100%; + @media #{mq.$medium} { + display: inline; } } - .roadmap { - color: var(--lumo-primary-contrast-color); - background-color: var(--lumo-primary-color); - - @media #{mq.$large} { - color: var(--lumo-primary-contrast-color); - } - - vaadin-icon { - color: var(--lumo-primary-contrast-color); - } + &::part(label) { + line-height: 1.5; } } -} -:host([hasroadmap]) { - .content { - @media #{mq.$large} { - display: grid; - grid-template-columns: repeat(3, 1fr); - column-gap: var(--lumo-space-l); + .roadmap { + color: var(--lumo-primary-contrast-color); + background-color: var(--lumo-primary-color); - > div { - grid-column: 1 / 3; - } + @media #{mq.$large} { + color: var(--lumo-primary-contrast-color); + } - .stats { - grid-column: 3 / 4; - } + vaadin-icon { + color: var(--lumo-primary-contrast-color); } } -} -::slotted(.stats-desktop) { - display: none; + .slider { + margin-top: var(--lumo-space-l); + } - @media #{mq.$large} { + .slider-title { display: block; + margin-bottom: var(--lumo-space-s); + font-size: var(--lumo-font-size-xs); + line-height: 1; + text-transform: uppercase; + color: var(--cxl-color-black-50pct); } -} -::slotted(.stats-mobile) { - @media #{mq.$large} { - display: none; + .content { + & + .content { + margin-top: var(--lumo-space-l); + padding-top: var(--lumo-space-l); + border-top: 1px solid var(--lumo-shade-20pct); + } } } diff --git a/packages/cxl-ui/scss/cxl-light-card.scss b/packages/cxl-ui/scss/cxl-light-card.scss index 8d560e53a..169d4504c 100644 --- a/packages/cxl-ui/scss/cxl-light-card.scss +++ b/packages/cxl-ui/scss/cxl-light-card.scss @@ -1,7 +1,7 @@ :host { min-width: 267px; // 3col widths on 1400px max-width: 300px; - height: auto; + height: 100%; min-height: calc(3 * var(--lumo-space-xl)); padding: var(--lumo-space-m) var(--lumo-space-m) var(--lumo-space-s); overflow: hidden; @@ -123,6 +123,10 @@ margin-left: -3px; // to align with the instructor text color: var(--lumo-tint-40pct); } + + .progress { + color: var(--lumo-primary-contrast-color); + } } :host([theme~="portrait"]) { @@ -133,11 +137,13 @@ .container { display: block; + height: 100%; padding: 0; } header { - display: block; + display: flex; + flex-direction: column; } .info { diff --git a/packages/cxl-ui/scss/cxl-stats.scss b/packages/cxl-ui/scss/cxl-stats.scss index 8380cf825..3c3f10106 100644 --- a/packages/cxl-ui/scss/cxl-stats.scss +++ b/packages/cxl-ui/scss/cxl-stats.scss @@ -16,11 +16,18 @@ } :host([theme~="cxl-stats-dashboard-header"]) { - padding: var(--lumo-space-m); + margin-top: var(--lumo-space-m); + padding: 0; border: 0; - background-color: var(--lumo-primary-contrast-color); @media #{mq.$medium} { - grid-template-columns: repeat(2, 1fr); + margin-top: 0; + gap: var(--lumo-space-l); + } +} + +:host([theme~="cxl-stats-dashboard-header"][theme~="completed"]) { + @media #{mq.$medium} { + grid-template-columns: repeat(3, 1fr); } } diff --git a/packages/cxl-ui/scss/global/cxl-dashboard-header.scss b/packages/cxl-ui/scss/global/cxl-dashboard-header.scss index b9df43dca..049d99125 100644 --- a/packages/cxl-ui/scss/global/cxl-dashboard-header.scss +++ b/packages/cxl-ui/scss/global/cxl-dashboard-header.scss @@ -2,22 +2,4 @@ cxl-dashboard-header { position: relative; z-index: 1; display: block; - - .edit-roadmap { - display: flex; - align-items: center; - align-self: end; - max-width: fit-content; - height: fit-content; - padding: 0 var(--lumo-space-s); - margin: 0; - color: var(--lumo-primary-color); - cursor: pointer; - background-color: var(--lumo-primary-contrast-color); - border-radius: var(--lumo-border-radius-s); - - &::part(label) { - line-height: 1.5; - } - } } diff --git a/packages/cxl-ui/scss/global/cxl-stats.scss b/packages/cxl-ui/scss/global/cxl-stats.scss index 8c5f2a1e5..7e38845df 100644 --- a/packages/cxl-ui/scss/global/cxl-stats.scss +++ b/packages/cxl-ui/scss/global/cxl-stats.scss @@ -1,6 +1,10 @@ @use "~@conversionxl/cxl-lumo-styles/scss/mq"; cxl-stats { + .stat-item { + min-width: 112px; + } + .stat-title { margin: 0 0 var(--lumo-space-s) 0; font-size: var(--lumo-font-size-xs); @@ -19,11 +23,14 @@ cxl-stats { small { font-size: var(--lumo-font-size-l); } + } + + a.stat-count { + color: var(--cxl-color-black); + text-decoration: underline; - a { - font-size: var(--lumo-font-size-m); - font-weight: 400; - text-decoration: underline; + &:hover { + color: var(--lumo-primary-color); } } } diff --git a/packages/cxl-ui/src/components/cxl-base-card.js b/packages/cxl-ui/src/components/cxl-base-card.js index e7f2f21b2..6755188dc 100644 --- a/packages/cxl-ui/src/components/cxl-base-card.js +++ b/packages/cxl-ui/src/components/cxl-base-card.js @@ -59,18 +59,20 @@ export class CXLBaseCardElement extends LitElement { } _renderHeaderAttributes() { - return html` - ${this.time || this.instructor - ? html`
- ${unsafeHTML(el.count)} ${el.link ? html`${el.link}` : nothing} -
-- ${unsafeHTML(el.count)} ${el.link ? html`${el.link}` : nothing} -
-GA4 is packed with new capabilities that help you improve acquisition, engagement, revenue, and retention for your website.
In five hours, we'll have you confident, capable, and armed with new insights into your business and your website. This course pays back for you real quick.
", - tags: ['Marketing', 'Analytics'], - ctaUrl: 'https://cxl.com', - avatar: - 'https://cxl.com/institute/wp-content/uploads/2020/04/fred-pike-instructor-headshot-1x1-color-bw-min-1024x1024.png', + notificationCount: 6, + showCompletedStats: true, + showContinueSlider: true, + showRoadmap: true, + showRoadmapStats: true, + showRoadmapSlider: true, + editRoadmapLinkUrl: 'https://cxl.com', + showMinidegrees: true }; return html`GA4 is packed with new capabilities that help you improve acquisition, engagement, revenue, and retention for your website.
In five hours, we'll have you confident, capable, and armed with new insights into your business and your website. This course pays back for you real quick.
", - tags: ['Marketing', 'Analytics'], - ctaUrl: 'https://cxl.com', - avatar: - 'https://cxl.com/institute/wp-content/uploads/2020/04/fred-pike-instructor-headshot-1x1-color-bw-min-1024x1024.png', + notificationCount: 6, + showCompletedStats: true, + showContinueSlider: true, + showRoadmap: true, + showRoadmapStats: true, + showRoadmapSlider: true, + editRoadmapLinkUrl: 'https://cxl.com', + showMinidegrees: true }; return html`