roboto-js 1.6.2 → 1.6.3

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.
@@ -89,7 +89,8 @@ var Roboto = exports["default"] = /*#__PURE__*/function () {
89
89
  }, {
90
90
  key: "getSiteEnv",
91
91
  value: function getSiteEnv() {
92
- return this.api.getSiteEnv();
92
+ var key = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
93
+ return this.api.getSiteEnv(key);
93
94
  }
94
95
  }, {
95
96
  key: "setAppServiceHost",
@@ -173,6 +173,10 @@ var RbtApi = exports["default"] = /*#__PURE__*/function () {
173
173
  }, {
174
174
  key: "getSiteEnv",
175
175
  value: function getSiteEnv() {
176
+ var key = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
177
+ if (key) {
178
+ return this.siteEnv[key];
179
+ }
176
180
  return this.siteEnv;
177
181
  }
178
182
  }, {
package/dist/esm/index.js CHANGED
@@ -53,8 +53,8 @@ export default class Roboto {
53
53
  setSiteEnv(siteEnv) {
54
54
  this.api.setSiteEnv(siteEnv);
55
55
  }
56
- getSiteEnv() {
57
- return this.api.getSiteEnv();
56
+ getSiteEnv(key = null) {
57
+ return this.api.getSiteEnv(key);
58
58
  }
59
59
  setAppServiceHost(host) {
60
60
  // DEVELOPMENT
@@ -75,7 +75,10 @@ export default class RbtApi {
75
75
  setSiteEnv(siteEnv) {
76
76
  this.siteEnv = siteEnv;
77
77
  }
78
- getSiteEnv() {
78
+ getSiteEnv(key = null) {
79
+ if (key) {
80
+ return this.siteEnv[key];
81
+ }
79
82
  return this.siteEnv;
80
83
  }
81
84
  async registerTypedefs(typedefs) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "roboto-js",
3
- "version": "1.6.2",
3
+ "version": "1.6.3",
4
4
  "type": "module",
5
5
  "description": "",
6
6
  "main": "dist/cjs/index.cjs",
package/src/index.js CHANGED
@@ -64,8 +64,8 @@ export default class Roboto{
64
64
  }
65
65
 
66
66
 
67
- getSiteEnv(){
68
- return this.api.getSiteEnv();
67
+ getSiteEnv(key=null){
68
+ return this.api.getSiteEnv(key);
69
69
  }
70
70
 
71
71
  setAppServiceHost(host){
package/src/rbt_api.js CHANGED
@@ -90,7 +90,11 @@ export default class RbtApi {
90
90
 
91
91
  }
92
92
 
93
- getSiteEnv(){
93
+ getSiteEnv(key=null){
94
+
95
+ if(key){
96
+ return this.siteEnv[key];
97
+ }
94
98
 
95
99
  return this.siteEnv;
96
100