@sparkle-learning/core 0.0.45 → 0.0.46
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/header-mobile-collapse_61.cjs.entry.js +6 -106
- package/dist/cjs/{icons-c61db785.js → icons-fda820af.js} +0 -0
- package/dist/cjs/sparkle-code.cjs.entry.js +1 -1
- package/dist/cjs/sparkle-menu-collapsible.cjs.entry.js +1 -1
- package/dist/esm/header-mobile-collapse_61.entry.js +8 -108
- package/dist/esm/{icons-9b62a1ec.js → icons-1c794c74.js} +0 -0
- package/dist/esm/sparkle-code.entry.js +1 -1
- package/dist/esm/sparkle-menu-collapsible.entry.js +1 -1
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/button/button.css +49 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/cards/card/card.css +208 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/cards/cards.css +31 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/code/code.css +245 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/dropdown/dropdown.css +115 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/header/header-mobile-collapse/header-mobile-collapse.css +255 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/header/header.css +232 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/collapsible/collapsible.css +3 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/menu-toggle/menu-toggle.css +25 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/menu.css +71 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/nav/nav.css +194 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/notfound-page/notfound-page.css +4 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/overlay/overlay.css +67 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/page-footer/page-footer.css +18 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/pagination/pagination.css +93 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/select/select.css +52 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/sidebar/sidebar.css +98 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/sparkle-lower-content-nav/sparkle-lower-content-nav.css +8 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/table-of-contents/table-of-contents.css +37 -0
- package/dist/node_modules/@sparkle-learning/components/dist/collection/components/tabs/tabs.css +64 -0
- package/dist/sparkle-core/{p-0fa3fd63.entry.js → p-11a6c175.entry.js} +1 -1
- package/dist/sparkle-core/{p-a102341e.entry.js → p-957715c5.entry.js} +1 -1
- package/dist/sparkle-core/{p-421d4a6e.entry.js → p-a465598d.entry.js} +26 -30
- package/dist/sparkle-core/{p-e8073714.js → p-cabe9139.js} +0 -0
- package/dist/sparkle-core/sparkle-core.esm.js +1 -1
- package/package.json +2 -2
@@ -3,7 +3,7 @@
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
4
4
|
|
5
5
|
const index = require('./index-51e8292e.js');
|
6
|
-
const icons = require('./icons-
|
6
|
+
const icons = require('./icons-fda820af.js');
|
7
7
|
const ionicGlobal = require('./ionic-global-2cde9d3a.js');
|
8
8
|
const helpers = require('./helpers-c2496722.js');
|
9
9
|
const theme = require('./theme-b0b295c1.js');
|
@@ -16601,106 +16601,6 @@ const SparklePageFooter = class {
|
|
16601
16601
|
};
|
16602
16602
|
SparklePageFooter.style = pageFooterCss;
|
16603
16603
|
|
16604
|
-
/*!
|
16605
|
-
* (C) Ionic http://ionicframework.com - MIT License
|
16606
|
-
*/
|
16607
|
-
/**
|
16608
|
-
* Waits for a component to be ready for
|
16609
|
-
* both custom element and non-custom element builds.
|
16610
|
-
* If non-custom element build, el.componentOnReady
|
16611
|
-
* will be used.
|
16612
|
-
* For custom element builds, we wait a frame
|
16613
|
-
* so that the inner contents of the component
|
16614
|
-
* have a chance to render.
|
16615
|
-
*
|
16616
|
-
* Use this utility rather than calling
|
16617
|
-
* el.componentOnReady yourself.
|
16618
|
-
*/
|
16619
|
-
const componentOnReady = (el, callback) => {
|
16620
|
-
if (el.componentOnReady) {
|
16621
|
-
el.componentOnReady().then((resolvedEl) => callback(resolvedEl));
|
16622
|
-
}
|
16623
|
-
else {
|
16624
|
-
raf(() => callback(el));
|
16625
|
-
}
|
16626
|
-
};
|
16627
|
-
/**
|
16628
|
-
* Patched version of requestAnimationFrame that avoids ngzone
|
16629
|
-
* Use only when you know ngzone should not run
|
16630
|
-
*/
|
16631
|
-
const raf = (h) => {
|
16632
|
-
if (typeof __zone_symbol__requestAnimationFrame === 'function') {
|
16633
|
-
return __zone_symbol__requestAnimationFrame(h);
|
16634
|
-
}
|
16635
|
-
if (typeof requestAnimationFrame === 'function') {
|
16636
|
-
return requestAnimationFrame(h);
|
16637
|
-
}
|
16638
|
-
return setTimeout(h);
|
16639
|
-
};
|
16640
|
-
|
16641
|
-
/*!
|
16642
|
-
* (C) Ionic http://ionicframework.com - MIT License
|
16643
|
-
*/
|
16644
|
-
const createController = (tagName) => {
|
16645
|
-
return {
|
16646
|
-
create(options) {
|
16647
|
-
return createOverlay(tagName, options);
|
16648
|
-
},
|
16649
|
-
dismiss(data, role, id) {
|
16650
|
-
return dismissOverlay(document, data, role, tagName, id);
|
16651
|
-
},
|
16652
|
-
async getTop() {
|
16653
|
-
return getOverlay(document, tagName);
|
16654
|
-
},
|
16655
|
-
};
|
16656
|
-
};
|
16657
|
-
const toastController = /*@__PURE__*/ createController('ion-toast');
|
16658
|
-
const createOverlay = (tagName, opts) => {
|
16659
|
-
if (typeof window !== 'undefined' && typeof window.customElements !== 'undefined') {
|
16660
|
-
return window.customElements.whenDefined(tagName).then(() => {
|
16661
|
-
const element = document.createElement(tagName);
|
16662
|
-
element.classList.add('overlay-hidden');
|
16663
|
-
/**
|
16664
|
-
* Convert the passed in overlay options into props
|
16665
|
-
* that get passed down into the new overlay.
|
16666
|
-
*/
|
16667
|
-
Object.assign(element, Object.assign(Object.assign({}, opts), { hasController: true }));
|
16668
|
-
// append the overlay element to the document body
|
16669
|
-
getAppRoot(document).appendChild(element);
|
16670
|
-
return new Promise((resolve) => componentOnReady(element, resolve));
|
16671
|
-
});
|
16672
|
-
}
|
16673
|
-
return Promise.resolve();
|
16674
|
-
};
|
16675
|
-
const isOverlayHidden = (overlay) => overlay.classList.contains('overlay-hidden');
|
16676
|
-
const dismissOverlay = (doc, data, role, overlayTag, id) => {
|
16677
|
-
const overlay = getOverlay(doc, overlayTag, id);
|
16678
|
-
if (!overlay) {
|
16679
|
-
return Promise.reject('overlay does not exist');
|
16680
|
-
}
|
16681
|
-
return overlay.dismiss(data, role);
|
16682
|
-
};
|
16683
|
-
const getOverlays = (doc, selector) => {
|
16684
|
-
if (selector === undefined) {
|
16685
|
-
selector = 'ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-picker,ion-popover,ion-toast';
|
16686
|
-
}
|
16687
|
-
return Array.from(doc.querySelectorAll(selector)).filter((c) => c.overlayIndex > 0);
|
16688
|
-
};
|
16689
|
-
/**
|
16690
|
-
* Returns an overlay element
|
16691
|
-
* @param doc The document to find the element within.
|
16692
|
-
* @param overlayTag The selector for the overlay, defaults to Ionic overlay components.
|
16693
|
-
* @param id The unique identifier for the overlay instance.
|
16694
|
-
* @returns The overlay element or `undefined` if no overlay element is found.
|
16695
|
-
*/
|
16696
|
-
const getOverlay = (doc, overlayTag, id) => {
|
16697
|
-
const overlays = getOverlays(doc, overlayTag).filter((o) => !isOverlayHidden(o));
|
16698
|
-
return id === undefined ? overlays[overlays.length - 1] : overlays.find((o) => o.id === id);
|
16699
|
-
};
|
16700
|
-
const getAppRoot = (doc) => {
|
16701
|
-
return doc.querySelector('ion-app') || doc.body;
|
16702
|
-
};
|
16703
|
-
|
16704
16604
|
const paginationCss = "sparkle-pagination{border-color:var(--line-rule-color);border-style:solid;border-width:0 0 1px;display:flex;flex-wrap:wrap-reverse;padding:var(--page-padding, 2rem 0rem) 0}sparkle-pagination .next,sparkle-pagination .previous{max-width:100%;overflow:hidden}sparkle-pagination .next{margin-left:auto}sparkle-pagination a{border-radius:4px;display:flex;align-items:flex-start;flex-direction:column;padding:1em 1.5em;color:rgb(var(--accent-color-rgb))}sparkle-pagination .previous a{padding-left:0}sparkle-pagination .next a{padding-right:0;align-items:flex-end}@media (max-width: 700px){sparkle-pagination .previous a{padding-right:0.5rem}sparkle-pagination .next a{padding-left:0.5rem}}@media (hover: hover){sparkle-pagination a:hover,sparkle-pagination a:active{filter:brightness(0.8)}}sparkle-pagination .pagination__title{color:var(--text-color--lighter);font-size:12px;display:block}sparkle-pagination .pagination__text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;color:var(--ion-color-sparkle)}sparkle-pagination span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}sparkle-pagination svg{fill:currentColor;flex:none;height:1em;margin-bottom:-0.125em;width:1em}sparkle-pagination .next svg{margin-left:0.5em}sparkle-pagination .previous svg{margin-right:0.5em}.completed-toast{z-index:999999999999999999999999999 !important}";
|
16705
16605
|
|
16706
16606
|
const SparklePagination = class {
|
@@ -16710,18 +16610,18 @@ const SparklePagination = class {
|
|
16710
16610
|
}
|
16711
16611
|
async presentToast() {
|
16712
16612
|
console.log('showToast');
|
16713
|
-
const toast = await toastController.create({
|
16613
|
+
const toast = await overlays.toastController.create({
|
16714
16614
|
message: 'Lesson Completed.',
|
16715
|
-
duration:
|
16615
|
+
duration: 3000,
|
16716
16616
|
cssClass: "completed-toast"
|
16717
16617
|
});
|
16718
16618
|
toast.present();
|
16719
16619
|
}
|
16720
16620
|
async presentToastLastSession() {
|
16721
16621
|
console.log('showToast');
|
16722
|
-
const toast = await toastController.create({
|
16622
|
+
const toast = await overlays.toastController.create({
|
16723
16623
|
message: 'Session Completed',
|
16724
|
-
duration:
|
16624
|
+
duration: 3000,
|
16725
16625
|
cssClass: "completed-toast"
|
16726
16626
|
});
|
16727
16627
|
toast.present();
|
@@ -16742,7 +16642,7 @@ const SparklePagination = class {
|
|
16742
16642
|
links.push(index.h("stencil-route-link", { onClick: () => this.presentToastLastSession(), url: nextUrl, key: "next", class: "next", anchorTitle: nextText }, index.h("div", { class: "pagination__title" }, "Next"), index.h("div", { class: "pagination__text" }, index.h("span", null, nextText), index.h(icons.ForwardArrow, null))));
|
16743
16643
|
}
|
16744
16644
|
else {
|
16745
|
-
links.push(index.h("
|
16645
|
+
links.push(index.h("stencil-route-link", { onClick: () => this.presentToastLastSession(), url: nextUrl, key: "next", class: "next", anchorTitle: nextText }, index.h("div", { class: "pagination__title" }, "Next"), index.h("div", { class: "pagination__text" }, index.h("span", null, nextText), index.h(icons.ForwardArrow, null))));
|
16746
16646
|
}
|
16747
16647
|
}
|
16748
16648
|
return links;
|
File without changes
|
@@ -3,7 +3,7 @@
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
4
4
|
|
5
5
|
const index = require('./index-51e8292e.js');
|
6
|
-
const icons = require('./icons-
|
6
|
+
const icons = require('./icons-fda820af.js');
|
7
7
|
|
8
8
|
const codeCss = "code[class*=\"language-\"],pre[class*=\"language-\"]{color:#4d4d4c;background:none;white-space:pre;word-spacing:normal;word-break:normal;word-wrap:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;-moz-hyphens:none;-ms-hyphens:none;hyphens:none}pre[class*=\"language-\"],:not(pre)>code[class*=\"language-\"]{background:hsl(30, 20%, 25%)}pre[class*=\"language-\"]{padding:1em;margin:.5em 0;overflow:auto;border:.3em solid hsl(30, 20%, 40%);border-radius:.5em;box-shadow:1px 1px .5em black inset}:not(pre)>code[class*=\"language-\"]{padding:.15em .2em .05em;border-radius:.3em;border:.13em solid hsl(30, 20%, 40%);box-shadow:1px 1px .3em -.1em black inset;white-space:normal}.token.comment,.token.prolog,.token.doctype,.token.cdata{color:#8c9296}.token.punctuation{opacity:.7}.namespace{opacity:.7}.token.tag{color:#91c5ff}.token.tag .token.tag{color:#2b90ff}.token.property,.token.attr-name,.token.boolean,.token.number,.token.constant,.token.symbol{color:#8454ff}.token.selector,.token.char,.token.function,.token.builtin,.token.inserted{color:#ff6810}.token.operator,.token.string,.token.entity,.token.url,.token.attr-value,.language-css .token.string,.style .token.string,.token.variable{color:#42b983}.token.atrule{color:#ffbb01}.token.regex,.token.keyword,.token.important{color:#f55073}.token.important,.token.bold{font-weight:bold}.token.italic{font-style:italic}.token.entity{cursor:help}.token.deleted{color:red}sparkle-code[language=\"shell\"]>pre{background-color:var(--text-color--dark);border-radius:7px}sparkle-code[language=\"shell\"]:before{display:none}sparkle-code[language=\"shell\"] code{color:rgba(255, 255, 255, 0.7);font-size:13px}sparkle-code[language=\"shell\"] .token{color:inherit}sparkle-code[language=\"shell\"] .token.prompt{color:#fb96f9;user-select:none}sparkle-code[language=\"shell\"] .token.comment{color:rgba(255, 255, 255, 0.45)}sparkle-code{display:block;position:relative}sparkle-code:before{color:#bdc5d1;content:attr(language);font-family:var(--code-font-family);font-size:10px;letter-spacing:0.05em;line-height:1;padding:0.75em;position:absolute;right:0;text-transform:uppercase;top:0}sparkle-code[language=\"shell\"] pre{white-space:pre-wrap}.code-text__copy{position:absolute;right:0;top:-1.6rem;height:20px}.code-text__copy-link,.code-text__copy-confirmation{padding:4px 5px;font-size:12px;line-height:12px;font-weight:600;position:absolute;right:0;top:0}.code-text__copy-link{transition:0.2s transform ,\r\n 0.2s opacity,\r\n 0.2s color;color:#70A4FF;background-color:#E0EEFF;border-radius:4px;display:inline-block;cursor:pointer;opacity:1;transform:translate3d(0,0,0);z-index:5}.code-text__copy-link:hover{color:var(--blue)}.code-text__copy-confirmation{transition:0.2s transform ,\r\n 0.2s opacity;color:#0ec254;opacity:0;transform:translate3d(0,5px,0);z-index:1;display:flex;align-items:center;height:20px;padding:0}.code-text__copy-confirmation svg{fill:#0ec254;margin-right:-4px}.show-confirmation .code-text__copy-link{opacity:0;transform:translate3d(0,-5px,0);pointer-events:none}.show-confirmation .code-text__copy-confirmation{opacity:1;transform:translate3d(0,0,0)}";
|
9
9
|
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { c as getAssetPath, r as registerInstance, h as h$1, e as getElement, H as Host, i as createEvent, f as forceUpdate, j as readTask, w as writeTask, F as Fragment, k as getContext } from './index-c04b9ed5.js';
|
2
|
-
import { M as MoreDots, O as Outbound, D as DownArrow, a as Menu, B as BackArrow, F as ForwardArrow } from './icons-
|
2
|
+
import { M as MoreDots, O as Outbound, D as DownArrow, a as Menu, B as BackArrow, F as ForwardArrow } from './icons-1c794c74.js';
|
3
3
|
import { g as getIonMode$1, c as config } from './ionic-global-4903e23e.js';
|
4
|
-
import { h as hasShadowDom, i as inheritAriaAttributes, b as getAriaLabel, d as renderHiddenInput, e as debounceEvent, j as inheritAttributes$1, k as findItemLabel, l as raf
|
4
|
+
import { h as hasShadowDom, i as inheritAriaAttributes, b as getAriaLabel, d as renderHiddenInput, e as debounceEvent, j as inheritAttributes$1, k as findItemLabel, l as raf, a as addEventListener, r as removeEventListener, m as clamp } from './helpers-bf0e23d6.js';
|
5
5
|
import { o as openURL, c as createColorClasses$1, h as hostContext } from './theme-7ef00c83.js';
|
6
6
|
import { c as chevronForward } from './index-4044fde9.js';
|
7
7
|
import { p as printIonError, a as printIonWarning } from './index-dad75b83.js';
|
@@ -17,7 +17,7 @@ import { E as EnvironmentConfigService } from './environment-config.service-2b5d
|
|
17
17
|
import { s as sample, S as SparkleGlobal$1, d as date, M as MyHealthTemplate, a as MyHealthTemplateJSON, b as MyMoodTemplate, c as MyMoodTemplateJSON } from './util-6ef753e9.js';
|
18
18
|
import { F as FacilitatorService, f as facilitatorStore } from './facilitator.service-b0292f7f.js';
|
19
19
|
import { m as menuController } from './index-cded2d87.js';
|
20
|
-
import { m as modalController, a as alertController } from './overlays-3b4dca92.js';
|
20
|
+
import { m as modalController, a as alertController, t as toastController } from './overlays-3b4dca92.js';
|
21
21
|
import { H as HttpService } from './httpService-7b75b095.js';
|
22
22
|
import { A as AppDataService, g as goalStore, F as FeedService, f as feedStore } from './feed.service-8fbe4ce3.js';
|
23
23
|
import './localstorage.service-4bf408c8.js';
|
@@ -1255,7 +1255,7 @@ const Item = class {
|
|
1255
1255
|
}
|
1256
1256
|
}
|
1257
1257
|
componentDidLoad() {
|
1258
|
-
raf
|
1258
|
+
raf(() => {
|
1259
1259
|
this.setMultipleInputs();
|
1260
1260
|
this.focusable = this.isFocusable();
|
1261
1261
|
});
|
@@ -1322,7 +1322,7 @@ const Item = class {
|
|
1322
1322
|
input.fireFocusEvents = false;
|
1323
1323
|
input.setBlur();
|
1324
1324
|
input.setFocus();
|
1325
|
-
raf
|
1325
|
+
raf(() => {
|
1326
1326
|
input.fireFocusEvents = true;
|
1327
1327
|
});
|
1328
1328
|
}
|
@@ -16597,106 +16597,6 @@ const SparklePageFooter = class {
|
|
16597
16597
|
};
|
16598
16598
|
SparklePageFooter.style = pageFooterCss;
|
16599
16599
|
|
16600
|
-
/*!
|
16601
|
-
* (C) Ionic http://ionicframework.com - MIT License
|
16602
|
-
*/
|
16603
|
-
/**
|
16604
|
-
* Waits for a component to be ready for
|
16605
|
-
* both custom element and non-custom element builds.
|
16606
|
-
* If non-custom element build, el.componentOnReady
|
16607
|
-
* will be used.
|
16608
|
-
* For custom element builds, we wait a frame
|
16609
|
-
* so that the inner contents of the component
|
16610
|
-
* have a chance to render.
|
16611
|
-
*
|
16612
|
-
* Use this utility rather than calling
|
16613
|
-
* el.componentOnReady yourself.
|
16614
|
-
*/
|
16615
|
-
const componentOnReady = (el, callback) => {
|
16616
|
-
if (el.componentOnReady) {
|
16617
|
-
el.componentOnReady().then((resolvedEl) => callback(resolvedEl));
|
16618
|
-
}
|
16619
|
-
else {
|
16620
|
-
raf(() => callback(el));
|
16621
|
-
}
|
16622
|
-
};
|
16623
|
-
/**
|
16624
|
-
* Patched version of requestAnimationFrame that avoids ngzone
|
16625
|
-
* Use only when you know ngzone should not run
|
16626
|
-
*/
|
16627
|
-
const raf = (h) => {
|
16628
|
-
if (typeof __zone_symbol__requestAnimationFrame === 'function') {
|
16629
|
-
return __zone_symbol__requestAnimationFrame(h);
|
16630
|
-
}
|
16631
|
-
if (typeof requestAnimationFrame === 'function') {
|
16632
|
-
return requestAnimationFrame(h);
|
16633
|
-
}
|
16634
|
-
return setTimeout(h);
|
16635
|
-
};
|
16636
|
-
|
16637
|
-
/*!
|
16638
|
-
* (C) Ionic http://ionicframework.com - MIT License
|
16639
|
-
*/
|
16640
|
-
const createController = (tagName) => {
|
16641
|
-
return {
|
16642
|
-
create(options) {
|
16643
|
-
return createOverlay(tagName, options);
|
16644
|
-
},
|
16645
|
-
dismiss(data, role, id) {
|
16646
|
-
return dismissOverlay(document, data, role, tagName, id);
|
16647
|
-
},
|
16648
|
-
async getTop() {
|
16649
|
-
return getOverlay(document, tagName);
|
16650
|
-
},
|
16651
|
-
};
|
16652
|
-
};
|
16653
|
-
const toastController = /*@__PURE__*/ createController('ion-toast');
|
16654
|
-
const createOverlay = (tagName, opts) => {
|
16655
|
-
if (typeof window !== 'undefined' && typeof window.customElements !== 'undefined') {
|
16656
|
-
return window.customElements.whenDefined(tagName).then(() => {
|
16657
|
-
const element = document.createElement(tagName);
|
16658
|
-
element.classList.add('overlay-hidden');
|
16659
|
-
/**
|
16660
|
-
* Convert the passed in overlay options into props
|
16661
|
-
* that get passed down into the new overlay.
|
16662
|
-
*/
|
16663
|
-
Object.assign(element, Object.assign(Object.assign({}, opts), { hasController: true }));
|
16664
|
-
// append the overlay element to the document body
|
16665
|
-
getAppRoot(document).appendChild(element);
|
16666
|
-
return new Promise((resolve) => componentOnReady(element, resolve));
|
16667
|
-
});
|
16668
|
-
}
|
16669
|
-
return Promise.resolve();
|
16670
|
-
};
|
16671
|
-
const isOverlayHidden = (overlay) => overlay.classList.contains('overlay-hidden');
|
16672
|
-
const dismissOverlay = (doc, data, role, overlayTag, id) => {
|
16673
|
-
const overlay = getOverlay(doc, overlayTag, id);
|
16674
|
-
if (!overlay) {
|
16675
|
-
return Promise.reject('overlay does not exist');
|
16676
|
-
}
|
16677
|
-
return overlay.dismiss(data, role);
|
16678
|
-
};
|
16679
|
-
const getOverlays = (doc, selector) => {
|
16680
|
-
if (selector === undefined) {
|
16681
|
-
selector = 'ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-picker,ion-popover,ion-toast';
|
16682
|
-
}
|
16683
|
-
return Array.from(doc.querySelectorAll(selector)).filter((c) => c.overlayIndex > 0);
|
16684
|
-
};
|
16685
|
-
/**
|
16686
|
-
* Returns an overlay element
|
16687
|
-
* @param doc The document to find the element within.
|
16688
|
-
* @param overlayTag The selector for the overlay, defaults to Ionic overlay components.
|
16689
|
-
* @param id The unique identifier for the overlay instance.
|
16690
|
-
* @returns The overlay element or `undefined` if no overlay element is found.
|
16691
|
-
*/
|
16692
|
-
const getOverlay = (doc, overlayTag, id) => {
|
16693
|
-
const overlays = getOverlays(doc, overlayTag).filter((o) => !isOverlayHidden(o));
|
16694
|
-
return id === undefined ? overlays[overlays.length - 1] : overlays.find((o) => o.id === id);
|
16695
|
-
};
|
16696
|
-
const getAppRoot = (doc) => {
|
16697
|
-
return doc.querySelector('ion-app') || doc.body;
|
16698
|
-
};
|
16699
|
-
|
16700
16600
|
const paginationCss = "sparkle-pagination{border-color:var(--line-rule-color);border-style:solid;border-width:0 0 1px;display:flex;flex-wrap:wrap-reverse;padding:var(--page-padding, 2rem 0rem) 0}sparkle-pagination .next,sparkle-pagination .previous{max-width:100%;overflow:hidden}sparkle-pagination .next{margin-left:auto}sparkle-pagination a{border-radius:4px;display:flex;align-items:flex-start;flex-direction:column;padding:1em 1.5em;color:rgb(var(--accent-color-rgb))}sparkle-pagination .previous a{padding-left:0}sparkle-pagination .next a{padding-right:0;align-items:flex-end}@media (max-width: 700px){sparkle-pagination .previous a{padding-right:0.5rem}sparkle-pagination .next a{padding-left:0.5rem}}@media (hover: hover){sparkle-pagination a:hover,sparkle-pagination a:active{filter:brightness(0.8)}}sparkle-pagination .pagination__title{color:var(--text-color--lighter);font-size:12px;display:block}sparkle-pagination .pagination__text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;color:var(--ion-color-sparkle)}sparkle-pagination span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}sparkle-pagination svg{fill:currentColor;flex:none;height:1em;margin-bottom:-0.125em;width:1em}sparkle-pagination .next svg{margin-left:0.5em}sparkle-pagination .previous svg{margin-right:0.5em}.completed-toast{z-index:999999999999999999999999999 !important}";
|
16701
16601
|
|
16702
16602
|
const SparklePagination = class {
|
@@ -16708,7 +16608,7 @@ const SparklePagination = class {
|
|
16708
16608
|
console.log('showToast');
|
16709
16609
|
const toast = await toastController.create({
|
16710
16610
|
message: 'Lesson Completed.',
|
16711
|
-
duration:
|
16611
|
+
duration: 3000,
|
16712
16612
|
cssClass: "completed-toast"
|
16713
16613
|
});
|
16714
16614
|
toast.present();
|
@@ -16717,7 +16617,7 @@ const SparklePagination = class {
|
|
16717
16617
|
console.log('showToast');
|
16718
16618
|
const toast = await toastController.create({
|
16719
16619
|
message: 'Session Completed',
|
16720
|
-
duration:
|
16620
|
+
duration: 3000,
|
16721
16621
|
cssClass: "completed-toast"
|
16722
16622
|
});
|
16723
16623
|
toast.present();
|
@@ -16738,7 +16638,7 @@ const SparklePagination = class {
|
|
16738
16638
|
links.push(h$1("stencil-route-link", { onClick: () => this.presentToastLastSession(), url: nextUrl, key: "next", class: "next", anchorTitle: nextText }, h$1("div", { class: "pagination__title" }, "Next"), h$1("div", { class: "pagination__text" }, h$1("span", null, nextText), h$1(ForwardArrow, null))));
|
16739
16639
|
}
|
16740
16640
|
else {
|
16741
|
-
links.push(h$1("
|
16641
|
+
links.push(h$1("stencil-route-link", { onClick: () => this.presentToastLastSession(), url: nextUrl, key: "next", class: "next", anchorTitle: nextText }, h$1("div", { class: "pagination__title" }, "Next"), h$1("div", { class: "pagination__text" }, h$1("span", null, nextText), h$1(ForwardArrow, null))));
|
16742
16642
|
}
|
16743
16643
|
}
|
16744
16644
|
return links;
|
File without changes
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { r as registerInstance, h, H as Host, e as getElement } from './index-c04b9ed5.js';
|
2
|
-
import { C as CheckmarkSoft } from './icons-
|
2
|
+
import { C as CheckmarkSoft } from './icons-1c794c74.js';
|
3
3
|
|
4
4
|
const codeCss = "code[class*=\"language-\"],pre[class*=\"language-\"]{color:#4d4d4c;background:none;white-space:pre;word-spacing:normal;word-break:normal;word-wrap:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;-moz-hyphens:none;-ms-hyphens:none;hyphens:none}pre[class*=\"language-\"],:not(pre)>code[class*=\"language-\"]{background:hsl(30, 20%, 25%)}pre[class*=\"language-\"]{padding:1em;margin:.5em 0;overflow:auto;border:.3em solid hsl(30, 20%, 40%);border-radius:.5em;box-shadow:1px 1px .5em black inset}:not(pre)>code[class*=\"language-\"]{padding:.15em .2em .05em;border-radius:.3em;border:.13em solid hsl(30, 20%, 40%);box-shadow:1px 1px .3em -.1em black inset;white-space:normal}.token.comment,.token.prolog,.token.doctype,.token.cdata{color:#8c9296}.token.punctuation{opacity:.7}.namespace{opacity:.7}.token.tag{color:#91c5ff}.token.tag .token.tag{color:#2b90ff}.token.property,.token.attr-name,.token.boolean,.token.number,.token.constant,.token.symbol{color:#8454ff}.token.selector,.token.char,.token.function,.token.builtin,.token.inserted{color:#ff6810}.token.operator,.token.string,.token.entity,.token.url,.token.attr-value,.language-css .token.string,.style .token.string,.token.variable{color:#42b983}.token.atrule{color:#ffbb01}.token.regex,.token.keyword,.token.important{color:#f55073}.token.important,.token.bold{font-weight:bold}.token.italic{font-style:italic}.token.entity{cursor:help}.token.deleted{color:red}sparkle-code[language=\"shell\"]>pre{background-color:var(--text-color--dark);border-radius:7px}sparkle-code[language=\"shell\"]:before{display:none}sparkle-code[language=\"shell\"] code{color:rgba(255, 255, 255, 0.7);font-size:13px}sparkle-code[language=\"shell\"] .token{color:inherit}sparkle-code[language=\"shell\"] .token.prompt{color:#fb96f9;user-select:none}sparkle-code[language=\"shell\"] .token.comment{color:rgba(255, 255, 255, 0.45)}sparkle-code{display:block;position:relative}sparkle-code:before{color:#bdc5d1;content:attr(language);font-family:var(--code-font-family);font-size:10px;letter-spacing:0.05em;line-height:1;padding:0.75em;position:absolute;right:0;text-transform:uppercase;top:0}sparkle-code[language=\"shell\"] pre{white-space:pre-wrap}.code-text__copy{position:absolute;right:0;top:-1.6rem;height:20px}.code-text__copy-link,.code-text__copy-confirmation{padding:4px 5px;font-size:12px;line-height:12px;font-weight:600;position:absolute;right:0;top:0}.code-text__copy-link{transition:0.2s transform ,\r\n 0.2s opacity,\r\n 0.2s color;color:#70A4FF;background-color:#E0EEFF;border-radius:4px;display:inline-block;cursor:pointer;opacity:1;transform:translate3d(0,0,0);z-index:5}.code-text__copy-link:hover{color:var(--blue)}.code-text__copy-confirmation{transition:0.2s transform ,\r\n 0.2s opacity;color:#0ec254;opacity:0;transform:translate3d(0,5px,0);z-index:1;display:flex;align-items:center;height:20px;padding:0}.code-text__copy-confirmation svg{fill:#0ec254;margin-right:-4px}.show-confirmation .code-text__copy-link{opacity:0;transform:translate3d(0,-5px,0);pointer-events:none}.show-confirmation .code-text__copy-confirmation{opacity:1;transform:translate3d(0,0,0)}";
|
5
5
|
|
package/dist/node_modules/@sparkle-learning/components/dist/collection/components/button/button.css
ADDED
@@ -0,0 +1,49 @@
|
|
1
|
+
sparkle-button {
|
2
|
+
background-color: rgba(var(--ion-color-sparkle-rgb), var(--bg-alpha, 0.06));
|
3
|
+
border-radius: 6px;
|
4
|
+
color: var(--accent-color);
|
5
|
+
display: inline-block;
|
6
|
+
font-weight: 600;
|
7
|
+
white-space: nowrap;box-shadow: 0 1px 3px rgba(0,0,0,.1);
|
8
|
+
}
|
9
|
+
|
10
|
+
sparkle-button a,
|
11
|
+
sparkle-button button {
|
12
|
+
color: inherit;
|
13
|
+
display: inline-block;
|
14
|
+
font-size: inherit;
|
15
|
+
font-weight: inherit;
|
16
|
+
padding: 0.75em 1.5em;
|
17
|
+
}
|
18
|
+
|
19
|
+
sparkle-button button {
|
20
|
+
appearance: none;
|
21
|
+
background: none;
|
22
|
+
border: none;
|
23
|
+
line-height: inherit;
|
24
|
+
}
|
25
|
+
|
26
|
+
sparkle-button svg {
|
27
|
+
fill: currentColor;
|
28
|
+
height: 1em;
|
29
|
+
margin-bottom: -0.125em;
|
30
|
+
width: 1em;
|
31
|
+
}
|
32
|
+
|
33
|
+
sparkle-button[round] {
|
34
|
+
border-radius: 2em;
|
35
|
+
}
|
36
|
+
sparkle-button[primary] {
|
37
|
+
background-color: rgba(var(--ion-color-sparkle-rgb));
|
38
|
+
color:var(--ion-color-sparkle-contrast);
|
39
|
+
}
|
40
|
+
|
41
|
+
@media (hover: hover) {
|
42
|
+
sparkle-button:hover {
|
43
|
+
--bg-alpha: 0.08;
|
44
|
+
}
|
45
|
+
|
46
|
+
sparkle-button:active {
|
47
|
+
--bg-alpha: 0.1;
|
48
|
+
}
|
49
|
+
}
|
@@ -0,0 +1,208 @@
|
|
1
|
+
sparkle-card {
|
2
|
+
display: block;
|
3
|
+
font-size: 12px;
|
4
|
+
max-width: 30em;
|
5
|
+
}
|
6
|
+
|
7
|
+
.Card {
|
8
|
+
background-color: var(--background);
|
9
|
+
border-radius: 4px;
|
10
|
+
box-shadow: 0px 0.175em 0.5em rgba(2, 8, 20, 0.1), 0px 0.085em 0.175em rgba(2, 8, 20, 0.08);
|
11
|
+
color: var(--text-color--light);
|
12
|
+
display: flex;
|
13
|
+
flex-direction: column;
|
14
|
+
font-size: inherit;
|
15
|
+
font-weight: normal;
|
16
|
+
height: 100%;
|
17
|
+
justify-content: flex-start;
|
18
|
+
line-height: 1.6;
|
19
|
+
transition: box-shadow 150ms ease, transform 150ms ease;
|
20
|
+
width: 100%;
|
21
|
+
overflow: hidden;
|
22
|
+
}
|
23
|
+
|
24
|
+
.Card-with-image {
|
25
|
+
grid-row: span 2;
|
26
|
+
}
|
27
|
+
|
28
|
+
.Card-without-image {
|
29
|
+
font-size: 12px;
|
30
|
+
}
|
31
|
+
|
32
|
+
.Card-container {
|
33
|
+
padding: 1.65em 2em 1.65em;
|
34
|
+
}
|
35
|
+
|
36
|
+
.Card-image {
|
37
|
+
width: 100%;
|
38
|
+
height: auto;
|
39
|
+
}
|
40
|
+
|
41
|
+
.Card-icon,
|
42
|
+
.Card-iconset__container {
|
43
|
+
width: 48px;
|
44
|
+
height: 48px;
|
45
|
+
|
46
|
+
margin-bottom: 1.2em;
|
47
|
+
|
48
|
+
border-radius: 50%;
|
49
|
+
object-fit: cover;
|
50
|
+
background: rgb(246, 248, 251);
|
51
|
+
}
|
52
|
+
|
53
|
+
.Card-icon-hover {
|
54
|
+
display: none;
|
55
|
+
}
|
56
|
+
|
57
|
+
.Card-iconset__container {
|
58
|
+
position: relative;
|
59
|
+
}
|
60
|
+
|
61
|
+
.Card-iconset__container .Card-icon {
|
62
|
+
position: absolute;
|
63
|
+
opacity: 0;
|
64
|
+
transition: 0.8s opacity;
|
65
|
+
}
|
66
|
+
|
67
|
+
.Card-iconset__container .Card-icon--active {
|
68
|
+
opacity: 1;
|
69
|
+
}
|
70
|
+
|
71
|
+
.Card-ionicon {
|
72
|
+
width: 48px;
|
73
|
+
height: 48px;
|
74
|
+
float: left;
|
75
|
+
margin-right: 1em;
|
76
|
+
}
|
77
|
+
|
78
|
+
@media (hover: hover) {
|
79
|
+
.Card[href]:hover {
|
80
|
+
box-shadow: 0 0.35em 1.175em rgba(2, 8, 20, 0.1), 0 0.175em 0.5em rgba(2, 8, 20, 0.08);
|
81
|
+
transform: translateY(-1px);
|
82
|
+
}
|
83
|
+
|
84
|
+
.Card[href]:hover .Card-icon-default {
|
85
|
+
display: none;
|
86
|
+
}
|
87
|
+
|
88
|
+
.Card[href]:hover .Card-icon-hover {
|
89
|
+
display: block;
|
90
|
+
}
|
91
|
+
}
|
92
|
+
|
93
|
+
.Card-content > *:first-child {
|
94
|
+
margin-top: 0;
|
95
|
+
}
|
96
|
+
|
97
|
+
.Card-content > *:last-child {
|
98
|
+
margin-bottom: 0;
|
99
|
+
}
|
100
|
+
|
101
|
+
.Card-content > * {
|
102
|
+
margin: 0 0 0.65em;
|
103
|
+
}
|
104
|
+
|
105
|
+
.Card-header {
|
106
|
+
color: var(--text-color--dark);
|
107
|
+
font-size: 1.4em;
|
108
|
+
font-weight: 500;
|
109
|
+
line-height: 1.4;
|
110
|
+
margin-bottom: 0.45em;
|
111
|
+
}
|
112
|
+
|
113
|
+
.Card-without-image .Card-header {
|
114
|
+
margin-bottom: 0.3em;
|
115
|
+
}
|
116
|
+
|
117
|
+
.Card-header > svg {
|
118
|
+
fill: currentColor;
|
119
|
+
height: 1em;
|
120
|
+
margin-bottom: -0.125em;
|
121
|
+
width: auto;
|
122
|
+
}
|
123
|
+
|
124
|
+
.Card-size-lg {
|
125
|
+
font-size: 14px;
|
126
|
+
}
|
127
|
+
|
128
|
+
.Card-size-lg .Card-icon,
|
129
|
+
.Card-size-lg .Card-ionicon,
|
130
|
+
.Card-size-lg .Card-iconset__container {
|
131
|
+
width: 80px;
|
132
|
+
height: 80px;
|
133
|
+
}
|
134
|
+
|
135
|
+
.Card-size-lg.Card-without-image .Card-header {
|
136
|
+
font-size: 20px;
|
137
|
+
}
|
138
|
+
|
139
|
+
sparkle-card.disabled,
|
140
|
+
sparkle-card[disabled] {
|
141
|
+
position: relative;
|
142
|
+
}
|
143
|
+
|
144
|
+
sparkle-card.disabled::after,
|
145
|
+
sparkle-card[disabled]::after {
|
146
|
+
position: absolute;
|
147
|
+
top: 0;
|
148
|
+
right: 0;
|
149
|
+
left: 0;
|
150
|
+
bottom: 0;
|
151
|
+
background: rgba(232, 232, 232, 0.5);
|
152
|
+
pointer-events: none;
|
153
|
+
content: '';
|
154
|
+
}
|
155
|
+
|
156
|
+
aside sparkle-card {
|
157
|
+
max-width: 240px;
|
158
|
+
}
|
159
|
+
|
160
|
+
aside .Card-container {
|
161
|
+
display: grid;
|
162
|
+
grid-template-columns: minmax(0, max-content) 1fr;
|
163
|
+
grid-template-rows: minmax(0, min-content);
|
164
|
+
grid-template-areas:
|
165
|
+
'icon title'
|
166
|
+
'icon body';
|
167
|
+
}
|
168
|
+
|
169
|
+
aside .Card-icon {
|
170
|
+
width: 32px;
|
171
|
+
height: 32px;
|
172
|
+
margin-right: 16px;
|
173
|
+
margin-bottom: 0;
|
174
|
+
grid-area: icon;
|
175
|
+
}
|
176
|
+
|
177
|
+
aside .Card-header {
|
178
|
+
grid-area: title;
|
179
|
+
}
|
180
|
+
|
181
|
+
aside .Card-header::after {
|
182
|
+
background-image: url('/docs/assets/img/new-tab.svg');
|
183
|
+
display: inline-block;
|
184
|
+
height: 13px;
|
185
|
+
width: 13px;
|
186
|
+
background-size: 13px 13px;
|
187
|
+
margin-left: 4px;
|
188
|
+
content: '';
|
189
|
+
}
|
190
|
+
|
191
|
+
aside .Card-content {
|
192
|
+
grid-area: body;
|
193
|
+
/* https://stackoverflow.com/questions/5269713/css-ellipsis-on-second-line */
|
194
|
+
max-height: 42px;
|
195
|
+
overflow: hidden;
|
196
|
+
text-overflow: ellipsis;
|
197
|
+
display: -webkit-box;
|
198
|
+
-webkit-line-clamp: 2;
|
199
|
+
-webkit-box-orient: vertical;
|
200
|
+
}
|
201
|
+
|
202
|
+
aside .Card-icon + .Card-content {
|
203
|
+
margin-top: -6px;
|
204
|
+
}
|
205
|
+
|
206
|
+
.markdown-content p sparkle-card {
|
207
|
+
margin-top: 1em;
|
208
|
+
}
|
package/dist/node_modules/@sparkle-learning/components/dist/collection/components/cards/cards.css
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
sparkle-cards {
|
2
|
+
display: grid;
|
3
|
+
font-size: 12px;
|
4
|
+
grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
|
5
|
+
grid-gap: 1.35rem;
|
6
|
+
}
|
7
|
+
|
8
|
+
sparkle-cards > sparkle-card {
|
9
|
+
font-size: inherit;
|
10
|
+
max-width: none;
|
11
|
+
}
|
12
|
+
|
13
|
+
sparkle-cards > sparkle-card.tall {
|
14
|
+
grid-row: span 2;
|
15
|
+
}
|
16
|
+
|
17
|
+
sparkle-cards > sparkle-card.wide {
|
18
|
+
grid-column: span 2;
|
19
|
+
}
|
20
|
+
|
21
|
+
sparkle-cards.prioritized > sparkle-card:nth-child(-n + 5) {
|
22
|
+
font-size: 1.25em;
|
23
|
+
}
|
24
|
+
|
25
|
+
sparkle-cards.prioritized > sparkle-card:first-child {
|
26
|
+
grid-row: span 2;
|
27
|
+
}
|
28
|
+
|
29
|
+
sparkle-cards.max-measure > sparkle-card {
|
30
|
+
max-width: 50%;
|
31
|
+
}
|