@bbn/bbn 1.0.30 → 1.0.32

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.
Files changed (237) hide show
  1. package/dist/bundle.d.ts +8 -8
  2. package/dist/bundle.js +12 -12
  3. package/dist/fn/_addLoader.js +3 -6
  4. package/dist/fn/_compareValues.js +11 -14
  5. package/dist/fn/_deleteLoader.js +7 -10
  6. package/dist/fn/abort.js +3 -6
  7. package/dist/fn/abortURL.js +4 -7
  8. package/dist/fn/addColors.js +5 -8
  9. package/dist/fn/addInputs.js +3 -6
  10. package/dist/fn/addStyle.js +5 -8
  11. package/dist/fn/adjustHeight.js +5 -8
  12. package/dist/fn/adjustSize.js +5 -8
  13. package/dist/fn/adjustWidth.js +5 -8
  14. package/dist/fn/ajax.js +31 -34
  15. package/dist/fn/analyzeFunction.js +3 -6
  16. package/dist/fn/animateCss.js +1 -4
  17. package/dist/fn/arrayBuffer2String.js +1 -4
  18. package/dist/fn/arrayFromProp.js +5 -8
  19. package/dist/fn/autoExtend.js +4 -7
  20. package/dist/fn/baseName.js +6 -9
  21. package/dist/fn/br2nl.js +3 -6
  22. package/dist/fn/calendar.js +10 -15
  23. package/dist/fn/callback.js +16 -19
  24. package/dist/fn/camelToCss.js +1 -4
  25. package/dist/fn/camelize.js +1 -4
  26. package/dist/fn/canvasToImage.js +1 -4
  27. package/dist/fn/center.js +1 -4
  28. package/dist/fn/checkProps.js +3 -6
  29. package/dist/fn/checkPropsDetails.js +9 -12
  30. package/dist/fn/checkPropsOrDie.js +3 -6
  31. package/dist/fn/checkType.js +16 -19
  32. package/dist/fn/chrono.js +3 -7
  33. package/dist/fn/circularReplacer.js +7 -10
  34. package/dist/fn/clone.js +7 -10
  35. package/dist/fn/colorToHex.js +1 -4
  36. package/dist/fn/compare.js +18 -21
  37. package/dist/fn/compareConditions.js +10 -13
  38. package/dist/fn/copy.js +4 -7
  39. package/dist/fn/correctCase.js +1 -4
  40. package/dist/fn/count.js +3 -6
  41. package/dist/fn/crc32.js +1 -4
  42. package/dist/fn/createObject.js +3 -6
  43. package/dist/fn/cssExists.js +3 -6
  44. package/dist/fn/date.js +8 -11
  45. package/dist/fn/dateSQL.d.ts +1 -1
  46. package/dist/fn/dateSQL.js +3 -7
  47. package/dist/fn/daysInMonth.d.ts +1 -1
  48. package/dist/fn/daysInMonth.js +3 -7
  49. package/dist/fn/deepPath.js +7 -10
  50. package/dist/fn/defaultAjaxAbortFunction.js +3 -6
  51. package/dist/fn/defaultAjaxErrorFunction.d.ts +1 -1
  52. package/dist/fn/defaultAjaxErrorFunction.js +1 -4
  53. package/dist/fn/defaultAlertFunction.js +1 -4
  54. package/dist/fn/defaultConfirmFunction.js +4 -7
  55. package/dist/fn/defaultEndLoadingFunction.js +1 -4
  56. package/dist/fn/defaultErrorFunction.js +3 -6
  57. package/dist/fn/defaultHistoryFunction.js +1 -4
  58. package/dist/fn/defaultLinkFunction.js +1 -4
  59. package/dist/fn/defaultPostLinkFunction.js +1 -4
  60. package/dist/fn/defaultPreLinkFunction.js +1 -4
  61. package/dist/fn/defaultResizeFunction.js +1 -4
  62. package/dist/fn/defaultStartLoadingFunction.js +1 -4
  63. package/dist/fn/deleteProp.js +4 -7
  64. package/dist/fn/diffObj.js +16 -19
  65. package/dist/fn/dirName.js +7 -10
  66. package/dist/fn/download.js +15 -18
  67. package/dist/fn/downloadContent.js +9 -12
  68. package/dist/fn/each.js +7 -10
  69. package/dist/fn/eraseCookie.js +1 -4
  70. package/dist/fn/error.js +3 -6
  71. package/dist/fn/escapeDquotes.js +3 -6
  72. package/dist/fn/escapeRegExp.js +1 -4
  73. package/dist/fn/escapeSquotes.js +3 -6
  74. package/dist/fn/escapeTicks.js +3 -6
  75. package/dist/fn/escapeUrl.js +8 -11
  76. package/dist/fn/extend.js +13 -16
  77. package/dist/fn/extendOut.js +4 -7
  78. package/dist/fn/fdate.js +9 -13
  79. package/dist/fn/fdatetime.js +7 -11
  80. package/dist/fn/fieldValue.js +1 -4
  81. package/dist/fn/fileExt.js +3 -6
  82. package/dist/fn/filter.js +12 -15
  83. package/dist/fn/filterToConditions.js +8 -11
  84. package/dist/fn/findAll.js +7 -10
  85. package/dist/fn/fori.js +6 -9
  86. package/dist/fn/forir.js +6 -9
  87. package/dist/fn/format.js +3 -6
  88. package/dist/fn/formatBytes.js +1 -4
  89. package/dist/fn/formatDate.d.ts +1 -1
  90. package/dist/fn/formatDate.js +1 -5
  91. package/dist/fn/formatSize.js +5 -8
  92. package/dist/fn/formdata.js +11 -14
  93. package/dist/fn/fromXml.js +1 -4
  94. package/dist/fn/ftime.js +8 -13
  95. package/dist/fn/getAllTags.js +3 -6
  96. package/dist/fn/getAncestors.js +1 -4
  97. package/dist/fn/getAttributes.js +3 -6
  98. package/dist/fn/getBrowserName.js +1 -4
  99. package/dist/fn/getBrowserVersion.js +1 -4
  100. package/dist/fn/getCookie.js +1 -4
  101. package/dist/fn/getCssVar.js +1 -4
  102. package/dist/fn/getDay.js +3 -6
  103. package/dist/fn/getDeviceType.js +1 -4
  104. package/dist/fn/getEventData.js +7 -10
  105. package/dist/fn/getField.js +3 -6
  106. package/dist/fn/getFieldValues.js +7 -10
  107. package/dist/fn/getHTMLOfSelection.js +4 -7
  108. package/dist/fn/getHtml.js +3 -6
  109. package/dist/fn/getLoader.js +3 -6
  110. package/dist/fn/getPath.js +3 -6
  111. package/dist/fn/getProp.js +4 -7
  112. package/dist/fn/getProperty.js +1 -4
  113. package/dist/fn/getRequestId.js +5 -8
  114. package/dist/fn/getRow.js +3 -6
  115. package/dist/fn/getScrollBarSize.js +1 -4
  116. package/dist/fn/getText.js +1 -4
  117. package/dist/fn/getTimeoff.js +1 -4
  118. package/dist/fn/happy.js +3 -6
  119. package/dist/fn/hash.js +11 -14
  120. package/dist/fn/hex2rgb.js +1 -4
  121. package/dist/fn/history.js +1 -4
  122. package/dist/fn/html2text.js +1 -4
  123. package/dist/fn/imageToCanvas.js +1 -4
  124. package/dist/fn/imgToBase64.js +3 -6
  125. package/dist/fn/info.js +3 -6
  126. package/dist/fn/init.js +31 -35
  127. package/dist/fn/isActiveInterface.js +1 -4
  128. package/dist/fn/isArray.js +1 -4
  129. package/dist/fn/isBlob.js +1 -4
  130. package/dist/fn/isBoolean.js +1 -4
  131. package/dist/fn/isCanvas.js +1 -4
  132. package/dist/fn/isColor.js +3 -6
  133. package/dist/fn/isComment.js +1 -4
  134. package/dist/fn/isCp.js +3 -6
  135. package/dist/fn/isDate.js +1 -4
  136. package/dist/fn/isDesktopDevice.js +1 -4
  137. package/dist/fn/isDimension.js +3 -6
  138. package/dist/fn/isDom.js +1 -4
  139. package/dist/fn/isEmail.js +3 -6
  140. package/dist/fn/isEmpty.js +5 -8
  141. package/dist/fn/isEvent.js +1 -4
  142. package/dist/fn/isFocused.js +1 -4
  143. package/dist/fn/isFunction.js +1 -4
  144. package/dist/fn/isHostname.js +5 -8
  145. package/dist/fn/isIP.js +3 -6
  146. package/dist/fn/isInside.js +7 -10
  147. package/dist/fn/isInt.js +1 -4
  148. package/dist/fn/isIterable.js +1 -4
  149. package/dist/fn/isMobile.js +4 -7
  150. package/dist/fn/isMobileDevice.js +1 -4
  151. package/dist/fn/isNull.js +1 -4
  152. package/dist/fn/isNumber.js +1 -4
  153. package/dist/fn/isObject.js +1 -4
  154. package/dist/fn/isPercent.js +1 -4
  155. package/dist/fn/isPrimitive.js +1 -4
  156. package/dist/fn/isPromise.js +1 -4
  157. package/dist/fn/isPropSize.js +3 -6
  158. package/dist/fn/isSQLDate.js +1 -4
  159. package/dist/fn/isSame.js +5 -8
  160. package/dist/fn/isString.js +1 -4
  161. package/dist/fn/isSymbol.js +1 -4
  162. package/dist/fn/isTabletDevice.js +1 -4
  163. package/dist/fn/isURL.js +1 -4
  164. package/dist/fn/isValidDimension.js +4 -7
  165. package/dist/fn/isValidName.js +3 -6
  166. package/dist/fn/isValue.js +3 -6
  167. package/dist/fn/isVue.js +1 -4
  168. package/dist/fn/iterate.js +5 -8
  169. package/dist/fn/lightenDarkenHex.js +1 -4
  170. package/dist/fn/link.js +19 -22
  171. package/dist/fn/log.js +3 -6
  172. package/dist/fn/makeReactive.js +28 -31
  173. package/dist/fn/map.js +3 -6
  174. package/dist/fn/md5.js +1 -4
  175. package/dist/fn/money.js +3 -6
  176. package/dist/fn/move.js +1 -4
  177. package/dist/fn/multiorder.js +3 -6
  178. package/dist/fn/nl2br.js +3 -6
  179. package/dist/fn/numProperties.js +1 -4
  180. package/dist/fn/objectToFormData.js +12 -15
  181. package/dist/fn/order.js +3 -6
  182. package/dist/fn/outerHeight.js +3 -6
  183. package/dist/fn/outerWidth.js +3 -6
  184. package/dist/fn/percent.js +1 -4
  185. package/dist/fn/pickValue.js +1 -4
  186. package/dist/fn/post.js +7 -10
  187. package/dist/fn/postOut.js +5 -8
  188. package/dist/fn/printf.js +1 -4
  189. package/dist/fn/quotes2html.js +4 -7
  190. package/dist/fn/randomInt.js +1 -4
  191. package/dist/fn/randomString.js +4 -7
  192. package/dist/fn/removeAccents.js +5 -8
  193. package/dist/fn/removeEmpty.js +8 -11
  194. package/dist/fn/removeExtraSpaces.js +1 -4
  195. package/dist/fn/removeHtmlComments.js +3 -6
  196. package/dist/fn/removePrivateProp.js +3 -6
  197. package/dist/fn/removeTrailingChars.js +6 -9
  198. package/dist/fn/repeat.js +1 -4
  199. package/dist/fn/replaceAll.js +4 -7
  200. package/dist/fn/replaceSelection.js +1 -4
  201. package/dist/fn/resize.js +7 -10
  202. package/dist/fn/rgb2hex.js +1 -4
  203. package/dist/fn/riterate.js +3 -6
  204. package/dist/fn/roundDecimal.js +1 -4
  205. package/dist/fn/sanitize.js +5 -8
  206. package/dist/fn/search.js +15 -18
  207. package/dist/fn/selectElementText.js +1 -4
  208. package/dist/fn/selector.js +1 -4
  209. package/dist/fn/setCookie.js +1 -4
  210. package/dist/fn/setCssVar.js +1 -4
  211. package/dist/fn/setNavigationVars.js +10 -13
  212. package/dist/fn/setProp.js +1 -4
  213. package/dist/fn/setProperty.js +3 -6
  214. package/dist/fn/shorten.js +5 -8
  215. package/dist/fn/shortenObj.js +9 -12
  216. package/dist/fn/shuffle.js +1 -4
  217. package/dist/fn/simpleHash.js +5 -8
  218. package/dist/fn/simpleHash1.js +1 -4
  219. package/dist/fn/simpleHash2.js +1 -4
  220. package/dist/fn/stat.js +1 -4
  221. package/dist/fn/string2ArrayBuffer.js +1 -4
  222. package/dist/fn/submit.js +6 -9
  223. package/dist/fn/substr.js +7 -10
  224. package/dist/fn/sum.js +4 -7
  225. package/dist/fn/timestamp.js +1 -4
  226. package/dist/fn/toCSV.js +8 -11
  227. package/dist/fn/toggleFullScreen.js +3 -6
  228. package/dist/fn/translate.js +3 -6
  229. package/dist/fn/treatAjaxArguments.js +10 -13
  230. package/dist/fn/trim.js +4 -7
  231. package/dist/fn/uniqString.js +7 -10
  232. package/dist/fn/unique.js +1 -4
  233. package/dist/fn/upload.js +6 -10
  234. package/dist/fn/warning.js +3 -6
  235. package/dist/index.d.ts +4 -4
  236. package/dist/index.js +459 -471
  237. package/package.json +1 -1
