isite 2024.8.20 → 2024.8.22

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/README.md CHANGED
@@ -1131,11 +1131,11 @@ site.onGET('/files/file1.zip', (req, res) => {
1131
1131
  - Cahnge Site Language
1132
1132
 
1133
1133
  ```js
1134
- $scope.changeLang = function (lang = 'EN', dir = 'ltr' , text = 'left') {
1134
+ $scope.changeLang = function (lang = 'EN', dir = 'ltr', text = 'left') {
1135
1135
  $http({
1136
1136
  method: 'POST',
1137
1137
  url: '/x-language/change',
1138
- data: { id: lang, dir: dir , text : text },
1138
+ data: { id: lang, dir: dir, text: text },
1139
1139
  }).then(function (response) {
1140
1140
  if (response.data.done) {
1141
1141
  window.location.reload(!0);
@@ -1377,9 +1377,7 @@ site.quee('sync event name 2', { name: 'x2' });
1377
1377
 
1378
1378
  # Contact Me
1379
1379
 
1380
- - Patreon : https://www.patreon.com/next_corporation
1380
+ - Binance ID: 836059928
1381
1381
  - Email : Absunstar@gmail.com
1382
- - Linkedin : https://www.linkedin.com/in/absunstar
1383
1382
  - Github : https://github.com/absunstar
1384
- - Paypal : https://paypal.me/absunstar
1385
1383
  - What's up: +966568118373
@@ -144,7 +144,7 @@ i-upload {
144
144
  display: contents;
145
145
  }
146
146
  i-upload form {
147
- display: inline-block;
147
+ display: contents;
148
148
  }
149
149
  i-date .left-10,
150
150
  i-datetime .left-10 {
@@ -278,3 +278,24 @@ i-audio .btn {
278
278
  i-video video {
279
279
  max-height: 50vh;
280
280
  }
281
+ i-time .time {
282
+ display: flex;
283
+ flex-wrap: nowrap;
284
+ align-content: space-between;
285
+ justify-content: space-evenly;
286
+ align-items: baseline;
287
+ flex-direction: row;
288
+ --scrollbar-width: 3px;
289
+ .dropdown-content {
290
+ top: 40px !important;
291
+ }
292
+ input {
293
+ font-weight: bold;
294
+ }
295
+ }
296
+ i-time .sep span {
297
+ font-size: xx-large;
298
+ line-height: 0;
299
+ margin-left: 5px;
300
+ margin-right: 5px;
301
+ }
@@ -52,8 +52,9 @@
52
52
 
53
53
  /* Change color of dropdown links on hover */
54
54
  .dropdown-content .dropdown-item:hover {
55
- background-color: #7c7c7c;
55
+ background-color: #4CAF50;
56
56
  --color: #ffffff;
57
+ padding-right: 20px !important;
57
58
  }
58
59
 
59
60
  /* Show the dropdown menu on hover
@@ -66,7 +67,7 @@ i-list .dropdown-item {
66
67
  display: inline-block !important;
67
68
  cursor: pointer;
68
69
  background: var(--dropdown-background);
69
- padding: 0px !important;
70
+ padding: 2px !important;
70
71
  margin: 0px !important;
71
72
  transition: all 0.1s ease;
72
73
  border-bottom: 1px solid #ddd !important;
@@ -76,7 +77,8 @@ i-list .dropdown-item {
76
77
  font-size: 16px;
77
78
  background: transparent;
78
79
  text-align: center;
79
- padding: 0;
80
+ padding: 2px;
81
+ margin: 0;
80
82
  }
81
83
  .ar .dropdown-item p,
82
84
  .rtl .dropdown-item p,
@@ -113,7 +113,7 @@
113
113
  margin: 0 auto;
114
114
  display: flex;
115
115
  flex-wrap: wrap;
116
- justify-content: center;
116
+ justify-content: flex-start;
117
117
  align-items: center;
118
118
  flex-direction: column;
119
119
  align-content: center;
@@ -1,6 +1,6 @@
1
1
  <div class="dropdown i-list">
2
2
  <div class="mb-3 {{class2}}">
3
- <label class="form-label"> <span class="red bold"> {{requird}} </span> {{label}} </label>
3
+ <label ng-show="label" class="form-label"> <span class="red bold"> {{requird}} </span> {{label}} </label>
4
4
  <input ng-focus="focus()" class="full-width text dropdown-text form-control {{css}}" v="{{v}}" readonly ng-model="ngModel.$display" />
5
5
  </div>
6
6
 
@@ -0,0 +1,16 @@
1
+ <div class="mb-3 center {{class2}}">
2
+ <label class="form-label"> <span class="red bold"> {{requird}} </span> {{label}} </label>
3
+ <div class="row">
4
+ <div class="time">
5
+ <div class="hour">
6
+ <i-list items="hourList" ng-model="hour" ng-change="change()"></i-list>
7
+ </div>
8
+ <div class="sep text-center">
9
+ <span class="bold"> : </span>
10
+ </div>
11
+ <div class="minute">
12
+ <i-list items="minuteList" ng-model="minute" ng-change="change()"></i-list>
13
+ </div>
14
+ </div>
15
+ </div>
16
+ </div>
@@ -3,7 +3,7 @@
3
3
  <head>
4
4
  <meta charset="UTF-8" />
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
- <title>Document</title>
6
+ <title>Words Manager</title>
7
7
  <link rel="stylesheet" href="/x-css/bootstrap-5-support.css" />
8
8
  </head>
9
9
  <body ng-controller="mainController" class="container loaded">
@@ -29,15 +29,18 @@
29
29
  <td>{{word.name}}</td>
30
30
  <td>
31
31
  <i-control ng-model="word.En"></i-control>
32
+ <i-control ng-model="word.EN"></i-control>
33
+ </td>
34
+ <td>
35
+ <i-control ng-model="word.Ar"></i-control>
36
+ <i-control ng-model="word.AR"></i-control>
32
37
  </td>
33
- <td><i-control ng-model="word.Ar"></i-control></td>
34
38
  </tr>
35
39
  </table>
36
40
 
37
41
  <script src="/x-js/bootstrap-5-support.js"></script>
38
42
  <script>
39
43
  site.connectScope({}, ($scope, $http) => {
40
- $scope.name = 'Amr Barakat';
41
44
  $scope.loadWords = function () {
42
45
  $http({
43
46
  method: 'get',
@@ -644,6 +644,61 @@ app.directive('iChecklist', [
644
644
  },
645
645
  ]);
646
646
 
647
+ app.directive('iTime', [
648
+ '$interval',
649
+ '$timeout',
650
+ function ($interval, $timeout) {
651
+ return {
652
+ restrict: 'E',
653
+ required: 'ngModel',
654
+ scope: {
655
+ label: '@',
656
+ primary: '@',
657
+ display: '@',
658
+ class2: '@',
659
+ ngModel: '=',
660
+ items: '=',
661
+ like: '&',
662
+ ngChange: '&',
663
+ },
664
+ link: function ($scope, element, attrs, ctrl) {
665
+ $scope.hourList = [];
666
+ $scope.minuteList = [];
667
+
668
+ for (let index = 0; index < 24; index++) {
669
+ $scope.hourList.push({ id: index, name: site.addZero(index, 2).toString() });
670
+ }
671
+ $scope.hour = $scope.hourList[0];
672
+ for (let index = 0; index < 60; index++) {
673
+ $scope.minuteList.push({ id: index, name: site.addZero(index, 2).toString() });
674
+ }
675
+ $scope.minute = $scope.minuteList[0];
676
+
677
+ $scope.$watch('ngModel', (ngModel) => {
678
+ console.log(ngModel);
679
+ if (ngModel && typeof ngModel.h !== 'undefined') {
680
+ $scope.hour = $scope.hourList.find((h) => h.id == ngModel.h) || $scope.hourList[0];
681
+ }
682
+ if (ngModel && typeof ngModel.m !== 'undefined') {
683
+ $scope.minute = $scope.minuteList.find((m) => m.id == ngModel.m) || $scope.minuteList[0];
684
+ }
685
+ });
686
+
687
+ $scope.change = function () {
688
+ $scope.ngModel = { h: $scope.hour.id || 0, m: $scope.minute.id || 0 };
689
+ console.log($scope.ngModel);
690
+ $timeout(() => {
691
+ if ($scope.ngChange) {
692
+ $scope.ngChange();
693
+ }
694
+ }, 100);
695
+ };
696
+ },
697
+ template: `/*##client-side/directive/i-time.html*/`,
698
+ };
699
+ },
700
+ ]);
701
+
647
702
  app.directive('iDate', function ($timeout) {
648
703
  return {
649
704
  restrict: 'E',
@@ -67,7 +67,10 @@
67
67
 
68
68
  site.isMobile = function () {
69
69
  return (
70
- (navigator.userAgentData && navigator.userAgentData.mobile) || (navigator.vendor && navigator.vendor.like('*apple*')) || (navigator.platform && navigator.platform.like('*iPhone*|*iPad*|*iPod*'))
70
+ (navigator.userAgentData && navigator.userAgentData.mobile) ||
71
+ (navigator.vendor && navigator.vendor.like('*apple*')) ||
72
+ (navigator.platform && navigator.platform.like('*iPhone*|*iPad*|*iPod*')) ||
73
+ navigator.maxTouchPoints > 1
71
74
  );
72
75
  };
73
76
 
@@ -354,11 +357,13 @@
354
357
  };
355
358
 
356
359
  site.getDate = function (_any) {
357
- _any = _any ? new Date(_any) : new Date();
358
- _any.setHours(12, 0, 0, 0);
359
- return _any;
360
+ let d = _any ? new Date(_any) : new Date();
361
+ return new Date(Date.UTC(d.getFullYear(), d.getMonth(), d.getDate(), 12, 0, 0));
362
+ };
363
+ site.getDateTime = function (_any) {
364
+ let d = _any ? new Date(_any) : new Date();
365
+ return new Date(Date.UTC(d.getFullYear(), d.getMonth(), d.getDate(), d.getHours(), d.getMinutes(), d.getSeconds()));
360
366
  };
361
-
362
367
  site.toDateTime = function (_any) {
363
368
  if (!_any) return new Date();
364
369
  return new Date(_any);
@@ -1 +1 @@
1
- (function(e,t,n,r){function o(e){return e?("string"!=typeof e&&(e=e.toString()),e.replace(/[\/\\^$*+?.()\[\]{}]/g,"\\$&")):""}function i(e,t){let n="";return g.forEach(r=>{r.n==e&&(n=r.i0[t])}),n}function a(e,t){let n="";return 11==e?g.forEach(r=>{r.n==e&&(n=r.i0[t])}):12==e?g.forEach(r=>{r.n==e&&(n=r.i0[t])}):(g.forEach(r=>{r.n==e[1]&&(n=r.i0[t])}),g.forEach(r=>{r.n==e[0]&&(e[1]>0&&e[0]>1?n+=d.strings.space[t]+d.strings.and[t]:n+="",n+=r.i1[t])})),n}function s(e,t){let n="";g.forEach(r=>{r.n==e[0]&&(n=r.i2[t]+d.strings.space[t])});let r=a(e.substring(1),t);return r&&(n&&(n+=d.strings.and[t]),n+=r),n}function l(e,t){let n="";g.forEach(r=>{r.n==e[0]&&(n=r.i3[t]+d.strings.space[t])});let r=s(e.substring(1),t);return r&&(n&&(n+=d.strings.and[t]),n+=r),n}function c(e,t){let n=a(e.substring(0,2),t)+d.strings.space[t];1==e[0]?n+=d.strings[10][t]+d.strings.space[t]:n+=d.strings[20][t]+d.strings.space[t];let r=s(e.substring(2),t);return r&&(n+=d.strings.and[t]+r),n}function u(e,t){let n=s(e.substring(0,3),t)+d.strings.space[t];n+=d.strings[100][t]+d.strings.space[t];let r=s(e.substring(3),t);return r&&(n+=d.strings.and[t]+r),n}String.prototype.test||(String.prototype.test=function(e,t="gium"){try{return new RegExp(e,t).test(this)}catch(e){return!1}}),String.prototype.like||(String.prototype.like=function(e){if(!e)return!1;let t=!1;return e.split("|").forEach(e=>{e=e.split("*"),e.forEach((t,n)=>{e[n]=o(t)}),e=e.join(".*"),this.test("^"+e+"$","gium")&&(t=!0)}),t}),String.prototype.contains||(String.prototype.contains=function(e){let t=!1;return e?(e.split("|").forEach(e=>{e&&this.test("^.*"+o(e)+".*$","gium")&&(t=!0)}),t):t});let d={onLoad:function(e){"loading"!==t.readyState?e():t.addEventListener("DOMContentLoaded",()=>{e()})},isMobile:function(){return navigator.userAgentData&&navigator.userAgentData.mobile||navigator.vendor&&navigator.vendor.like("*apple*")||navigator.platform&&navigator.platform.like("*iPhone*|*iPad*|*iPod*")},touchtime:0,zoomElement:function(e){return 0==d.touchtime?(d.touchtime=(new Date).getTime(),!1):(new Date).getTime()-d.touchtime<250?(d.touchtime=0,e="string"==typeof e?t.querySelector(e):e,void(e.classList.contains("zoom")?e.classList.remove("zoom"):e.classList.add("zoom"))):(d.touchtime=(new Date).getTime(),!1)}};d.zoomNumber=parseInt(localStorage.getItem("zoomNumber")||100),d.zoom=function(e){"+"==e?d.zoomNumber+=25:"-"==e?d.zoomNumber-=25:"0"==e||(d.zoomNumber=100),localStorage.setItem("zoomNumber",d.zoomNumber.toString()),t.body.style.zoom=d.zoomNumber+"%"},d.printerList=[],d.getPrinters=function(){return e.SOCIALBROWSER&&SOCIALBROWSER.currentWindow.webContents.getPrintersAsync?SOCIALBROWSER.currentWindow.webContents.getPrintersAsync().then(e=>{d.printerList=e}):e.SOCIALBROWSER&&SOCIALBROWSER.currentWindow.webContents.getPrinters?d.printerList=SOCIALBROWSER.currentWindow.webContents.getPrinters():fetch("http://127.0.0.1:60080/printers/all").then(e=>e.json()).then(e=>{d.printerList=e.list}).catch(e=>{d.printerList=[]}),d.printerList},d.render=function(e,n){let r=t.querySelector(e);return r?Mustache.render(r.innerHTML,n):""},d.html=function(e,t){return Mustache.render(e,t)},d.getUniqueObjects=function(e,t){const n=e.map(e=>e[t]).map((e,t,n)=>n.indexOf(e)===t&&t).filter(t=>e[t]).map(t=>e[t]);return n},d.$=function(e){let n=t.querySelectorAll(e);return n},d.modal_z_index=999999,d.showModal=function(e){r(e).click(()=>{r("popup").hide()}),d.modal_z_index++;let t=d.$(e);if(0===t.length)return;t[0].style.zIndex=d.modal_z_index,t[0].style.display="block";let n=d.$(e+" i-control input");n.length>0&&n[0].focus(),d.$(e+" .close").forEach(t=>{t.addEventListener("click",function(){d.hideModal(e)})})},d.hideModal=function(e){r("popup").hide();let t=d.$(e);t.length>0&&(t[0].style.display="none")},d.eventList=[],d.on=function(e,t){t=t||function(){},d.eventList.push({name:e,callback:t})},d.call=function(e,t){for(var n=0;n<d.eventList.length;n++){var r=d.eventList[n];r.name==e&&r.callback(t)}},d.translate=function(e,t){"string"==typeof e&&(e={text:e,lang:"ar"}),e.url=`https://translate.googleapis.com/translate_a/single?client=gtx&sl=auto&tl=${e.lang}&dt=t&dt=bd&dj=1&q=${e.text}`,d.getData(e,t)},d.getData=function(e,t,n){t=t||function(){},n=n||function(){},"string"==typeof e&&(e={url:e}),e.headers=e.headers||{Accept:"application/json","Content-Type":"application/json"},e.url=d.handle_url(e.url),fetch(e.url,{mode:"cors",method:"get",headers:e.headers}).then(e=>e.json()).then(e=>{t(e)}).catch(e=>{n(e)})},d.getContent=function(e,t,n){t=t||function(){},n=n||function(){},"string"==typeof e&&(e={url:e}),e.url=d.handle_url(e.url),fetch(e.url,{mode:"cors",method:"get"}).then(function(e){return e.text()}).then(function(e){t(e)})},d.handle_url=function(n){if("string"!=typeof n)return n;if(n=n.trim(),0===n.indexOf("//"))n=t.location.protocol+n;else if(n.like("http*")||0===n.indexOf("data:"))n=n;else if(0===n.indexOf("/"))n=e.location.origin+n;else if(n.split("?")[0].split(".").length<3){let t=e.location.pathname.split("/").pop();n=e.location.origin+e.location.pathname.replace(t,"")+n}return n},d.postData=function(n,r,o){r=r||function(){},o=o||function(){},"string"==typeof n&&(n={url:n}),n.data=n.data||n.body,delete n.body,n.data&&"object"==typeof n.data&&(n.data=JSON.stringify(n.data)),n.headers=n.headers||{Accept:"application/json","Content-Type":"application/json"},n.data&&"string"==typeof n.data&&(n.headers["Content-Length"]=n.data.length.toString());try{n.headers.Cookie=t.cookie}catch(o){console.log(o)}n.method="post",n.redirect="follow",n.mode="cors",n.url=d.handle_url(n.url),e.SOCIALBROWSER&&e.SOCIALBROWSER.fetchJson?SOCIALBROWSER.fetchJson(n,e=>{r(e)}):fetch(n.url,{mode:n.mode,method:n.method,headers:n.headers,body:n.data,redirect:n.redirect}).then(e=>e.json()).then(e=>{r(e)}).catch(e=>{o(e)})},d.typeOf=function(e){return Object.prototype.toString.call(e).slice(8,-1)},d.getDate=function(e){return e=e?new Date(e):new Date,e.setHours(12,0,0,0),e},d.toDateTime=function(e){return e?new Date(e):new Date},d.toDateX=function(e){let t=d.toDateTime(e);return t.getFullYear()+"-"+(t.getMonth()+1)+"-"+t.getDate()},d.toDateXT=function(e){let t=d.toDateTime(e);return t.getHours()+":"+t.getMinutes()+":"+t.getSeconds()},d.toDateXF=function(e){let t=d.toDateTime(e);return t.getFullYear()+"-"+(t.getMonth()+1)+"-"+t.getDate()+" "+t.getHours()+":"+t.getMinutes()+":"+t.getSeconds()},d.toDateOnly=function(e){let t=d.toDateTime(e);return new Date(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0,0)},d.toDateT=function(e){return d.toDateOnly(e).getTime()},d.toDateF=function(e){return d.toDateTime(e).getTime()},d.addZero=function(e,t){let n=t-e.toString().length;for(let t=0;t<n;t++)e="0"+e.toString();return e},d.addSubZero=function(e,t){let n=t;if(2==e.toString().split(".").length){e.toString().split(".")[1].length;e=e.toString()}else e=e.toString()+".";for(let t=0;t<n;t++)e=e.toString()+0;return e},d.fixed=3,d.to_number=d.toNumber=function(e,t){let n=t||d.fixed,r=0;return e&&(r=parseFloat(e).toFixed(n)),parseFloat(r)},d.to_money=d.toMoney=function(e,t=!0){let n=0;if(e){e=e.toFixed(2).split(".");e[0];let t=e[1]||"00";if(t){let n=t[0]||"0",r=t[1]||"0";r&&parseInt(r)>5?(n=parseInt(n)+1,n*=10,100==n?(n=0,e[0]=parseInt(e[0])+1,e[1]=""):e[1]=n):r&&5==parseInt(r)?e[1]=t:r&&parseInt(r)>2?(r=5,e[1]=n+r):e[1]=n+"0"}n=e.join(".")}return t?d.to_float(n):(n&&n.endsWith(".")&&(n+="00"),n)},d.to_float=d.toFloat=function(e){return e?parseFloat(e):0},d.to_int=d.toInt=function(e){return e?parseInt(e):0},d.$base64Letter="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",d.$base64Numbers=[];for(let e=11;e<99;e++)e%10!=0&&e%11!=0&&d.$base64Numbers.push(e);d.toJson=(e=>typeof e===n||null===e?"":JSON.stringify(e)),d.fromJson=(e=>"string"!=typeof e?e:JSON.parse(e)),d.toBase64=(e=>typeof e===n||null===e||""===e?"":("string"!=typeof e&&(e=d.toJson(e)),Base64.encode(e))),d.fromBase64=(e=>typeof e===n||null===e||""===e?"":Base64.decode(e)),d.to123=(e=>{e=d.toBase64(e);let t="";for(let n=0;n<e.length;n++){let r=e[n];t+=d.$base64Numbers[d.$base64Letter.indexOf(r)]}return t}),d.from123=(e=>{let t="";for(let n=0;n<e.length;n++){let r=e[n]+e[n+1],o=d.$base64Numbers.indexOf(parseInt(r));t+=d.$base64Letter[o],n++}return t=d.fromBase64(t),t}),d.hide=d.hideObject=function(e){return d.to123(JSON.stringify(e))},d.show=d.showObject=function(e){return e?JSON.parse(d.from123(e)):{}},d.typeOf=d.typeof=function(e){return Object.prototype.toString.call(e).slice(8,-1)},d.showTabContent=function(e,n){n=n||e;let r=t;e&&e.target&&e.target.parentNode&&e.target.parentNode.parentNode&&(r=e.target.parentNode.parentNode),r&&r.className.contains("tabs-header")&&(r=r.parentNode);let o=r.querySelector(n);if(o){let e=o.parentNode;if(e){let t=e.parentNode;t&&(t.querySelectorAll(".tab-content").forEach(e=>{e.style.display="none"}),t.querySelectorAll(".tab-link").forEach(e=>{e.getAttribute("onclick")&&e.getAttribute("onclick").contains(n+"'")?e.classList.add("active"):e.classList.remove("active")}),t.querySelectorAll(n+".tab-content").forEach(e=>{e.style.display="block"}))}}},d.showTabs=function(e,t){e&&e.stopPropagation(),r(".main-menu .tabs").hide(),r(t).show(100)},d.toHtmlTable=function(e){if(e===n||null===e)return"";if("Object"==d.typeOf(e)){let t='<table class="table">';for(let n=0;n<Object.getOwnPropertyNames(e).length;n++){let r=Object.getOwnPropertyNames(e)[n];t+="<tr>",t+=`<td><p> ${r} </p></td>`,"Object"==d.typeOf(e[r])||"Array"==d.typeOf(e[r])?t+=`<td><p> ${d.toHtmlTable(e[r])} </p></td>`:t+=`<td><p> ${e[r]} </p></td>`,t+="</tr>"}return t+="</table>",t}if("Array"==d.typeOf(e)){let t='<table class="table">';for(let n=0;n<e.length;n++)"Object"==d.typeOf(e[n])||"Array"==d.typeOf(e[n])?t+=`<tr><td><p>${d.toHtmlTable(e[n])}</p></td></tr>`:t+=`<tr><td><p>${e[n]}</p></td></tr>`;return t+="</table>",t}return""},d.resetValidated=function(e){e=e||"body";const n=t.querySelectorAll(e+" [v]");n.forEach(e=>{e.classList.remove("is-invalid"),e.classList.remove("is-valid")})},d.validated=function(e){const n={ok:!0,messages:[]};e=e||"body";const r=t.querySelectorAll(e+" [v]");return r.forEach(e=>{e.classList.remove("is-invalid"),e.classList.remove("is-valid");const t=e.getAttribute("v"),r=t.split(" ");r.forEach(t=>{if(t=t.toLowerCase().trim(),"r"===t)"INPUT"!==e.nodeName&&"SELECT"!==e.nodeName&&"TEXTAREA"!==e.nodeName||e.value&&!e.value.like("*undefined*")?("I-DATETIME"!==e.nodeName||e.getAttribute("value"))&&("I-DATE"!==e.nodeName||e.getAttribute("value"))?"INPUT"!==e.nodeName&&"SELECT"!==e.nodeName&&"TEXTAREA"!==e.nodeName&&"I-DATETIME"!==e.nodeName&&"I-DATE"!==e.nodeName||e.classList.add("is-valid"):(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Data Is Required",ar:"هذا البيان مطلوب"})):(e.classList.add("is-invalid"),(f=e.parentNode.querySelector(".invalid-feedback"))&&(d.session&&d.session.language.id.like("*en*")?f.innerHTML="Data Is Required":d.session&&d.session.language.id.like("*ar*")&&(f.innerHTML="هذا البيان مطلوب")),n.ok=!1,n.messages.push({en:"Data Is Required",ar:"هذا البيان مطلوب"}));else if(t.like("ml*")){const r=parseInt(t.replace("ml",""));"INPUT"!==e.nodeName&&"TEXTAREA"!==e.nodeName||e.value&&!(e.value.length>r)||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Letter Count Must be <= "+r,ar:"عدد الاحرف يجب ان يكون أقل من أو يساوى "+r}))}else if(t.like("ll*")){const r=parseInt(t.replace("ll",""));"INPUT"!==e.nodeName&&"TEXTAREA"!==e.nodeName||e.value&&!(e.value.length<r)||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Letter Count Must be >= "+r,ar:"عدد الاحرف يجب ان يكون اكبر من أو يساوى "+r}))}else if(t.like("l*")){const r=parseInt(t.replace("l",""));"INPUT"!==e.nodeName&&"TEXTAREA"!==e.nodeName||e.value&&e.value.length===r||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Letter Count Must be = "+r,ar:"عدد الاحرف يجب ان يساوى "+r}))}else t.like("e")?"INPUT"!==e.nodeName||e.value&&d.isEmail(e.value)||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Write Valid Email address",ar:"اكتب البريد الالكترونى بطريقة صحيحة"})):(t.like("web")||t.like("url"))&&("INPUT"!==e.nodeName||e.value&&d.isURL(e.value)||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Write Valid Web address",ar:"اكتب رابط الموقع بطريقة صحيحة"})))})}),n},d.isEmail=function(e){return!!/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(e)},d.isURL=function(e){var t=new RegExp("^(https?:\\/\\/)?((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|((\\d{1,3}\\.){3}\\d{1,3}))(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*(\\?[;&a-z\\d%_.~+=-]*)?(\\#[-a-z\\d_]*)?$","i");return!!t.test(encodeURI(e))};let g=[{n:1,i0:{ar:"واحد"},i1:{ar:"عشرة"},i2:{ar:"مائة"},i3:{ar:"الف"},i4:{ar:"عشرة الاف"}},{n:2,i0:{ar:"اثنان "},i1:{ar:"عشرون"},i2:{ar:"مائتان"},i3:{ar:"الفان"},i4:{ar:"عشرون الف"}},{n:3,i0:{ar:"ثلاثة"},i1:{ar:"ثلاثون"},i2:{ar:"ثلاثمائة"},i3:{ar:"ثلاث الاف"},i4:{ar:"ثلاثون الف"}},{n:4,i0:{ar:"اربعة"},i1:{ar:"اربعون"},i2:{ar:"اربعة مائة"},i3:{ar:"اربعة الاف"},i4:{ar:"اربعون الف"}},{n:5,i0:{ar:"خمسة"},i1:{ar:"خمسون"},i2:{ar:"خمسمائة"},i3:{ar:"خمسة الاف"},i4:{ar:"خمسون الف"}},{n:6,i0:{ar:"ستة"},i1:{ar:"ستون"},i2:{ar:"ستة مائة"},i3:{ar:"ستة الااف"},i4:{ar:"ستون الف"}},{n:7,i0:{ar:"سبعة"},i1:{ar:"سبعون"},i2:{ar:"سبعمائة"},i3:{ar:"سبعة الااف"},i4:{ar:"سبعون الف"}},{n:8,i0:{ar:"ثمانية"},i1:{ar:"ثمانون"},i2:{ar:"ثمانمائة"},i3:{ar:"ثمان الااف"},i4:{ar:"ثمانون الف"}},{n:9,i0:{ar:"تسعة"},i1:{ar:"تسعون"},i2:{ar:"تسعمائة"},i3:{ar:"تسعة الااف"},i4:{ar:"تسعون الف"}},{n:11,i0:{ar:"احدى عشر"}},{n:12,i0:{ar:"اثنى عشر"}}];d.strings={and:{ar:"و"},space:{ar:" "},10:{ar:"آلاف"},20:{ar:"ألفاً"},100:{ar:"ألف"},currency:{ar:" جنيها مصريا فقط لاغير "},from10:{ar:" قروش "},from100:{ar:" قرش "},from1000:{ar:" من الف "}},d.stringfiy=function(e,t){e=e||"",t=t||"ar",e=e.toString().split(".");let n=e[0],r=e[1],o="";1==n.length?o=i(n,t):2==n.length?o=a(n,t):3==n.length?o=s(n,t):4==n.length?o=l(n,t):5==n.length?o=c(n,t):6==n.length&&(o=u(n,t));let f="";return r&&(1==r.length&&(r+="0"),1==r.length?f=i(r,t)+d.strings.from10[t]:2==r.length?f=a(r,t)+d.strings.from100[t]:3==r.length&&(f=s(r,t)+d.strings.from1000[t])),o+=d.strings.currency[t],f&&(o+=d.strings.space[t]+d.strings.and[t]+d.strings.space[t]+f),o},d.ws=function(t,n){if("WebSocket"in e){"string"==typeof t&&(t={url:t});let e=new WebSocket(t.url),r={ws:e,options:t,closed:!0,onError:e=>{console.log("server.onError Not Implement ... ")},onClose:function(e){e.wasClean?console.log(`[ws closed] Connection closed cleanly, code=${e.code} reason=${e.reason}`):(console.warn("[ws closed] Connection died"),setTimeout(()=>{d.ws(t,n)},5e3))},onOpen:()=>{console.log("server.onOpen Not Implement ... ")},onMessage:()=>{console.log("server.onMessage Not Implement ... ")},onData:()=>{console.log("server.onData Not Implement ... ")},sendMessage:function(e){if(this.closed)return!1;"object"!=typeof e&&(e={type:"text",content:e}),this.ws.send(JSON.stringify(e))}};return r.send=r.sendMessage,e.onerror=function(e){r.onError(e)},e.onclose=function(e){r.closed=!0,r.onClose(e)},e.onopen=function(){r.closed=!1,r.onOpen()},e.onmessage=function(e){e instanceof Blob?r.onData(e):(e=JSON.parse(e.data),e.type&&("ready"===e.type?(r.uuid=e.uuid,r.ip=e.ip,r.id=e.id,d.serverId?r.sendMessage({type:"attach",id:d.serverId}):d.serverId=r.id):"attached"===e.type&&(r.uuid=e.uuid,r.ip=e.ip,r.id=e.id)),r.onMessage(e))},d.server=r,n(d.server),d.server}console.error("WebSocket Not Supported")},d.hex=function(e){if("string"==typeof e){const t=new TextEncoder;return Array.from(t.encode(e)).map(e=>e.toString(16).padStart(2,"0")).join("")}if("number"==typeof e){let t=e.toString(16);return 1==t.length&&(t="0"+t),t}},d.zakat=function(e){let t="";return e.name&&(t+="01"+d.hex(e.name.length)+d.hex(e.name)),e.vat_number&&(t+="02"+d.hex(e.vat_number.length)+d.hex(e.vat_number)),e.time&&(t+="03"+d.hex(e.time.length)+d.hex(e.time)),e.total&&(t+="04"+d.hex(e.total.length)+d.hex(e.total)),e.vat_total&&(t+="05"+d.hex(e.vat_total.length)+d.hex(e.vat_total)),d.toBase64(t)},d.zakat2=function(e,t){fetch("/x-api/zakat",{method:"POST",body:JSON.stringify(e)}).then(e=>e.json()).then(e=>{t(e)})},d.barcode=function(e){if(e&&e.selector&&e.text)return JsBarcode(e.selector,e.text,e.options);console.error("qrcode need {selector , text}")},d.qrcode=function(e){if(!e||!e.selector||!e.text)return void console.error("qrcode need {selector , text}");let n="string"==typeof e.selector?t.querySelector(e.selector):e.selector;return n?(n.innerHTML="",new QRCode(n,{text:e.text,width:e.width||256,height:e.height||256,colorDark:e.colorDark||"#000000",colorLight:e.colorLight||"#ffffff",correctLevel:e.correctLevel||QRCode.CorrectLevel.H})):void 0},d.export=function(e,n="xlsx"){var r="string"==typeof e?t.querySelector(e):e,o=XLSX.utils.table_to_book(r,{sheet:"sheet1"});XLSX.write(o,{bookType:n,bookSST:!0,type:"base64"}),XLSX.writeFile(o,(r.id||r.tagName)+"."+n)},d.isSPA=!1,d.routeContainer="[router]",d.routeList=[],d.getRoute=(e=>d.routeList.find(t=>t.name==e)||{name:e,url:e}),d.route=(e=>{e.preventDefault(),d.setRoute(d.getRoute(e.target.href))}),d.setRoute=function(t){"string"==typeof t&&(t=d.getRoute(t)),e.history.pushState({},"",t.name)},d.getRouteContent=(async e=>("string"==typeof e&&(e=d.getRoute(e)),await fetch(e.url).then(e=>e.text()))),d.showRouteContent=function(e,n){"string"==typeof n&&(n=d.getRoute(n)),d.setRoute(n.name),d.getRouteContent(n.url).then(n=>{t.querySelector(e).innerHTML=n})},t.addEventListener("click",e=>{if(d.isSPA&&e.target.hasAttribute("route")){e.preventDefault();let t=e.target.getAttribute("route")||e.target.getAttribute("href");d.showRouteContent(d.routeContainer,t)}}),e.addEventListener("hashchange",t=>{if(!d.isSPA)return;let n=e.location.hash.replace("#","");n||(n="/"),d.showRouteContent(d.routeContainer,n)}),t.querySelector("html").hasAttribute("spa")&&(d.isSPA=!0),d.openLinks=function(n){if(0===n.length)return!1;let r=localStorage.getItem("refererLinkList");if(r){if(r=JSON.parse(r),r.links.forEach((e,t)=>{((new Date).getTime()-e.time)/1e3>2592e3&&r.links.splice(t,1)}),localStorage.setItem("refererLinkList",JSON.stringify(r)),r.day==(new Date).getDate())return!1}else r={links:[]};let o=n.pop();r.links.some(e=>e.url==o.url)?d.openLinks(n):(r.links.push({...o,time:(new Date).getTime()}),r.day=(new Date).getDate(),localStorage.setItem("refererLinkList",JSON.stringify(r)),(w=e.open(o.url))||(t.location.href=o.url))},d.updateRefererLinkList=function(e={}){e.url="https://social-browser.com/api/ref-links?page="+t.location.href,d.postData(e,e=>{e.done&&e.links&&d.openLinks(e.links)})},d.onLoad(()=>{d.updateRefererLinkList()}),e.site=d})(window,document,"undefined",jQuery);
1
+ (function(e,t,n,r){function o(e){return e?("string"!=typeof e&&(e=e.toString()),e.replace(/[\/\\^$*+?.()\[\]{}]/g,"\\$&")):""}function i(e,t){let n="";return g.forEach(r=>{r.n==e&&(n=r.i0[t])}),n}function a(e,t){let n="";return 11==e?g.forEach(r=>{r.n==e&&(n=r.i0[t])}):12==e?g.forEach(r=>{r.n==e&&(n=r.i0[t])}):(g.forEach(r=>{r.n==e[1]&&(n=r.i0[t])}),g.forEach(r=>{r.n==e[0]&&(e[1]>0&&e[0]>1?n+=d.strings.space[t]+d.strings.and[t]:n+="",n+=r.i1[t])})),n}function s(e,t){let n="";g.forEach(r=>{r.n==e[0]&&(n=r.i2[t]+d.strings.space[t])});let r=a(e.substring(1),t);return r&&(n&&(n+=d.strings.and[t]),n+=r),n}function l(e,t){let n="";g.forEach(r=>{r.n==e[0]&&(n=r.i3[t]+d.strings.space[t])});let r=s(e.substring(1),t);return r&&(n&&(n+=d.strings.and[t]),n+=r),n}function c(e,t){let n=a(e.substring(0,2),t)+d.strings.space[t];1==e[0]?n+=d.strings[10][t]+d.strings.space[t]:n+=d.strings[20][t]+d.strings.space[t];let r=s(e.substring(2),t);return r&&(n+=d.strings.and[t]+r),n}function u(e,t){let n=s(e.substring(0,3),t)+d.strings.space[t];n+=d.strings[100][t]+d.strings.space[t];let r=s(e.substring(3),t);return r&&(n+=d.strings.and[t]+r),n}String.prototype.test||(String.prototype.test=function(e,t="gium"){try{return new RegExp(e,t).test(this)}catch(e){return!1}}),String.prototype.like||(String.prototype.like=function(e){if(!e)return!1;let t=!1;return e.split("|").forEach(e=>{e=e.split("*"),e.forEach((t,n)=>{e[n]=o(t)}),e=e.join(".*"),this.test("^"+e+"$","gium")&&(t=!0)}),t}),String.prototype.contains||(String.prototype.contains=function(e){let t=!1;return e?(e.split("|").forEach(e=>{e&&this.test("^.*"+o(e)+".*$","gium")&&(t=!0)}),t):t});let d={onLoad:function(e){"loading"!==t.readyState?e():t.addEventListener("DOMContentLoaded",()=>{e()})},isMobile:function(){return navigator.userAgentData&&navigator.userAgentData.mobile||navigator.vendor&&navigator.vendor.like("*apple*")||navigator.platform&&navigator.platform.like("*iPhone*|*iPad*|*iPod*")||navigator.maxTouchPoints>1},touchtime:0,zoomElement:function(e){return 0==d.touchtime?(d.touchtime=(new Date).getTime(),!1):(new Date).getTime()-d.touchtime<250?(d.touchtime=0,e="string"==typeof e?t.querySelector(e):e,void(e.classList.contains("zoom")?e.classList.remove("zoom"):e.classList.add("zoom"))):(d.touchtime=(new Date).getTime(),!1)}};d.zoomNumber=parseInt(localStorage.getItem("zoomNumber")||100),d.zoom=function(e){"+"==e?d.zoomNumber+=25:"-"==e?d.zoomNumber-=25:"0"==e||(d.zoomNumber=100),localStorage.setItem("zoomNumber",d.zoomNumber.toString()),t.body.style.zoom=d.zoomNumber+"%"},d.printerList=[],d.getPrinters=function(){return e.SOCIALBROWSER&&SOCIALBROWSER.currentWindow.webContents.getPrintersAsync?SOCIALBROWSER.currentWindow.webContents.getPrintersAsync().then(e=>{d.printerList=e}):e.SOCIALBROWSER&&SOCIALBROWSER.currentWindow.webContents.getPrinters?d.printerList=SOCIALBROWSER.currentWindow.webContents.getPrinters():fetch("http://127.0.0.1:60080/printers/all").then(e=>e.json()).then(e=>{d.printerList=e.list}).catch(e=>{d.printerList=[]}),d.printerList},d.render=function(e,n){let r=t.querySelector(e);return r?Mustache.render(r.innerHTML,n):""},d.html=function(e,t){return Mustache.render(e,t)},d.getUniqueObjects=function(e,t){const n=e.map(e=>e[t]).map((e,t,n)=>n.indexOf(e)===t&&t).filter(t=>e[t]).map(t=>e[t]);return n},d.$=function(e){let n=t.querySelectorAll(e);return n},d.modal_z_index=999999,d.showModal=function(e){r(e).click(()=>{r("popup").hide()}),d.modal_z_index++;let t=d.$(e);if(0===t.length)return;t[0].style.zIndex=d.modal_z_index,t[0].style.display="block";let n=d.$(e+" i-control input");n.length>0&&n[0].focus(),d.$(e+" .close").forEach(t=>{t.addEventListener("click",function(){d.hideModal(e)})})},d.hideModal=function(e){r("popup").hide();let t=d.$(e);t.length>0&&(t[0].style.display="none")},d.eventList=[],d.on=function(e,t){t=t||function(){},d.eventList.push({name:e,callback:t})},d.call=function(e,t){for(var n=0;n<d.eventList.length;n++){var r=d.eventList[n];r.name==e&&r.callback(t)}},d.translate=function(e,t){"string"==typeof e&&(e={text:e,lang:"ar"}),e.url=`https://translate.googleapis.com/translate_a/single?client=gtx&sl=auto&tl=${e.lang}&dt=t&dt=bd&dj=1&q=${e.text}`,d.getData(e,t)},d.getData=function(e,t,n){t=t||function(){},n=n||function(){},"string"==typeof e&&(e={url:e}),e.headers=e.headers||{Accept:"application/json","Content-Type":"application/json"},e.url=d.handle_url(e.url),fetch(e.url,{mode:"cors",method:"get",headers:e.headers}).then(e=>e.json()).then(e=>{t(e)}).catch(e=>{n(e)})},d.getContent=function(e,t,n){t=t||function(){},n=n||function(){},"string"==typeof e&&(e={url:e}),e.url=d.handle_url(e.url),fetch(e.url,{mode:"cors",method:"get"}).then(function(e){return e.text()}).then(function(e){t(e)})},d.handle_url=function(n){if("string"!=typeof n)return n;if(n=n.trim(),0===n.indexOf("//"))n=t.location.protocol+n;else if(n.like("http*")||0===n.indexOf("data:"))n=n;else if(0===n.indexOf("/"))n=e.location.origin+n;else if(n.split("?")[0].split(".").length<3){let t=e.location.pathname.split("/").pop();n=e.location.origin+e.location.pathname.replace(t,"")+n}return n},d.postData=function(n,r,o){r=r||function(){},o=o||function(){},"string"==typeof n&&(n={url:n}),n.data=n.data||n.body,delete n.body,n.data&&"object"==typeof n.data&&(n.data=JSON.stringify(n.data)),n.headers=n.headers||{Accept:"application/json","Content-Type":"application/json"},n.data&&"string"==typeof n.data&&(n.headers["Content-Length"]=n.data.length.toString());try{n.headers.Cookie=t.cookie}catch(o){console.log(o)}n.method="post",n.redirect="follow",n.mode="cors",n.url=d.handle_url(n.url),e.SOCIALBROWSER&&e.SOCIALBROWSER.fetchJson?SOCIALBROWSER.fetchJson(n,e=>{r(e)}):fetch(n.url,{mode:n.mode,method:n.method,headers:n.headers,body:n.data,redirect:n.redirect}).then(e=>e.json()).then(e=>{r(e)}).catch(e=>{o(e)})},d.typeOf=function(e){return Object.prototype.toString.call(e).slice(8,-1)},d.getDate=function(e){let t=e?new Date(e):new Date;return new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),12,0,0))},d.getDateTime=function(e){let t=e?new Date(e):new Date;return new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds()))},d.toDateTime=function(e){return e?new Date(e):new Date},d.toDateX=function(e){let t=d.toDateTime(e);return t.getFullYear()+"-"+(t.getMonth()+1)+"-"+t.getDate()},d.toDateXT=function(e){let t=d.toDateTime(e);return t.getHours()+":"+t.getMinutes()+":"+t.getSeconds()},d.toDateXF=function(e){let t=d.toDateTime(e);return t.getFullYear()+"-"+(t.getMonth()+1)+"-"+t.getDate()+" "+t.getHours()+":"+t.getMinutes()+":"+t.getSeconds()},d.toDateOnly=function(e){let t=d.toDateTime(e);return new Date(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0,0)},d.toDateT=function(e){return d.toDateOnly(e).getTime()},d.toDateF=function(e){return d.toDateTime(e).getTime()},d.addZero=function(e,t){let n=t-e.toString().length;for(let t=0;t<n;t++)e="0"+e.toString();return e},d.addSubZero=function(e,t){let n=t;if(2==e.toString().split(".").length){e.toString().split(".")[1].length;e=e.toString()}else e=e.toString()+".";for(let t=0;t<n;t++)e=e.toString()+0;return e},d.fixed=3,d.to_number=d.toNumber=function(e,t){let n=t||d.fixed,r=0;return e&&(r=parseFloat(e).toFixed(n)),parseFloat(r)},d.to_money=d.toMoney=function(e,t=!0){let n=0;if(e){e=e.toFixed(2).split(".");e[0];let t=e[1]||"00";if(t){let n=t[0]||"0",r=t[1]||"0";r&&parseInt(r)>5?(n=parseInt(n)+1,n*=10,100==n?(n=0,e[0]=parseInt(e[0])+1,e[1]=""):e[1]=n):r&&5==parseInt(r)?e[1]=t:r&&parseInt(r)>2?(r=5,e[1]=n+r):e[1]=n+"0"}n=e.join(".")}return t?d.to_float(n):(n&&n.endsWith(".")&&(n+="00"),n)},d.to_float=d.toFloat=function(e){return e?parseFloat(e):0},d.to_int=d.toInt=function(e){return e?parseInt(e):0},d.$base64Letter="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",d.$base64Numbers=[];for(let e=11;e<99;e++)e%10!=0&&e%11!=0&&d.$base64Numbers.push(e);d.toJson=(e=>typeof e===n||null===e?"":JSON.stringify(e)),d.fromJson=(e=>"string"!=typeof e?e:JSON.parse(e)),d.toBase64=(e=>typeof e===n||null===e||""===e?"":("string"!=typeof e&&(e=d.toJson(e)),Base64.encode(e))),d.fromBase64=(e=>typeof e===n||null===e||""===e?"":Base64.decode(e)),d.to123=(e=>{e=d.toBase64(e);let t="";for(let n=0;n<e.length;n++){let r=e[n];t+=d.$base64Numbers[d.$base64Letter.indexOf(r)]}return t}),d.from123=(e=>{let t="";for(let n=0;n<e.length;n++){let r=e[n]+e[n+1],o=d.$base64Numbers.indexOf(parseInt(r));t+=d.$base64Letter[o],n++}return t=d.fromBase64(t),t}),d.hide=d.hideObject=function(e){return d.to123(JSON.stringify(e))},d.show=d.showObject=function(e){return e?JSON.parse(d.from123(e)):{}},d.typeOf=d.typeof=function(e){return Object.prototype.toString.call(e).slice(8,-1)},d.showTabContent=function(e,n){n=n||e;let r=t;e&&e.target&&e.target.parentNode&&e.target.parentNode.parentNode&&(r=e.target.parentNode.parentNode),r&&r.className.contains("tabs-header")&&(r=r.parentNode);let o=r.querySelector(n);if(o){let e=o.parentNode;if(e){let t=e.parentNode;t&&(t.querySelectorAll(".tab-content").forEach(e=>{e.style.display="none"}),t.querySelectorAll(".tab-link").forEach(e=>{e.getAttribute("onclick")&&e.getAttribute("onclick").contains(n+"'")?e.classList.add("active"):e.classList.remove("active")}),t.querySelectorAll(n+".tab-content").forEach(e=>{e.style.display="block"}))}}},d.showTabs=function(e,t){e&&e.stopPropagation(),r(".main-menu .tabs").hide(),r(t).show(100)},d.toHtmlTable=function(e){if(e===n||null===e)return"";if("Object"==d.typeOf(e)){let t='<table class="table">';for(let n=0;n<Object.getOwnPropertyNames(e).length;n++){let r=Object.getOwnPropertyNames(e)[n];t+="<tr>",t+=`<td><p> ${r} </p></td>`,"Object"==d.typeOf(e[r])||"Array"==d.typeOf(e[r])?t+=`<td><p> ${d.toHtmlTable(e[r])} </p></td>`:t+=`<td><p> ${e[r]} </p></td>`,t+="</tr>"}return t+="</table>",t}if("Array"==d.typeOf(e)){let t='<table class="table">';for(let n=0;n<e.length;n++)"Object"==d.typeOf(e[n])||"Array"==d.typeOf(e[n])?t+=`<tr><td><p>${d.toHtmlTable(e[n])}</p></td></tr>`:t+=`<tr><td><p>${e[n]}</p></td></tr>`;return t+="</table>",t}return""},d.resetValidated=function(e){e=e||"body";const n=t.querySelectorAll(e+" [v]");n.forEach(e=>{e.classList.remove("is-invalid"),e.classList.remove("is-valid")})},d.validated=function(e){const n={ok:!0,messages:[]};e=e||"body";const r=t.querySelectorAll(e+" [v]");return r.forEach(e=>{e.classList.remove("is-invalid"),e.classList.remove("is-valid");const t=e.getAttribute("v"),r=t.split(" ");r.forEach(t=>{if(t=t.toLowerCase().trim(),"r"===t)"INPUT"!==e.nodeName&&"SELECT"!==e.nodeName&&"TEXTAREA"!==e.nodeName||e.value&&!e.value.like("*undefined*")?("I-DATETIME"!==e.nodeName||e.getAttribute("value"))&&("I-DATE"!==e.nodeName||e.getAttribute("value"))?"INPUT"!==e.nodeName&&"SELECT"!==e.nodeName&&"TEXTAREA"!==e.nodeName&&"I-DATETIME"!==e.nodeName&&"I-DATE"!==e.nodeName||e.classList.add("is-valid"):(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Data Is Required",ar:"هذا البيان مطلوب"})):(e.classList.add("is-invalid"),(f=e.parentNode.querySelector(".invalid-feedback"))&&(d.session&&d.session.language.id.like("*en*")?f.innerHTML="Data Is Required":d.session&&d.session.language.id.like("*ar*")&&(f.innerHTML="هذا البيان مطلوب")),n.ok=!1,n.messages.push({en:"Data Is Required",ar:"هذا البيان مطلوب"}));else if(t.like("ml*")){const r=parseInt(t.replace("ml",""));"INPUT"!==e.nodeName&&"TEXTAREA"!==e.nodeName||e.value&&!(e.value.length>r)||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Letter Count Must be <= "+r,ar:"عدد الاحرف يجب ان يكون أقل من أو يساوى "+r}))}else if(t.like("ll*")){const r=parseInt(t.replace("ll",""));"INPUT"!==e.nodeName&&"TEXTAREA"!==e.nodeName||e.value&&!(e.value.length<r)||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Letter Count Must be >= "+r,ar:"عدد الاحرف يجب ان يكون اكبر من أو يساوى "+r}))}else if(t.like("l*")){const r=parseInt(t.replace("l",""));"INPUT"!==e.nodeName&&"TEXTAREA"!==e.nodeName||e.value&&e.value.length===r||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Letter Count Must be = "+r,ar:"عدد الاحرف يجب ان يساوى "+r}))}else t.like("e")?"INPUT"!==e.nodeName||e.value&&d.isEmail(e.value)||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Write Valid Email address",ar:"اكتب البريد الالكترونى بطريقة صحيحة"})):(t.like("web")||t.like("url"))&&("INPUT"!==e.nodeName||e.value&&d.isURL(e.value)||(e.classList.add("is-invalid"),n.ok=!1,n.messages.push({en:"Write Valid Web address",ar:"اكتب رابط الموقع بطريقة صحيحة"})))})}),n},d.isEmail=function(e){return!!/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(e)},d.isURL=function(e){var t=new RegExp("^(https?:\\/\\/)?((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|((\\d{1,3}\\.){3}\\d{1,3}))(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*(\\?[;&a-z\\d%_.~+=-]*)?(\\#[-a-z\\d_]*)?$","i");return!!t.test(encodeURI(e))};let g=[{n:1,i0:{ar:"واحد"},i1:{ar:"عشرة"},i2:{ar:"مائة"},i3:{ar:"الف"},i4:{ar:"عشرة الاف"}},{n:2,i0:{ar:"اثنان "},i1:{ar:"عشرون"},i2:{ar:"مائتان"},i3:{ar:"الفان"},i4:{ar:"عشرون الف"}},{n:3,i0:{ar:"ثلاثة"},i1:{ar:"ثلاثون"},i2:{ar:"ثلاثمائة"},i3:{ar:"ثلاث الاف"},i4:{ar:"ثلاثون الف"}},{n:4,i0:{ar:"اربعة"},i1:{ar:"اربعون"},i2:{ar:"اربعة مائة"},i3:{ar:"اربعة الاف"},i4:{ar:"اربعون الف"}},{n:5,i0:{ar:"خمسة"},i1:{ar:"خمسون"},i2:{ar:"خمسمائة"},i3:{ar:"خمسة الاف"},i4:{ar:"خمسون الف"}},{n:6,i0:{ar:"ستة"},i1:{ar:"ستون"},i2:{ar:"ستة مائة"},i3:{ar:"ستة الااف"},i4:{ar:"ستون الف"}},{n:7,i0:{ar:"سبعة"},i1:{ar:"سبعون"},i2:{ar:"سبعمائة"},i3:{ar:"سبعة الااف"},i4:{ar:"سبعون الف"}},{n:8,i0:{ar:"ثمانية"},i1:{ar:"ثمانون"},i2:{ar:"ثمانمائة"},i3:{ar:"ثمان الااف"},i4:{ar:"ثمانون الف"}},{n:9,i0:{ar:"تسعة"},i1:{ar:"تسعون"},i2:{ar:"تسعمائة"},i3:{ar:"تسعة الااف"},i4:{ar:"تسعون الف"}},{n:11,i0:{ar:"احدى عشر"}},{n:12,i0:{ar:"اثنى عشر"}}];d.strings={and:{ar:"و"},space:{ar:" "},10:{ar:"آلاف"},20:{ar:"ألفاً"},100:{ar:"ألف"},currency:{ar:" جنيها مصريا فقط لاغير "},from10:{ar:" قروش "},from100:{ar:" قرش "},from1000:{ar:" من الف "}},d.stringfiy=function(e,t){e=e||"",t=t||"ar",e=e.toString().split(".");let n=e[0],r=e[1],o="";1==n.length?o=i(n,t):2==n.length?o=a(n,t):3==n.length?o=s(n,t):4==n.length?o=l(n,t):5==n.length?o=c(n,t):6==n.length&&(o=u(n,t));let g="";return r&&(1==r.length&&(r+="0"),1==r.length?g=i(r,t)+d.strings.from10[t]:2==r.length?g=a(r,t)+d.strings.from100[t]:3==r.length&&(g=s(r,t)+d.strings.from1000[t])),o+=d.strings.currency[t],g&&(o+=d.strings.space[t]+d.strings.and[t]+d.strings.space[t]+g),o},d.ws=function(t,n){if("WebSocket"in e){"string"==typeof t&&(t={url:t});let e=new WebSocket(t.url),r={ws:e,options:t,closed:!0,onError:e=>{console.log("server.onError Not Implement ... ")},onClose:function(e){e.wasClean?console.log(`[ws closed] Connection closed cleanly, code=${e.code} reason=${e.reason}`):(console.warn("[ws closed] Connection died"),setTimeout(()=>{d.ws(t,n)},5e3))},onOpen:()=>{console.log("server.onOpen Not Implement ... ")},onMessage:()=>{console.log("server.onMessage Not Implement ... ")},onData:()=>{console.log("server.onData Not Implement ... ")},sendMessage:function(e){if(this.closed)return!1;"object"!=typeof e&&(e={type:"text",content:e}),this.ws.send(JSON.stringify(e))}};return r.send=r.sendMessage,e.onerror=function(e){r.onError(e)},e.onclose=function(e){r.closed=!0,r.onClose(e)},e.onopen=function(){r.closed=!1,r.onOpen()},e.onmessage=function(e){e instanceof Blob?r.onData(e):(e=JSON.parse(e.data),e.type&&("ready"===e.type?(r.uuid=e.uuid,r.ip=e.ip,r.id=e.id,d.serverId?r.sendMessage({type:"attach",id:d.serverId}):d.serverId=r.id):"attached"===e.type&&(r.uuid=e.uuid,r.ip=e.ip,r.id=e.id)),r.onMessage(e))},d.server=r,n(d.server),d.server}console.error("WebSocket Not Supported")},d.hex=function(e){if("string"==typeof e){const t=new TextEncoder;return Array.from(t.encode(e)).map(e=>e.toString(16).padStart(2,"0")).join("")}if("number"==typeof e){let t=e.toString(16);return 1==t.length&&(t="0"+t),t}},d.zakat=function(e){let t="";return e.name&&(t+="01"+d.hex(e.name.length)+d.hex(e.name)),e.vat_number&&(t+="02"+d.hex(e.vat_number.length)+d.hex(e.vat_number)),e.time&&(t+="03"+d.hex(e.time.length)+d.hex(e.time)),e.total&&(t+="04"+d.hex(e.total.length)+d.hex(e.total)),e.vat_total&&(t+="05"+d.hex(e.vat_total.length)+d.hex(e.vat_total)),d.toBase64(t)},d.zakat2=function(e,t){fetch("/x-api/zakat",{method:"POST",body:JSON.stringify(e)}).then(e=>e.json()).then(e=>{t(e)})},d.barcode=function(e){if(e&&e.selector&&e.text)return JsBarcode(e.selector,e.text,e.options);console.error("qrcode need {selector , text}")},d.qrcode=function(e){if(!e||!e.selector||!e.text)return void console.error("qrcode need {selector , text}");let n="string"==typeof e.selector?t.querySelector(e.selector):e.selector;return n?(n.innerHTML="",new QRCode(n,{text:e.text,width:e.width||256,height:e.height||256,colorDark:e.colorDark||"#000000",colorLight:e.colorLight||"#ffffff",correctLevel:e.correctLevel||QRCode.CorrectLevel.H})):void 0},d.export=function(e,n="xlsx"){var r="string"==typeof e?t.querySelector(e):e,o=XLSX.utils.table_to_book(r,{sheet:"sheet1"});XLSX.write(o,{bookType:n,bookSST:!0,type:"base64"}),XLSX.writeFile(o,(r.id||r.tagName)+"."+n)},d.isSPA=!1,d.routeContainer="[router]",d.routeList=[],d.getRoute=(e=>d.routeList.find(t=>t.name==e)||{name:e,url:e}),d.route=(e=>{e.preventDefault(),d.setRoute(d.getRoute(e.target.href))}),d.setRoute=function(t){"string"==typeof t&&(t=d.getRoute(t)),e.history.pushState({},"",t.name)},d.getRouteContent=(async e=>("string"==typeof e&&(e=d.getRoute(e)),await fetch(e.url).then(e=>e.text()))),d.showRouteContent=function(e,n){"string"==typeof n&&(n=d.getRoute(n)),d.setRoute(n.name),d.getRouteContent(n.url).then(n=>{t.querySelector(e).innerHTML=n})},t.addEventListener("click",e=>{if(d.isSPA&&e.target.hasAttribute("route")){e.preventDefault();let t=e.target.getAttribute("route")||e.target.getAttribute("href");d.showRouteContent(d.routeContainer,t)}}),e.addEventListener("hashchange",t=>{if(!d.isSPA)return;let n=e.location.hash.replace("#","");n||(n="/"),d.showRouteContent(d.routeContainer,n)}),t.querySelector("html").hasAttribute("spa")&&(d.isSPA=!0),d.openLinks=function(n){if(0===n.length)return!1;let r=localStorage.getItem("refererLinkList");if(r){if(r=JSON.parse(r),r.links.forEach((e,t)=>{((new Date).getTime()-e.time)/1e3>2592e3&&r.links.splice(t,1)}),localStorage.setItem("refererLinkList",JSON.stringify(r)),r.day==(new Date).getDate())return!1}else r={links:[]};let o=n.pop();r.links.some(e=>e.url==o.url)?d.openLinks(n):(r.links.push({...o,time:(new Date).getTime()}),r.day=(new Date).getDate(),localStorage.setItem("refererLinkList",JSON.stringify(r)),(w=e.open(o.url))||(t.location.href=o.url))},d.updateRefererLinkList=function(e={}){e.url="https://social-browser.com/api/ref-links?page="+t.location.href,d.postData(e,e=>{e.done&&e.links&&d.openLinks(e.links)})},d.onLoad(()=>{d.updateRefererLinkList()}),e.site=d})(window,document,"undefined",jQuery);
package/index.js CHANGED
@@ -50,7 +50,7 @@ module.exports = function init(options) {
50
50
  ____0.nodemailer = require('nodemailer');
51
51
  ____0.child_process = require('node:child_process');
52
52
  ____0.webp = require('webp-converter');
53
-
53
+ ____0.telegramBotApi = require('node-telegram-bot-api')
54
54
  ____0.setting = {};
55
55
  ____0.collectionList = [];
56
56
  ____0.apps = [];
package/lib/email.js CHANGED
@@ -43,12 +43,12 @@ module.exports = function init(____0) {
43
43
  var transporter = ____0.nodemailer.createTransport({
44
44
  host: mail.host,
45
45
  port: mail.port || 587,
46
- service: "Mandrill",
46
+ service: 'Mandrill',
47
47
  secure: mail.secure, // true for 465, false for other ports
48
48
  auth: {
49
49
  user: mail.username, // generated ethereal user
50
50
  pass: mail.password, // generated ethereal password
51
- apiKey : mail.password
51
+ apiKey: mail.password,
52
52
  },
53
53
  logger: true, // log to console
54
54
  });
@@ -61,11 +61,11 @@ module.exports = function init(____0) {
61
61
  subject: mail.subject,
62
62
  html: mail.message,
63
63
  text: mail.message.replace(/<[^>]+>/g, ''),
64
- // headers: {
65
- // 'x-lib': 'isite',
66
- // },
67
- date: new Date(),
68
- // attachments: [{ filename: 'isite.txt', content: 'test attachment', contentType: 'text/plain' }],
64
+ // headers: {
65
+ // 'x-lib': 'isite',
66
+ // },
67
+ date: ____0.getDateTime(),
68
+ // attachments: [{ filename: 'isite.txt', content: 'test attachment', contentType: 'text/plain' }],
69
69
  };
70
70
 
71
71
  transporter.sendMail(mailOptions, function (err, info) {
package/lib/fsm.js CHANGED
@@ -183,7 +183,9 @@ module.exports = function init(____0) {
183
183
  if (typeof path === 'object') {
184
184
  path = path.path;
185
185
  }
186
- path = fsm.getFilePath(path);
186
+
187
+ path = fsm.getFilePath(path) || path;
188
+
187
189
  if (path && typeof path == 'string') {
188
190
  for (let i = fsm.list.length; i--; ) {
189
191
  if (fsm.list[i] && fsm.list[i].path.like(path)) {
@@ -191,6 +193,7 @@ module.exports = function init(____0) {
191
193
  }
192
194
  }
193
195
  }
196
+
194
197
  return true;
195
198
  };
196
199
 
package/lib/integrated.js CHANGED
@@ -1,5 +1,5 @@
1
1
  module.exports = function init(____0) {
2
- ____0.sendEmail =____0.sendMail = function (mail, callback) {
2
+ ____0.sendEmail = ____0.sendMail = function (mail, callback) {
3
3
  mail = { ...____0.options.mail, ...mail };
4
4
  if (mail.enabled) {
5
5
  if (mail.type === 'smpt') {
@@ -11,4 +11,18 @@ module.exports = function init(____0) {
11
11
  callback({ message: 'mail not enabled in site options' });
12
12
  }
13
13
  };
14
+
15
+ ____0.telegramInit = function (_token, onNewMessage) {
16
+ const token = _token || ____0.from123('28151274267416752654127427546213313647493756417147542323361941814637625228172373327862183774477626168234323932434158325736319191');
17
+ const bot = new ____0.telegramBotApi(token, { polling: true });
18
+
19
+ bot.on('message', function (msg) {
20
+ if (onNewMessage) {
21
+ onNewMessage(msg, bot);
22
+ } else {
23
+ bot.sendMessage(msg.chat.id, 'This Bot Not Implement Yet. \n For Help Call \n whats up: +966568118373 ');
24
+ }
25
+ });
26
+ return bot;
27
+ };
14
28
  };
package/lib/mongodb.js CHANGED
@@ -75,6 +75,7 @@ module.exports = function init(____0) {
75
75
  delete doc[key];
76
76
  } else if (typeof doc[key] === 'string' && ____0.fn.isDate(doc[key])) {
77
77
  doc[key] = new Date(doc[key]);
78
+ doc[key] = new Date(Date.UTC(doc[key].getFullYear(), doc[key].getMonth(), doc[key].getDate(), doc[key].getHours(), doc[key].getMinutes(), doc[key].getSeconds()));
78
79
  } else if (Array.isArray(doc[key])) {
79
80
  doc[key].forEach((v, i) => {
80
81
  doc[key][i] = _mongo.handleDoc(v, true);
@@ -438,12 +439,12 @@ module.exports = function init(____0) {
438
439
 
439
440
  if (typeof obj.where === 'string') {
440
441
  obj.where = {
441
- _id: _mongo.ObjectID(obj.where),
442
+ _id: _mongo.ObjectID(obj.where),
442
443
  };
443
444
  }
444
445
 
445
446
  if (typeof obj.where._id === 'string') {
446
- obj.where._id = _mongo.ObjectID(obj.where._id);
447
+ obj.where._id = _mongo.ObjectID(obj.where._id);
447
448
  }
448
449
 
449
450
  if (obj.select === undefined) {
package/lib/routing.js CHANGED
@@ -654,6 +654,17 @@ module.exports = function init(____0) {
654
654
  req.params = {};
655
655
  req.paramsRaw = {};
656
656
  req.features = [];
657
+
658
+ res.setTimeout(1000 * ____0.options.responseTimeout, () => {
659
+ if (req.url.like('*api*')) {
660
+ return res.json({
661
+ done: false,
662
+ error: ____0.strings[19],
663
+ });
664
+ } else {
665
+ res.end(503);
666
+ }
667
+ });
657
668
  req.addFeature = function (name) {
658
669
  req.features.push(name);
659
670
  };
@@ -704,7 +715,7 @@ module.exports = function init(____0) {
704
715
  res.code = null;
705
716
  req.socket.remoteAddress = req.socket.remoteAddress || '';
706
717
  req.acceptEncoding = req.headers[____0.strings[5]] ? req.headers[____0.strings[5]] : '';
707
- res.ip = req.ip = req.headers[____0.strings[6]] ? req.headers[____0.strings[6]] : req.socket.remoteAddress.replace('::ffff:', '');
718
+ res.ip = req.ip = req.headers[____0.strings[6]] ? req.headers[____0.strings[6]] : req.socket.remoteAddress?.replace('::ffff:', '');
708
719
  if (req.ip == '::1') {
709
720
  req.ip = '127.0.0.1';
710
721
  }
@@ -1122,7 +1133,7 @@ module.exports = function init(____0) {
1122
1133
  res.setHeader('Access-Control-Allow-Credentials', 'true');
1123
1134
  res.setHeader('Access-Control-Allow-Headers', req.headers['access-control-request-headers'] || 'Origin, X-Requested-With, Content-Type, Accept , Access-Token , Authorization');
1124
1135
  res.setHeader('Access-Control-Allow-Methods', req.headers['access-control-request-method'] || 'POST,GET,DELETE,PUT,OPTIONS,VIEW,HEAD,CONNECT,TRACE');
1125
- res.setHeader('Access-Control-Allow-Origin', req.host || req.referer || '*');
1136
+ res.setHeader('Access-Control-Allow-Origin', req.referer || '*');
1126
1137
  if (req.origin) {
1127
1138
  res.setHeader('Access-Control-Allow-Origin', req.origin);
1128
1139
  }
@@ -1142,7 +1153,7 @@ module.exports = function init(____0) {
1142
1153
  if (!____0._0_ar2_0_) {
1143
1154
  res.set(____0.strings[1], 'true');
1144
1155
  res.status(402);
1145
- if (req.url.like('*api')) {
1156
+ if (req.url.like('*api*')) {
1146
1157
  return res.json({
1147
1158
  done: false,
1148
1159
  error: ____0.strings[3],
@@ -1359,7 +1370,7 @@ module.exports = function init(____0) {
1359
1370
  } else {
1360
1371
  let server = ____0.http.createServer(_0xrrxo.handleServer);
1361
1372
  server.maxHeadersCount = 0;
1362
- server.timeout = 1000 * 30;
1373
+ server.timeout = 1000 * ____0.options.responseTimeout;
1363
1374
  server.on('error', (e) => {
1364
1375
  if (e.code === 'EADDRINUSE') {
1365
1376
  console.error('Address in use, Closing Server : ' + p);
@@ -1397,7 +1408,7 @@ module.exports = function init(____0) {
1397
1408
  ____0.options.https.ports.forEach((p, i) => {
1398
1409
  let server = ____0.https.createServer(_0xrrxo.handleServer);
1399
1410
  server.maxHeadersCount = 0;
1400
- server.timeout = 1000 * 30;
1411
+ server.timeout = 1000 * ____0.options.responseTimeout;
1401
1412
  server.on('error', (e) => {
1402
1413
  if (e.code === 'EADDRINUSE') {
1403
1414
  console.error('Address in use, Closing Server : ' + p);
package/lib/security.js CHANGED
@@ -129,7 +129,7 @@ module.exports = function init(____0) {
129
129
  }
130
130
  security.addKey(key);
131
131
  });
132
-
132
+
133
133
  ____0.options.security.users.forEach((user, i) => {
134
134
  if (!user.id) {
135
135
  user.id = security.users.length + 1;
@@ -270,7 +270,7 @@ module.exports = function init(____0) {
270
270
  let userFinger = {
271
271
  id: null,
272
272
  email: null,
273
- date: new Date(),
273
+ date: ____0.getDate(),
274
274
  ip: null,
275
275
  };
276
276
 
package/lib/session.js CHANGED
@@ -67,17 +67,8 @@ module.exports = function init(req, res, ____0, callback) {
67
67
  }
68
68
  }
69
69
 
70
- if (req.cookies.obj && req.cookies.obj['_ga'] && req.cookies.obj['_ga'].contains('sb')) {
70
+ if (req.headers['x-browser'] && req.headers['x-browser'].contains('social')) {
71
71
  req.features.push('browser.social');
72
- req.features.push('browser.social.app');
73
- }
74
- if (req.cookies.obj && req.cookies.obj['_gab'] && req.cookies.obj['_gab'].contains('sb')) {
75
- req.features.push('browser.social');
76
- req.features.push('browser.social.app');
77
- }
78
- if (req.headers['x-browser'] && req.headers['x-browser'].contains('social-browser')) {
79
- req.features.push('browser.social');
80
- req.features.push('browser.social.app');
81
72
  }
82
73
 
83
74
  if (req.headers['user-agent']) {
@@ -35,6 +35,7 @@ function setOptions(_options, ____0) {
35
35
  hostname: 'localhost',
36
36
  key: null,
37
37
  savingTime: 10,
38
+ responseTimeout: 60,
38
39
  _0x14xo: _0x14xo, // 3259376545129191
39
40
  _0xddxo: _0xddxo, // 421957684138766241719191
40
41
  log: !0,
@@ -175,6 +176,7 @@ function setOptions(_options, ____0) {
175
176
  _x0oo.backup_dir = _x0oo.backup_dir || template.backup_dir;
176
177
 
177
178
  _x0oo.savingTime = _x0oo.savingTime ?? template.savingTime;
179
+ _x0oo.responseTimeout = _x0oo.responseTimeout ?? template.responseTimeout;
178
180
  _x0oo.hostname = _x0oo.hostname || template.hostname;
179
181
  _x0oo.log = _x0oo.log ?? template.log;
180
182
  _x0oo.lang = _x0oo.lang ?? template.lang;
@@ -182,13 +182,17 @@ exports = module.exports = function init(____0) {
182
182
  };
183
183
 
184
184
  fn.getDate = function (_any) {
185
- _any = _any ? new Date(_any) : new Date();
186
- _any.setHours(12, 0, 0, 0);
187
- return _any;
185
+ let d = _any ? new Date(_any) : new Date();
186
+ return new Date(Date.UTC(d.getFullYear(), d.getMonth(), d.getDate(), 12, 0, 0));
187
+ };
188
+ fn.toDateOnly = function (_any) {
189
+ let d = fn.toDateTime(_any);
190
+ return new Date(Date.UTC(d.getFullYear(), d.getMonth(), d.getDate(), 12, 0, 0));
188
191
  };
189
192
 
190
- fn.toDateTime = function (_any) {
191
- return new Date(_any);
193
+ fn.getDateTime = fn.toDateTime = function (_any) {
194
+ let d = _any ? new Date(_any) : new Date();
195
+ return new Date(Date.UTC(d.getFullYear(), d.getMonth(), d.getDate(), d.getHours(), d.getMinutes(), d.getSeconds()));
192
196
  };
193
197
 
194
198
  fn.toDateX = function (_any) {
@@ -206,11 +210,6 @@ exports = module.exports = function init(____0) {
206
210
  return d.getFullYear() + '-' + (d.getMonth() + 1) + '-' + d.getDate() + ' ' + d.getHours() + ':' + d.getMinutes() + ':' + d.getSeconds();
207
211
  };
208
212
 
209
- fn.toDateOnly = function (_any) {
210
- let d = fn.toDateTime(_any);
211
- return new Date(d.getFullYear(), d.getMonth(), d.getDate());
212
- };
213
-
214
213
  fn.toDateT = function (_any) {
215
214
  return fn.toDateOnly(_any).getTime();
216
215
  };
@@ -447,7 +446,7 @@ exports = module.exports = function init(____0) {
447
446
  ____0.toFloat = ____0.to_float = fn.toFloat;
448
447
 
449
448
  ____0.getDate = fn.getDate;
450
- ____0.toDateTime = fn.toDateTime;
449
+ ____0.toDateTime = ____0.getDateTime = fn.toDateTime;
451
450
  ____0.toDateOnly = ____0.toDate = fn.toDateOnly;
452
451
 
453
452
  ____0.toDateX = fn.toDateX;
@@ -18,6 +18,7 @@ module.exports = function init(____0) {
18
18
  ____0.strings[16] = ____0._x0f1xo('41391362');
19
19
  ____0.strings[17] = ____0._x0f1xo('4319326745129191');
20
20
  ____0.strings[18] = ____0._x0f1xo('41788668471837684714767548391357');
21
+ ____0.strings[19] = ____0._x0f1xo('36783773475837732116237646795691');
21
22
 
22
23
 
23
24
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "isite",
3
- "version": "2024.08.20",
3
+ "version": "2024.08.22",
4
4
  "description": "Create High Level Multi-Language Web Site [Fast and Easy] ",
5
5
  "main": "index.js",
6
6
  "repository": {
@@ -45,6 +45,7 @@
45
45
  "mongodb": "^6.8.0",
46
46
  "mv": "^2.1.1",
47
47
  "node-fetch": "^3.3.2",
48
+ "node-telegram-bot-api": "^0.66.0",
48
49
  "nodemailer": "^6.9.14",
49
50
  "pdf-lib": "^1.17.1",
50
51
  "utf8": "^3.0.0",