How to use the @lrnwebcomponents/haxcms-elements/lib/core/haxcms-site-store.js.store.location function in @lrnwebcomponents/haxcms-elements

To help you get started, we’ve selected a few @lrnwebcomponents/haxcms-elements examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github elmsln / lrnwebcomponents / elements / haxor-slevin / haxor-slevin.js View on Github external
_goBack(e) {
    window.history.pushState(null, null, store.location.baseUrl);
    window.dispatchEvent(new PopStateEvent("popstate"));
    // should help account for starting on a page where popstate isn't set
    // and also generate data model mirroring
    window.scrollTo({
      top: 0,
      left: 0
    });
    const evt = new CustomEvent("json-outline-schema-active-item-changed", {
      bubbles: true,
      cancelable: true,
      composed: true,
      detail: {}
    });
    this.dispatchEvent(evt);
    this.selectedPage = 0;
  }
github elmsln / lrnwebcomponents / elements / simple-blog / simple-blog.js View on Github external
_goBack(e) {
    const prevActiveItemId = store.activeId;
    window.history.pushState(null, null, store.location.baseUrl);
    window.dispatchEvent(new PopStateEvent("popstate"));
    // should help account for starting on a page where popstate isn't set
    // and also generate data model mirroring
    if (prevActiveItemId) {
      setTimeout(() => {
        let active = this.shadowRoot
          .querySelector("simple-blog-listing")
          .shadowRoot.querySelector(
            'simple-blog-overview[item-id="' + prevActiveItemId + '"]'
          );
        if (active) {
          active.scrollIntoView(true);
          active.focus();
        }
      }, 100);
    } else {
github elmsln / lrnwebcomponents / elements / haxor-slevin / haxor-slevin.es6.js View on Github external
_goBack(e) {
    window.history.pushState(null, null, store.location.baseUrl);
    window.dispatchEvent(new PopStateEvent("popstate"));
    // should help account for starting on a page where popstate isn't set
    // and also generate data model mirroring
    window.scrollTo({
      top: 0,
      left: 0
    });
    const evt = new CustomEvent("json-outline-schema-active-item-changed", {
      bubbles: true,
      cancelable: true,
      composed: true,
      detail: {}
    });
    this.dispatchEvent(evt);
    this.selectedPage = 0;
  }
github elmsln / lrnwebcomponents / elements / haxor-slevin / src / haxor-slevin.js View on Github external
_goBack(e) {
    window.history.pushState(null, null, store.location.baseUrl);
    window.dispatchEvent(new PopStateEvent("popstate"));
    // should help account for starting on a page where popstate isn't set
    // and also generate data model mirroring
    window.scrollTo({
      top: 0,
      left: 0
    });
    const evt = new CustomEvent("json-outline-schema-active-item-changed", {
      bubbles: true,
      cancelable: true,
      composed: true,
      detail: {}
    });
    this.dispatchEvent(evt);
    this.selectedPage = 0;
  }
github elmsln / lrnwebcomponents / elements / haxor-slevin / haxor-slevin.js View on Github external
autorun(reaction => {
      let location = toJS(store.location);
      this._noticeLocationChange(location);
      this.__disposer.push(reaction);
    });
    autorun(reaction => {
github elmsln / lrnwebcomponents / elements / haxor-slevin / src / haxor-slevin.js View on Github external
autorun(reaction => {
      let location = toJS(store.location);
      this._noticeLocationChange(location);
      this.__disposer.push(reaction);
    });
    autorun(reaction => {
github elmsln / lrnwebcomponents / elements / haxor-slevin / haxor-slevin.es6.js View on Github external
autorun(reaction => {
      let location = toJS(store.location);
      this._noticeLocationChange(location);
      this.__disposer.push(reaction);
    });
    autorun(reaction => {
github elmsln / lrnwebcomponents / elements / simple-blog / lib / simple-blog-footer.js View on Github external
_backButtonTap(e) {
    window.history.pushState(null, null, store.location.baseUrl);
    window.dispatchEvent(new PopStateEvent("popstate"));
  }
}
github elmsln / lrnwebcomponents / elements / haxcms-elements / lib / core / HAXCMSThemeWiring.js View on Github external
autorun(reaction => {
        this._location = toJS(store.location);
        this.__disposer.push(reaction);
      });
    }

@lrnwebcomponents/haxcms-elements

HAX CMS series of elements to provide a full on CMS

Apache-2.0
Latest version published 10 months ago

Package Health Score

66 / 100
Full package analysis

Popular @lrnwebcomponents/haxcms-elements functions