@smartico/public-api 0.0.242 → 0.0.243
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/Jackpots/JackpotPublicMeta.d.ts +5 -1
- package/dist/Level/LevelPublicMeta.d.ts +5 -1
- package/dist/Raffle/Raffle.d.ts +5 -1
- package/dist/SmarticoLib/index.d.ts +5 -1
- package/dist/WSAPI/WSAPITypes.d.ts +5 -1
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +4 -1
- package/dist/index.modern.mjs.map +1 -1
- package/package.json +1 -1
- package/src/IntUtils.ts +1 -1
- package/src/Jackpots/JackpotPublicMeta.ts +5 -1
- package/src/Level/LevelPublicMeta.ts +5 -1
- package/src/Raffle/Raffle.ts +5 -1
- package/src/SmarticoLib/index.ts +5 -1
- package/src/WSAPI/WSAPI.ts +5 -0
- package/src/WSAPI/WSAPITypes.ts +5 -1
|
@@ -14,7 +14,11 @@ interface JackpotPublicMeta {
|
|
|
14
14
|
placeholder1: string;
|
|
15
15
|
/** custom value of placeholder2 defined by operator and can be used in the HTML templates */
|
|
16
16
|
placeholder2: string;
|
|
17
|
-
/**
|
|
17
|
+
/**
|
|
18
|
+
* Custom data as string or JSON string that can be used in API to build custom UI
|
|
19
|
+
* You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
|
|
20
|
+
* Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
|
|
21
|
+
*/
|
|
18
22
|
custom_data: string;
|
|
19
23
|
}
|
|
20
24
|
export { JackpotPublicMeta };
|
|
@@ -14,6 +14,10 @@ export interface LevelPublicMeta {
|
|
|
14
14
|
dx: number;
|
|
15
15
|
dy: number;
|
|
16
16
|
};
|
|
17
|
-
/**
|
|
17
|
+
/**
|
|
18
|
+
* Custom data as string or JSON string that can be used in API to build custom UI
|
|
19
|
+
* You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
|
|
20
|
+
* Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
|
|
21
|
+
*/
|
|
18
22
|
custom_data: string;
|
|
19
23
|
}
|
package/dist/Raffle/Raffle.d.ts
CHANGED
|
@@ -8,7 +8,11 @@ interface RafflePublicMeta {
|
|
|
8
8
|
custom_section_id: number;
|
|
9
9
|
/** URL of the image that represents the raffle */
|
|
10
10
|
image_url: string;
|
|
11
|
-
/**
|
|
11
|
+
/**
|
|
12
|
+
* Custom data as string or JSON string that can be used in API to build custom UI
|
|
13
|
+
* You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
|
|
14
|
+
* Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
|
|
15
|
+
*/
|
|
12
16
|
custom_data: string;
|
|
13
17
|
}
|
|
14
18
|
interface Raffle {
|
|
@@ -836,7 +836,11 @@ export interface TLevel {
|
|
|
836
836
|
*
|
|
837
837
|
*/
|
|
838
838
|
required_level_counter_2: number;
|
|
839
|
-
/**
|
|
839
|
+
/**
|
|
840
|
+
* Custom data as string or JSON string that can be used in API to build custom UI
|
|
841
|
+
* You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
|
|
842
|
+
* Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
|
|
843
|
+
*/
|
|
840
844
|
custom_data: string;
|
|
841
845
|
}
|
|
842
846
|
/**
|
|
@@ -220,7 +220,11 @@ export interface TLevel {
|
|
|
220
220
|
*
|
|
221
221
|
*/
|
|
222
222
|
required_level_counter_2: number;
|
|
223
|
-
/**
|
|
223
|
+
/**
|
|
224
|
+
* Custom data as string or JSON string that can be used in API to build custom UI
|
|
225
|
+
* You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
|
|
226
|
+
* Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
|
|
227
|
+
*/
|
|
224
228
|
custom_data: string;
|
|
225
229
|
}
|
|
226
230
|
/**
|
package/dist/index.js
CHANGED
|
@@ -232,7 +232,7 @@ IntUtils.JsonOrText = function (str) {
|
|
|
232
232
|
return str;
|
|
233
233
|
}
|
|
234
234
|
}
|
|
235
|
-
return str;
|
|
235
|
+
return str || {};
|
|
236
236
|
};
|
|
237
237
|
// public static wsTimeToEpoch = (time: string): number => {
|
|
238
238
|
// if (time) {
|
|
@@ -2622,6 +2622,9 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2622
2622
|
var _pots = _jackpots.items.map(function (jp) {
|
|
2623
2623
|
return jp.pot;
|
|
2624
2624
|
});
|
|
2625
|
+
_jackpots.items.forEach(function (jp) {
|
|
2626
|
+
jp.jp_public_meta.custom_data = IntUtils.JsonOrText(jp.jp_public_meta.custom_data);
|
|
2627
|
+
});
|
|
2625
2628
|
OCache.set(onUpdateContextKey.Pots, _pots, exports.ECacheContext.WSAPI, JACKPOT_POT_CACHE_SEC);
|
|
2626
2629
|
return _jackpots.items;
|
|
2627
2630
|
});
|