@better-translate/react 1.0.1 → 2.0.0

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/index.js CHANGED
@@ -81,6 +81,9 @@ function BetterTranslateProvider({
81
81
  }
82
82
  const translate = ((...args) => {
83
83
  const [key, options] = args;
84
+ if (options?.bt === true) {
85
+ return key;
86
+ }
84
87
  return translator.t(
85
88
  key,
86
89
  {
@@ -1 +1 @@
1
- {"version":3,"file":"provider.d.ts","sourceRoot":"","sources":["../src/provider.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,4BAA4B,EAC5B,4BAA4B,EAI7B,MAAM,YAAY,CAAC;AAOpB;;;;;GAKG;AACH,wBAAgB,uBAAuB,CACrC,WAAW,SAAS,4BAA4B,EAChD,EACA,QAAQ,EACR,aAAa,EACb,UAAU,GACX,EAAE,4BAA4B,CAAC,WAAW,CAAC,2CAsI3C"}
1
+ {"version":3,"file":"provider.d.ts","sourceRoot":"","sources":["../src/provider.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,4BAA4B,EAC5B,4BAA4B,EAI7B,MAAM,YAAY,CAAC;AAOpB;;;;;GAKG;AACH,wBAAgB,uBAAuB,CACrC,WAAW,SAAS,4BAA4B,EAChD,EACA,QAAQ,EACR,aAAa,EACb,UAAU,GACX,EAAE,4BAA4B,CAAC,WAAW,CAAC,2CA6I3C"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@better-translate/react",
3
- "version": "1.0.1",
3
+ "version": "2.0.0",
4
4
  "description": "React context and hooks for Better Translate in web and native React apps.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -15,7 +15,11 @@
15
15
  },
16
16
  "./package.json": "./package.json"
17
17
  },
18
- "files": ["dist", "LICENSE", "README.md"],
18
+ "files": [
19
+ "dist",
20
+ "LICENSE",
21
+ "README.md"
22
+ ],
19
23
  "scripts": {
20
24
  "build": "tsup src/index.ts --format esm --clean && tsc -p tsconfig.build.json",
21
25
  "check-types": "tsc --noEmit",
@@ -35,7 +39,7 @@
35
39
  "url": "https://github.com/jralvarenga/better-translate/issues"
36
40
  },
37
41
  "dependencies": {
38
- "@better-translate/core": "^1.0.0"
42
+ "@better-translate/core": "^2.0.0"
39
43
  },
40
44
  "peerDependencies": {
41
45
  "react": "^19.0.0"