Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 0 additions & 20 deletions src/LearningCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,26 +53,6 @@ export class LearningCard extends LitElement {
});
}

// Lit life-cycle; this fires the 1st time the element is rendered on the screen
// this is a sign it is safe to make calls to this.shadowRoot
firstUpdated(changedProperties) {
if (super.firstUpdated) {
super.firstUpdated(changedProperties);
}
}

// HTMLElement life-cycle, element has been connected to the page / added or moved
// this fires EVERY time the element is moved
connectedCallback() {
super.connectedCallback();
}

// HTMLElement life-cycle, element has been removed from the page OR moved
// this fires every time the element moves
disconnectedCallback() {
super.disconnectedCallback();
}

// CSS - specific to Lit
static get styles() {
return css`
Expand Down
12 changes: 2 additions & 10 deletions src/LearningIcon.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import { html, css } from 'lit';
import { SimpleColors } from '@lrnwebcomponents/simple-colors';
import { html, css, LitElement } from 'lit';

const beaker = new URL('../assets/beaker.svg', import.meta.url).href;
const lightbulb = new URL('../assets/lightbulb.svg', import.meta.url).href;
const question = new URL('../assets/question.svg', import.meta.url).href;

export class LearningIcon extends SimpleColors {
export class LearningIcon extends LitElement {

constructor() {
super();
Expand All @@ -19,7 +18,6 @@ export class LearningIcon extends SimpleColors {

static get properties() {
return {
...super.properties,
icon: {type: String },
type: {type: String },
};
Expand Down Expand Up @@ -47,12 +45,6 @@ export class LearningIcon extends SimpleColors {
});
}

firstUpdated(changedProperties) {
if (super.firstUpdated) {
super.firstUpdated(changedProperties);
}
}

render() {
return html`
<div>
Expand Down
16 changes: 2 additions & 14 deletions src/LearningScaffold.js
Original file line number Diff line number Diff line change
@@ -1,25 +1,13 @@
import {html, css} from 'lit';
import { SimpleColors } from '@lrnwebcomponents/simple-colors';
import {html, css, LitElement} from 'lit';

export class LearningScaffold extends SimpleColors {

constructor() {
super();
}
export class LearningScaffold extends LitElement {

static get tag() {
return 'learning-scaffold';
}

static get properties() {
return {
...super.properties,
}
}

static get styles() {
return [
...super.styles,
css`
:host {
display: block;
Expand Down
Loading