@c15t/backend 1.3.1 → 1.4.1

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.
@@ -1,15 +1,15 @@
1
1
 
2
- > @c15t/backend@1.3.1 build /home/runner/work/c15t/c15t/packages/backend
2
+ > @c15t/backend@1.4.1 build /home/runner/work/c15t/c15t/packages/backend
3
3
  > rslib build
4
4
 
5
5
  Rslib v0.6.2
6
6
 
7
- ready built in 0.65 s (esm)
8
- ready built in 0.65 s (cjs)
7
+ ready built in 0.70 s (esm)
8
+ ready built in 0.69 s (cjs)
9
9
  start generating declaration files... (esm)
10
10
  start generating declaration files... (cjs)
11
- ready declaration files generated in 9.69 s (esm)
12
- ready declaration files generated in 9.73 s (cjs)
11
+ ready declaration files generated in 8.57 s (esm)
12
+ ready declaration files generated in 8.63 s (cjs)
13
13
 
14
14
   File (esm) Size 
15
15
  dist/pkgs/types/index.js 0.00 kB
@@ -19,16 +19,16 @@ ready declaration files generated in 9.73 s (cjs)
19
19
  dist/pkgs/db-adapters/adapters/memory-adapter/index.js 44.3 kB
20
20
  dist/pkgs/db-adapters/adapters/prisma-adapter/index.js 47.5 kB
21
21
  dist/pkgs/db-adapters/adapters/drizzle-adapter/index.js 50.0 kB
22
- dist/router.js 50.3 kB
22
+ dist/router.js 50.4 kB
23
23
  dist/pkgs/migrations/index.js 50.7 kB
24
24
  dist/pkgs/db-adapters/adapters/kysely-adapter/index.js 55.3 kB
25
25
  dist/pkgs/data-model/schema/index.js 60.9 kB
26
26
  dist/schema/index.js 61.2 kB
27
27
  dist/pkgs/data-model/index.js 61.8 kB
28
28
  dist/pkgs/db-adapters/index.js 89.6 kB
29
- dist/core.js 155.1 kB
29
+ dist/core.js 155.2 kB
30
30
 
31
- Total: 779.9 kB
31
+ Total: 780.1 kB
32
32
 
33
33
   -----
34
34
 
@@ -39,7 +39,7 @@ ready declaration files generated in 9.73 s (cjs)
39
39
  dist/contracts.cjs 31.7 kB
40
40
  dist/pkgs/db-adapters/adapters/memory-adapter/index.cjs 45.3 kB
41
41
  dist/pkgs/db-adapters/adapters/prisma-adapter/index.cjs 48.4 kB
42
- dist/router.cjs 50.1 kB
42
+ dist/router.cjs 50.2 kB
43
43
  dist/pkgs/db-adapters/adapters/drizzle-adapter/index.cjs 50.7 kB
44
44
  dist/pkgs/migrations/index.cjs 52.3 kB
45
45
  dist/pkgs/db-adapters/adapters/kysely-adapter/index.cjs 56.3 kB
@@ -47,7 +47,7 @@ ready declaration files generated in 9.73 s (cjs)
47
47
  dist/schema/index.cjs 64.5 kB
48
48
  dist/pkgs/data-model/index.cjs 66.0 kB
49
49
  dist/pkgs/db-adapters/index.cjs 90.8 kB
50
- dist/core.cjs 154.0 kB
50
+ dist/core.cjs 154.1 kB
51
51
 
52
- Total: 800.5 kB
52
+ Total: 800.7 kB
53
53
 
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @c15t/backend
2
2
 
3
+ ## 1.4.1
4
+
5
+ ### Patch Changes
6
+
7
+ - 8afd304: fix(backend): add custom c15t headers to override providers
8
+
3
9
  ## 1.3.1
4
10
 
5
11
  ### Patch Changes
package/dist/core.cjs CHANGED
@@ -2234,7 +2234,7 @@ function getBaseURL(url, path) {
2234
2234
  if (fromEnv) return withPath(fromEnv, path);
2235
2235
  }
2236
2236
  var package_namespaceObject = {
2237
- i8: "1.3.1"
2237
+ i8: "1.4.1"
2238
2238
  };