package/dist/fn/init.js CHANGED
@@ -1,28 +1,24 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.init = void 0;
4
- const dayjs = require("../../node_modules/dayjs/index");
5
- const substr_1 = require("./substr");
6
- const each_1 = require("./each");
7
- const extend_1 = require("./extend");
8
- const addColors_1 = require("./addColors");
9
- const link_1 = require("./link");
10
- const submit_1 = require("./submit");
11
- const resize_1 = require("./resize");
12
- const isMobile_1 = require("./isMobile");
13
- const isTabletDevice_1 = require("./isTabletDevice");
14
- const defaultHistoryFunction_1 = require("./defaultHistoryFunction");
15
- const isFunction_1 = require("./isFunction");
16
- const log_1 = require("./log");
1
+ import { substr } from './substr';
2
+ import { each } from './each';
3
+ import { extend } from './extend';
4
+ import { addColors } from './addColors';
5
+ import { link } from './link';
6
+ import { submit } from './submit';
7
+ import { resize } from './resize';
8
+ import { isMobile } from './isMobile';
9
+ import { isTabletDevice } from './isTabletDevice';
10
+ import { defaultHistoryFunction } from './defaultHistoryFunction';
11
+ import { isFunction } from './isFunction';
12
+ import { log } from './log';
17
13
  const init = function (cfg, force) {
18
14
  let parts;
19
15
  if (!bbn.env.isInit || force) {
20
16
  bbn.env.root = document.baseURI.length > 0 ? document.baseURI : bbn.env.host;
21
- if (bbn.env.root.length && (0, substr_1.substr)(bbn.env.root, -1) !== '/') {
17
+ if (bbn.env.root.length && substr(bbn.env.root, -1) !== '/') {
22
18
  bbn.env.root += '/';
23
19
  }
24
20
  if (!bbn.env.isInit && typeof dayjs !== 'undefined') {
25
- (0, each_1.each)([
21
+ each([
26
22
  'advancedFormat',
27
23
  'arraySupport',
28
24
  'badMutable',
@@ -64,19 +60,19 @@ const init = function (cfg, force) {
64
60
  }
65
61
  /* The server's path (difference between the host and the current dir */
66
62
  if (typeof cfg === 'object') {
67
- (0, extend_1.extend)(true, bbn, cfg);
63
+ extend(true, bbn, cfg);
68
64
  }
69
- bbn.env.path = (0, substr_1.substr)(bbn.env.url, bbn.env.root.length);
65
+ bbn.env.path = substr(bbn.env.url, bbn.env.root.length);
70
66
  parts = bbn.env.path.split('/');
71
67
  //$.each(parts, function(i, v){
72
- (0, each_1.each)(parts, (v, i) => {
68
+ each(parts, (v, i) => {
73
69
  v = decodeURI(v.trim());
74
70
  if (v !== '') {
75
71
  bbn.env.params.push(v);
76
72
  }
77
73
  });
78
74
  if (bbn.vars.colors) {
79
- (0, addColors_1.addColors)(bbn.vars.colors);
75
+ addColors(bbn.vars.colors);
80
76
  }
81
77
  if (bbn.env.lang && undefined !== dayjs) {
82
78
  dayjs.locale(bbn.env.lang);
@@ -118,28 +114,28 @@ const init = function (cfg, force) {
118
114
  if (target instanceof HTMLElement && target.hasAttribute('href') && !target.hasAttribute('target') && !target.classList.contains('bbn-no')) {
119
115
  e.preventDefault();
120
116
  e.stopPropagation();
121
- (0, link_1.link)(target.getAttribute('href'));
117
+ link(target.getAttribute('href'));
122
118
  return false;
123
119
  }
124
120
  });
125
- (0, each_1.each)(document.querySelectorAll('form:not(.bbn-no), form:not(.bbn-form)'), (ele) => {
121
+ each(document.querySelectorAll('form:not(.bbn-no), form:not(.bbn-form)'), (ele) => {
126
122
  ele.addEventListener('submit', (e) => {
127
- (0, submit_1.submit)(ele, e);
123
+ submit(ele, e);
128
124
  });
129
125
  });
130
126
  window.addEventListener('hashchange', () => {
131
127
  bbn.env.hashChanged = new Date().getTime();
132
128
  }, false);
133
129
  window.addEventListener('resize', () => {
134
- (0, resize_1.resize)();
130
+ resize();
135
131
  });
136
132
  window.addEventListener('orientationchange', () => {
137
- (0, resize_1.resize)();
133
+ resize();
138
134
  });
139
- (0, resize_1.resize)();
140
- if ((0, isMobile_1.isMobile)()) {
135
+ resize();
136
+ if (isMobile()) {
141
137
  document.body.classList.add('bbn-mobile');
142
- if ((0, isTabletDevice_1.isTabletDevice)()) {
138
+ if (isTabletDevice()) {
143
139
  document.body.classList.add('bbn-tablet');
144
140
  }
145
141
  }
@@ -150,11 +146,11 @@ const init = function (cfg, force) {
150
146
  //e.preventDefault();
151
147
  let state = h.state;
152
148
  if (state) {
153
- if ((0, defaultHistoryFunction_1.defaultHistoryFunction)(state)) {
149
+ if (defaultHistoryFunction(state)) {
154
150
  //link(substr(state.url, bbn.env.root.length), $.extend({title: state.title}, state.data));
155
- (0, link_1.link)(state.url, (0, extend_1.extend)({ title: state.title || bbn.env.siteTitle }, state.data || {}));
151
+ link(state.url, extend({ title: state.title || bbn.env.siteTitle }, state.data || {}));
156
152
  }
157
- else if (state && state.data && (0, isFunction_1.isFunction)(state.data.script)) {
153
+ else if (state && state.data && isFunction(state.data.script)) {
158
154
  state.data.script();
159
155
  }
160
156
  }
@@ -164,8 +160,8 @@ const init = function (cfg, force) {
164
160
  bbn.env.isInit = true;
165
161
  document.dispatchEvent(new Event('bbninit'));
166
162
  if (bbn.env.logging) {
167
- (0, log_1.log)('Logging in bbn is enabled');
163
+ log('Logging in bbn is enabled');
168
164
  }
169
165
  }
170
166
  };
171
- exports.init = init;
167
+ export { init };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isActiveInterface = void 0;
4
1
  const isActiveInterface = function (secs = 600) {
5
2
  if (!bbn.env.last_focus) {
6
3
  return false;
@@ -8,4 +5,4 @@ const isActiveInterface = function (secs = 600) {
8
5
  let t = new Date().getTime();
9
6
  return t - bbn.env.last_focus < secs * 1000;
10
7
  };
11
- exports.isActiveInterface = isActiveInterface;
8
+ export { isActiveInterface };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isArray = void 0;
4
1
  const isArray = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isArray = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isArray = isArray;
11
+ export { isArray };
package/dist/fn/isBlob.js CHANGED
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isBlob = void 0;
4
1
  const isBlob = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isBlob = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isBlob = isBlob;
11
+ export { isBlob };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isBoolean = void 0;
4
1
  const isBoolean = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isBoolean = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isBoolean = isBoolean;
11
+ export { isBoolean };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isCanvas = void 0;
4
1
  const isCanvas = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isCanvas = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isCanvas = isCanvas;
11
+ export { isCanvas };
@@ -1,13 +1,10 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isColor = void 0;
4
- const isString_1 = require("./isString");
1
+ import { isString } from './isString';
5
2
  const isColor = function (...args) {
6
3
  if (!args.length)
7
4
  return false;
8
5
  var reg = new RegExp('^(#[a-f0-9]{6}|#[a-f0-9]{3}|rgb *( *[0-9]{1,3}%? *, *[0-9]{1,3}%? *, *[0-9]{1,3}%? *)|rgba *( *[0-9]{1,3}%? *, *[0-9]{1,3}%? *, *[0-9]{1,3}%? *, *[0-9]{1,3}%? *)|black|green|silver|gray|olive|white|yellow|maroon|navy|red|blue|purple|teal|fuchsia|aqua)$', 'i');
9
6
  for (let st of args) {
10
- if (!(0, isString_1.isString)(st)) {
7
+ if (!isString(st)) {
11
8
  return false;
12
9
  }
13
10
  if (!reg.test(st)) {
@@ -16,4 +13,4 @@ const isColor = function (...args) {
16
13
  }
17
14
  return true;
18
15
  };
19
- exports.isColor = isColor;
16
+ export { isColor };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isComment = void 0;
4
1
  const isComment = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isComment = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isComment = isComment;
11
+ export { isComment };
package/dist/fn/isCp.js CHANGED
@@ -1,7 +1,4 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isCp = void 0;
4
- const isDom_1 = require("./isDom");
1
+ import { isDom } from './isDom';
5
2
  const isCp = function (...args) {
6
3
  if (!args.length) {
7
4
  return false;
@@ -9,7 +6,7 @@ const isCp = function (...args) {
9
6
  if ('cp' in bbn && 'isComponent' in bbn['cp'] && (typeof bbn['cp'].isComponent === 'function')) {
10
7
  for (let a of args) {
11
8
  let res = bbn.cp.isComponent(a);
12
- if (!res || (0, isDom_1.isDom)(res) || !res.$el) {
9
+ if (!res || isDom(res) || !res.$el) {
13
10
  return false;
14
11
  }
15
12
  }
@@ -17,4 +14,4 @@ const isCp = function (...args) {
17
14
  }
18
15
  return true;
19
16
  };
20
- exports.isCp = isCp;
17
+ export { isCp };
package/dist/fn/isDate.js CHANGED
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isDate = void 0;
4
1
  const isDate = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isDate = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isDate = isDate;
11
+ export { isDate };
@@ -1,7 +1,4 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isDesktopDevice = void 0;
4
1
  const isDesktopDevice = function () {
5
2
  return this.getDeviceType() === 'desktop';
6
3
  };
7
- exports.isDesktopDevice = isDesktopDevice;
4
+ export { isDesktopDevice };
@@ -1,7 +1,4 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isDimension = void 0;
4
- const isValidDimension_1 = require("./isValidDimension");
1
+ import { isValidDimension } from './isValidDimension';
5
2
  const isDimension = function (...args) {
6
3
  if (!args.length)
7
4
  return false;
@@ -9,10 +6,10 @@ const isDimension = function (...args) {
9
6
  if ((typeof st !== 'number') || (st < 0)) {
10
7
  return false;
11
8
  }
12
- if (!(0, isValidDimension_1.isValidDimension)(st)) {
9
+ if (!isValidDimension(st)) {
13
10
  return false;
14
11
  }
15
12
  }
16
13
  return true;
17
14
  };
18
- exports.isDimension = isDimension;
15
+ export { isDimension };
package/dist/fn/isDom.js CHANGED
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isDom = void 0;
4
1
  const isDom = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isDom = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isDom = isDom;
11
+ export { isDom };
@@ -1,13 +1,10 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isEmail = void 0;
4
- const isString_1 = require("./isString");
1
+ import { isString } from './isString';
5
2
  const isEmail = function (...args) {
6
3
  if (!args.length)
7
4
  return false;
8
5
  let regex = /^([a-zA-Z0-9_.+-])+\@(([a-zA-Z0-9-])+\.)+([a-zA-Z0-9]{2,4})+$/;
9
6
  for (let st of args) {
10
- if (!(0, isString_1.isString)(st)) {
7
+ if (!isString(st)) {
11
8
  return false;
12
9
  }
13
10
  if (!regex.test(st)) {
@@ -16,4 +13,4 @@ const isEmail = function (...args) {
16
13
  }
17
14
  return true;
18
15
  };
19
- exports.isEmail = isEmail;
16
+ export { isEmail };
@@ -1,21 +1,18 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isEmpty = void 0;
4
- const isArray_1 = require("./isArray");
5
- const numProperties_1 = require("./numProperties");
1
+ import { isArray } from './isArray';
2
+ import { numProperties } from './numProperties';
6
3
  const isEmpty = function (obj) {
7
4
  if (!obj) {
8
5
  return true;
9
6
  }
10
- if ((0, isArray_1.isArray)(obj)) {
7
+ if (isArray(obj)) {
11
8
  return obj.length ? false : true;
12
9
  }
13
10
  if (typeof obj === 'object') {
14
- if ((0, numProperties_1.numProperties)(obj)) {
11
+ if (numProperties(obj)) {
15
12
  return false;
16
13
  }
17
14
  return true;
18
15
  }
19
16
  return false;
20
17
  };
21
- exports.isEmpty = isEmpty;
18
+ export { isEmpty };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isEvent = void 0;
4
1
  const isEvent = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isEvent = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isEvent = isEvent;
11
+ export { isEvent };
@@ -1,7 +1,4 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isFocused = void 0;
4
1
  const isFocused = function (ele, contain) {
5
2
  return ele === document.activeElement || (contain && ele.contains && ele.contains(document.activeElement));
6
3
  };
7
- exports.isFocused = isFocused;
4
+ export { isFocused };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isFunction = void 0;
4
1
  const isFunction = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isFunction = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isFunction = isFunction;
11
+ export { isFunction };
@@ -1,19 +1,16 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isHostname = void 0;
4
- const isString_1 = require("./isString");
5
- const isIP_1 = require("./isIP");
1
+ import { isString } from './isString';
2
+ import { isIP } from './isIP';
6
3
  const isHostname = function (...args) {
7
4
  if (!args.length)
8
5
  return false;
9
6
  for (let st of args) {
10
- if (!(0, isString_1.isString)(st)) {
7
+ if (!isString(st)) {
11
8
  return false;
12
9
  }
13
- if (!(0, isIP_1.isIP)(st) && !bbn.vars.regexp.hostname.test(st)) {
10
+ if (!isIP(st) && !bbn.vars.regexp.hostname.test(st)) {
14
11
  return false;
15
12
  }
16
13
  }
17
14
  return true;
18
15
  };
19
- exports.isHostname = isHostname;
16
+ export { isHostname };
package/dist/fn/isIP.js CHANGED
@@ -1,15 +1,12 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isIP = void 0;
4
- const isString_1 = require("./isString");
1
+ import { isString } from './isString';
5
2
  const isIP = function (...args) {
6
3
  if (!args.length)
7
4
  return false;
8
5
  for (let st of args) {
9
- if (!(0, isString_1.isString)(st) || !bbn.vars.regexp.ip.test(st)) {
6
+ if (!isString(st) || !bbn.vars.regexp.ip.test(st)) {
10
7
  return false;
11
8
  }
12
9
  }
13
10
  return true;
14
11
  };
15
- exports.isIP = isIP;
12
+ export { isIP };
@@ -1,15 +1,12 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isInside = void 0;
4
- const getAncestors_1 = require("./getAncestors");
5
- const isString_1 = require("./isString");
6
- const each_1 = require("./each");
1
+ import { getAncestors } from './getAncestors';
2
+ import { isString } from './isString';
3
+ import { each } from './each';
7
4
  const isInside = function (ele, ancestor) {
8
- let ancestors = (0, getAncestors_1.getAncestors)(ele);
5
+ let ancestors = getAncestors(ele);
9
6
  if (ancestors.length) {
10
- if ((0, isString_1.isString)(ancestor)) {
7
+ if (isString(ancestor)) {
11
8
  let ok = false;
12
- (0, each_1.each)(ancestors, (a) => {
9
+ each(ancestors, (a) => {
13
10
  if (a.matches && a.matches(ancestor)) {
14
11
  ok = true;
15
12
  return false;
@@ -23,4 +20,4 @@ const isInside = function (ele, ancestor) {
23
20
  }
24
21
  return false;
25
22
  };
26
- exports.isInside = isInside;
23
+ export { isInside };
package/dist/fn/isInt.js CHANGED
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isInt = void 0;
4
1
  const isInt = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isInt = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isInt = isInt;
11
+ export { isInt };
@@ -1,7 +1,4 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isIterable = void 0;
4
1
  const isIterable = function (v) {
5
2
  return v && typeof v === 'object' && Symbol.iterator in Object(v);
6
3
  };
7
- exports.isIterable = isIterable;
4
+ export { isIterable };
@@ -1,9 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isMobile = void 0;
4
- const isMobileDevice_1 = require("./isMobileDevice");
5
- const isTabletDevice_1 = require("./isTabletDevice");
1
+ import { isMobileDevice } from './isMobileDevice';
2
+ import { isTabletDevice } from './isTabletDevice';
6
3
  const isMobile = function () {
7
- return (0, isMobileDevice_1.isMobileDevice)() || (0, isTabletDevice_1.isTabletDevice)();
4
+ return isMobileDevice() || isTabletDevice();
8
5
  };
9
- exports.isMobile = isMobile;
6
+ export { isMobile };
@@ -1,7 +1,4 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isMobileDevice = void 0;
4
1
  const isMobileDevice = function () {
5
2
  return this.getDeviceType() === 'mobile';
6
3
  };
7
- exports.isMobileDevice = isMobileDevice;
4
+ export { isMobileDevice };
package/dist/fn/isNull.js CHANGED
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isNull = void 0;
4
1
  const isNull = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isNull = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isNull = isNull;
11
+ export { isNull };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isNumber = void 0;
4
1
  const isNumber = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isNumber = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isNumber = isNumber;
11
+ export { isNumber };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isObject = void 0;
4
1
  const isObject = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isObject = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isObject = isObject;
11
+ export { isObject };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isPercent = void 0;
4
1
  const isPercent = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isPercent = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isPercent = isPercent;
11
+ export { isPercent };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isPrimitive = void 0;
4
1
  const isPrimitive = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isPrimitive = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isPrimitive = isPrimitive;
11
+ export { isPrimitive };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isPromise = void 0;
4
1
  const isPromise = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -11,4 +8,4 @@ const isPromise = function (...args) {
11
8
  }
12
9
  return true;
13
10
  };
14
- exports.isPromise = isPromise;
11
+ export { isPromise };
@@ -1,10 +1,7 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isPropSize = void 0;
4
- const each_1 = require("./each");
1
+ import { each } from './each';
5
2
  const isPropSize = function (name) {
6
3
  let isTrue = false;
7
- (0, each_1.each)(['width', 'height', 'gap', 'margin', 'padding', 'top', 'left', 'right', 'bottom'], (a) => {
4
+ each(['width', 'height', 'gap', 'margin', 'padding', 'top', 'left', 'right', 'bottom'], (a) => {
8
5
  if (name.indexOf(a) !== -1) {
9
6
  isTrue = true;
10
7
  return false;
@@ -12,4 +9,4 @@ const isPropSize = function (name) {
12
9
  });
13
10
  return isTrue;
14
11
  };
15
- exports.isPropSize = isPropSize;
12
+ export { isPropSize };
@@ -1,6 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isSQLDate = void 0;
4
1
  const isSQLDate = function (...args) {
5
2
  if (!args.length)
6
3
  return false;
@@ -12,4 +9,4 @@ const isSQLDate = function (...args) {
12
9
  }
13
10
  return true;
14
11
  };
15
- exports.isSQLDate = isSQLDate;
12
+ export { isSQLDate };