@things-factory/i18n-base 8.0.8 → 8.0.15

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@things-factory/i18n-base",
3
- "version": "8.0.8",
3
+ "version": "8.0.15",
4
4
  "main": "dist-server/index.js",
5
5
  "browser": "dist-client/index.js",
6
6
  "things-factory": true,
@@ -28,8 +28,8 @@
28
28
  },
29
29
  "dependencies": {
30
30
  "@operato/i18n": "^8.0.0",
31
- "@things-factory/auth-base": "^8.0.8",
32
- "@things-factory/shell": "^8.0.8"
31
+ "@things-factory/auth-base": "^8.0.15",
32
+ "@things-factory/shell": "^8.0.15"
33
33
  },
34
- "gitHead": "2f53ec5833616a278c1f5fc057a5ce50f309cebd"
34
+ "gitHead": "214b341ededb4ecb5ef4401149d53899fe67af44"
35
35
  }
package/server/routes.ts CHANGED
@@ -1,5 +1,6 @@
1
1
  import i18next from 'i18next'
2
2
  import { config } from '@things-factory/env'
3
+ import { getRoutePrefixForDomainType } from '@things-factory/shell'
3
4
 
4
5
  const disableCustomTerminologyFeature = config.get('i18n/disableCustomTerminologyFeature')
5
6
  const isPathBaseDomain = !config.get('subdomain')
@@ -24,7 +25,11 @@ process.on('bootstrap-module-global-public-route' as any, (app, globalPublicRout
24
25
 
25
26
  process.on('bootstrap-module-domain-public-route' as any, (app, domainPublicRouter) => {
26
27
  if (isPathBaseDomain) {
27
- domainPublicRouter.use('/domain/:subdomain', translationsRouter.routes(), translationsRouter.allowedMethods())
28
+ domainPublicRouter.use(
29
+ `/${getRoutePrefixForDomainType()}/:subdomain`,
30
+ translationsRouter.routes(),
31
+ translationsRouter.allowedMethods()
32
+ )
28
33
  } else if (!disableCustomTerminologyFeature) {
29
34
  domainPublicRouter.use('', translationsRouter.routes(), translationsRouter.allowedMethods())
30
35
  }