aotrautils 0.0.1994 → 0.0.1996

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,6 +1,6 @@
1
1
 
2
2
 
3
- /*utils COMMONS library associated with aotra version : «1_29072022-2359 (13/09/2026-22:47:04)»*/
3
+ /*utils COMMONS library associated with aotra version : «1_29072022-2359 (14/09/2026-01:06:08)»*/
4
4
  /*-----------------------------------------------------------------------------*/
5
5
 
6
6
 
@@ -3584,6 +3584,16 @@ window.objectsEqual=window.aotest({
3584
3584
 
3585
3585
 
3586
3586
 
3587
+ window.getShortenedString=function(str, charactersNumber){
3588
+ var DOTS_STRING="...";
3589
+
3590
+ if(charactersNumber<=0)
3591
+ return str;
3592
+ if(nothing(str))
3593
+ return "";
3594
+
3595
+ return str.substring(0, Math.min(str.length, charactersNumber))+DOTS_STRING;
3596
+ }
3587
3597
 
3588
3598
  window.getTextExtract=function(charactersNumberBefore, charactersNumberAfter, str, word){
3589
3599
  var DOTS_STRING="(...)";
@@ -5475,7 +5485,7 @@ window.AOTRAUTILS_LIB_IS_LOADED=true;
5475
5485
 
5476
5486
 
5477
5487
 
5478
- /*utils CLIENT library associated with aotra version : «1_29072022-2359 (13/09/2026-22:47:04)»*/
5488
+ /*utils CLIENT library associated with aotra version : «1_29072022-2359 (14/09/2026-01:06:08)»*/
5479
5489
  /*-----------------------------------------------------------------------------*/
5480
5490
  /* ## Utility global methods in a browser (htmljs) client environment.
5481
5491
  *
@@ -12990,7 +13000,7 @@ window.createOritaMicroClient=function(url, port, isNode=false, staticMicroClien
12990
13000
 
12991
13001
 
12992
13002
 
12993
- /*utils GEOMETRY library associated with aotra version : «1_29072022-2359 (13/09/2026-22:47:04)»*/
13003
+ /*utils GEOMETRY library associated with aotra version : «1_29072022-2359 (14/09/2026-01:06:08)»*/
12994
13004
  /*-----------------------------------------------------------------------------*/
12995
13005
 
12996
13006
 
@@ -14052,10 +14062,10 @@ function rayVsUnitSphereClosestPoint(p, r) {
14052
14062
  // MUST REMAIN AT THE END OF THIS LIBRARY FILE !
14053
14063
 
14054
14064
  window.AOTRAUTILS_GEOMETRY_LIB_IS_LOADED=true;
14055
- /*utils 3D library associated with aotra version : «1_29072022-2359 (13/09/2026-22:47:04)»*/
14065
+ /*utils 3D library associated with aotra version : «1_29072022-2359 (14/09/2026-01:06:08)»*/
14056
14066
  /*-----------------------------------------------------------------------------*/
14057
14067
 
14058
- /*utils AI library associated with aotra version : «1_29072022-2359 (13/09/2026-22:47:04)»*/
14068
+ /*utils AI library associated with aotra version : «1_29072022-2359 (14/09/2026-01:06:08)»*/
14059
14069
  /*-----------------------------------------------------------------------------*/
14060
14070
 
14061
14071
 
@@ -14319,7 +14329,7 @@ window.getLLMAPIClient=(modelName, apiURL, agentRole, defaultPrompt, llmProvider
14319
14329
 
14320
14330
 
14321
14331
 
14322
- /*utils CONSOLE library associated with aotra version : «1_29072022-2359 (13/09/2026-22:47:04)»*/
14332
+ /*utils CONSOLE library associated with aotra version : «1_29072022-2359 (14/09/2026-01:06:08)»*/
14323
14333
  /*-----------------------------------------------------------------------------*/
14324
14334
 
14325
14335
 
@@ -17492,10 +17502,8 @@ window.performHTTPRequest=function(completeURL, httpMethod="GET", headers={}, re
17492
17502
  data.httpStatus=status;
17493
17503
  resolve(data);
17494
17504
  }).catch(error => {
17495
-
17496
- // DBG
17497
- lognow("ERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERROR",error);
17498
-
17505
+ // TRACE
17506
+ console.error("Error:", error);
17499
17507
  reject({error:`${error}`, httpStatus:null});
17500
17508
  });
17501
17509
  });
@@ -17590,10 +17598,8 @@ window.performHTTPRequest=function(completeURL, httpMethod="GET", headers={}, re
17590
17598
 
17591
17599
  // Handle errors
17592
17600
  request.on("error", (error) => {
17593
-
17594
- // DBG
17595
- lognow("ERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERRORERROR",error);
17596
-
17601
+ // TRACE
17602
+ console.error("Error:", error);
17597
17603
  reject({error:`${error}`, httpStatus:null});
17598
17604
  });
17599
17605
 
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "aotrautils",
3
- "version": "0.0.1994",
3
+ "version": "0.0.1996",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "aotrautils",
9
- "version": "0.0.1994",
9
+ "version": "0.0.1996",
10
10
  "license": "HGPL-1.0",
11
11
  "dependencies": {
12
12
  "atob": "^2.1.2",
aotrautils/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aotrautils",
3
- "version": "0.0.1994",
3
+ "version": "0.0.1996",
4
4
  "main": "aotrautils.build.js",
5
5
  "description": "A library for vanilla javascript utils (client-side) used in aotra javascript CMS",
6
6
  "author": "Jeremie Ratomposon <info@alqemia.com> (https://alqemia.com)",