@symbo.ls/router 2.11.35 → 2.11.39

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.
Files changed (2) hide show
  1. package/index.js +3 -2
  2. package/package.json +2 -2
package/index.js CHANGED
@@ -2,7 +2,6 @@
2
2
 
3
3
  import { setCookie } from '@domql/cookie'
4
4
  import { redirectBasedOnAuth } from '@symbo.ls/auth-redirect'
5
- import { findModal } from '@symbo.ls/modals/action'
6
5
 
7
6
  export const getActiveRoute = (level = 0, route = window.location.pathname) => {
8
7
  const routeArray = route.split('/')
@@ -53,7 +52,9 @@ export const router = (
53
52
 
54
53
  const content = element.routes[routeInContent] || element.routes['/*']
55
54
 
56
- const isModal = (findModal(element, element.state) || {}).FoundModal
55
+ const { context } = element
56
+ const { components } = context
57
+ const isModal = components.findModal && (components.findModal(element, element.state) || {}).FoundModal
57
58
  const isInitial = options.initialRender
58
59
  const hashChanged = hash && hash !== window.location.hash.slice(1)
59
60
  const pathChanged = pathname !== lastPathname
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@symbo.ls/router",
3
- "version": "2.11.35",
3
+ "version": "2.11.39",
4
4
  "main": "index.js",
5
5
  "license": "MIT",
6
6
  "scripts": {
@@ -11,6 +11,6 @@
11
11
  "@domql/utils": "latest",
12
12
  "@symbo.ls/auth-redirect": "latest"
13
13
  },
14
- "gitHead": "9833e01499952b3973fb9b67ec917bac5fea42f8",
14
+ "gitHead": "5d63aa30de065dfe82d7924573b5e19de10fd895",
15
15
  "source": "index.js"
16
16
  }