2239
2239
  const createRegistry = (ctx)=>({
2240
2240
  ...auditLogRegistry(ctx),
@@ -3095,8 +3095,8 @@ const show_banner_handler_showConsentBanner = os.consent.showBanner.handler(({ c
3095
3095
  if (!value) return null;
3096
3096
  return Array.isArray(value) ? value[0] ?? null : value;
3097
3097
  };
3098
- const countryCode = normalizeHeader(headers.get('cf-ipcountry')) ?? normalizeHeader(headers.get('x-vercel-ip-country')) ?? normalizeHeader(headers.get('x-amz-cf-ipcountry')) ?? normalizeHeader(headers.get('x-country-code'));
3099
- const regionCode = normalizeHeader(headers.get('x-vercel-ip-country-region')) ?? normalizeHeader(headers.get('x-region-code'));
3098
+ const countryCode = normalizeHeader(headers.get('x-c15t-country')) ?? normalizeHeader(headers.get('cf-ipcountry')) ?? normalizeHeader(headers.get('x-vercel-ip-country')) ?? normalizeHeader(headers.get('x-amz-cf-ipcountry')) ?? normalizeHeader(headers.get('x-country-code'));
3099
+ const regionCode = normalizeHeader(headers.get('x-c15t-region')) ?? normalizeHeader(headers.get('x-vercel-ip-country-region')) ?? normalizeHeader(headers.get('x-region-code'));
3100
3100
  const acceptLanguage = normalizeHeader(headers.get('accept-language'));
3101
3101
  const preferredLanguage = getPreferredLanguage(acceptLanguage);
3102
3102
  const { showConsentBanner, jurisdictionCode, message } = checkJurisdiction(countryCode);
package/dist/core.js CHANGED
@@ -2199,7 +2199,7 @@ function getBaseURL(url, path) {
2199
2199
  if (fromEnv) return withPath(fromEnv, path);
2200
2200
  }
2201
2201
  var package_namespaceObject = {
2202
- i8: "1.3.1"
2202
+ i8: "1.4.1"
2203
2203
  };
2204
2204
  const createRegistry = (ctx)=>({
2205
2205
  ...auditLogRegistry(ctx),
@@ -3056,8 +3056,8 @@ const show_banner_handler_showConsentBanner = os.consent.showBanner.handler(({ c
3056
3056
  if (!value) return null;
3057
3057
  return Array.isArray(value) ? value[0] ?? null : value;
3058
3058
  };
3059
- const countryCode = normalizeHeader(headers.get('cf-ipcountry')) ?? normalizeHeader(headers.get('x-vercel-ip-country')) ?? normalizeHeader(headers.get('x-amz-cf-ipcountry')) ?? normalizeHeader(headers.get('x-country-code'));
3060
- const regionCode = normalizeHeader(headers.get('x-vercel-ip-country-region')) ?? normalizeHeader(headers.get('x-region-code'));
3059
+ const countryCode = normalizeHeader(headers.get('x-c15t-country')) ?? normalizeHeader(headers.get('cf-ipcountry')) ?? normalizeHeader(headers.get('x-vercel-ip-country')) ?? normalizeHeader(headers.get('x-amz-cf-ipcountry')) ?? normalizeHeader(headers.get('x-country-code'));
3060
+ const regionCode = normalizeHeader(headers.get('x-c15t-region')) ?? normalizeHeader(headers.get('x-vercel-ip-country-region')) ?? normalizeHeader(headers.get('x-region-code'));
3061
3061
  const acceptLanguage = normalizeHeader(headers.get('accept-language'));
3062
3062
  const preferredLanguage = getPreferredLanguage(acceptLanguage);
3063
3063
  const { showConsentBanner, jurisdictionCode, message } = checkJurisdiction(countryCode);
@@ -1 +1 @@
1
- {"version":3,"file":"show-banner.handler.d.ts","sourceRoot":"","sources":["../../../src/handlers/consent/show-banner.handler.ts"],"names":[],"mappings":"AAqCA;;;GAGG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+CAyD7B,CAAC;AAEF;;;GAGG;AACH,wBAAgB,iBAAiB,CAAC,WAAW,EAAE,MAAM,GAAG,IAAI;;;;EAmF3D"}
1
+ {"version":3,"file":"show-banner.handler.d.ts","sourceRoot":"","sources":["../../../src/handlers/consent/show-banner.handler.ts"],"names":[],"mappings":"AAqCA;;;GAGG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+CA2D7B,CAAC;AAEF;;;GAGG;AACH,wBAAgB,iBAAiB,CAAC,WAAW,EAAE,MAAM,GAAG,IAAI;;;;EAmF3D"}
package/dist/router.cjs CHANGED
@@ -911,8 +911,8 @@ const show_banner_handler_showConsentBanner = os.consent.showBanner.handler(({ c
911
911
  if (!value) return null;
912
912
  return Array.isArray(value) ? value[0] ?? null : value;
913
913
  };
914
- const countryCode = normalizeHeader(headers.get('cf-ipcountry')) ?? normalizeHeader(headers.get('x-vercel-ip-country')) ?? normalizeHeader(headers.get('x-amz-cf-ipcountry')) ?? normalizeHeader(headers.get('x-country-code'));
915
- const regionCode = normalizeHeader(headers.get('x-vercel-ip-country-region')) ?? normalizeHeader(headers.get('x-region-code'));
914
+ const countryCode = normalizeHeader(headers.get('x-c15t-country')) ?? normalizeHeader(headers.get('cf-ipcountry')) ?? normalizeHeader(headers.get('x-vercel-ip-country')) ?? normalizeHeader(headers.get('x-amz-cf-ipcountry')) ?? normalizeHeader(headers.get('x-country-code'));
915
+ const regionCode = normalizeHeader(headers.get('x-c15t-region')) ?? normalizeHeader(headers.get('x-vercel-ip-country-region')) ?? normalizeHeader(headers.get('x-region-code'));
916
916
  const acceptLanguage = normalizeHeader(headers.get('accept-language'));
917
917
  const preferredLanguage = getPreferredLanguage(acceptLanguage);
918
918
  const { showConsentBanner, jurisdictionCode, message } = checkJurisdiction(countryCode);
@@ -1208,7 +1208,7 @@ const consentHandlers = {
1208
1208
  verify: verifyConsent
1209
1209
  };
1210
1210
  var package_namespaceObject = {
1211
- i8: "1.3.1"
1211
+ i8: "1.4.1"
1212
1212
  };
1213
1213
  const statusHandler = os.meta.status.handler(({ context })=>{
1214
1214
  const typedContext = context;
package/dist/router.js CHANGED
@@ -873,8 +873,8 @@ const show_banner_handler_showConsentBanner = os.consent.showBanner.handler(({ c
873
873
  if (!value) return null;
874
874
  return Array.isArray(value) ? value[0] ?? null : value;
875
875
  };
876
- const countryCode = normalizeHeader(headers.get('cf-ipcountry')) ?? normalizeHeader(headers.get('x-vercel-ip-country')) ?? normalizeHeader(headers.get('x-amz-cf-ipcountry')) ?? normalizeHeader(headers.get('x-country-code'));
877
- const regionCode = normalizeHeader(headers.get('x-vercel-ip-country-region')) ?? normalizeHeader(headers.get('x-region-code'));
876
+ const countryCode = normalizeHeader(headers.get('x-c15t-country')) ?? normalizeHeader(headers.get('cf-ipcountry')) ?? normalizeHeader(headers.get('x-vercel-ip-country')) ?? normalizeHeader(headers.get('x-amz-cf-ipcountry')) ?? normalizeHeader(headers.get('x-country-code'));
877
+ const regionCode = normalizeHeader(headers.get('x-c15t-region')) ?? normalizeHeader(headers.get('x-vercel-ip-country-region')) ?? normalizeHeader(headers.get('x-region-code'));
878
878
  const acceptLanguage = normalizeHeader(headers.get('accept-language'));
879
879
  const preferredLanguage = getPreferredLanguage(acceptLanguage);
880
880
  const { showConsentBanner, jurisdictionCode, message } = checkJurisdiction(countryCode);
@@ -1170,7 +1170,7 @@ const consentHandlers = {
1170
1170
  verify: verifyConsent
1171
1171
  };
1172
1172
  var package_namespaceObject = {
1173
- i8: "1.3.1"
1173
+ i8: "1.4.1"
1174
1174
  };
1175
1175
  const statusHandler = os.meta.status.handler(({ context })=>{
1176
1176
  const typedContext = context;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@c15t/backend",
3
- "version": "1.3.1",
3
+ "version": "1.4.1",
4
4
  "license": "GPL-3.0-only",
5
5
  "type": "module",
6
6
  "exports": {
@@ -65,12 +65,14 @@ export const showConsentBanner = os.consent.showBanner.handler(
65
65
  };
66
66
 
67
67
  const countryCode =
68
+ normalizeHeader(headers.get('x-c15t-country')) ??
68
69
  normalizeHeader(headers.get('cf-ipcountry')) ??
69
70
  normalizeHeader(headers.get('x-vercel-ip-country')) ??
70
71
  normalizeHeader(headers.get('x-amz-cf-ipcountry')) ??
71
72
  normalizeHeader(headers.get('x-country-code'));
72
73
 
73
74
  const regionCode =
75
+ normalizeHeader(headers.get('x-c15t-region')) ??
74
76
  normalizeHeader(headers.get('x-vercel-ip-country-region')) ??
75
77
  normalizeHeader(headers.get('x-region-code'));
76
78