@bbn/bbn 1.0.76 → 1.0.78
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle.d.ts +2 -2
- package/dist/bundle.js +3 -3
- package/dist/fn/ajax/callback.d.ts +1 -1
- package/dist/fn/ajax/callback.js +3 -3
- package/dist/fn.d.ts +1 -1
- package/package.json +1 -1
package/dist/bundle.d.ts
CHANGED
|
@@ -1851,7 +1851,7 @@ declare module "fn/ajax/callback" {
|
|
|
1851
1851
|
*
|
|
1852
1852
|
* @returns {*} The result of the main callback function: res.script, fn, or bbn.fn.defaultLinkFunction
|
|
1853
1853
|
*/
|
|
1854
|
-
const callback: (url:
|
|
1854
|
+
const callback: (url: any, res: any, fn?: any, fn2?: any, ele?: any) => boolean;
|
|
1855
1855
|
export { callback };
|
|
1856
1856
|
}
|
|
1857
1857
|
declare module "fn/string/camelize" {
|
|
@@ -4675,7 +4675,7 @@ declare module "fn" {
|
|
|
4675
4675
|
baseName: (path: string, suffix?: string) => string;
|
|
4676
4676
|
br2nl: (st: any) => string;
|
|
4677
4677
|
calendar: (d?: string | number | Date, wrong_result?: string) => any;
|
|
4678
|
-
callback: (url:
|
|
4678
|
+
callback: (url: any, res: any, fn?: any, fn2?: any, ele?: any) => boolean;
|
|
4679
4679
|
camelize: (str: any) => any;
|
|
4680
4680
|
camelToCss: (str: any) => any;
|
|
4681
4681
|
canvasToImage: (canvas: any) => HTMLImageElement;
|
package/dist/bundle.js
CHANGED
|
@@ -3793,7 +3793,7 @@
|
|
|
3793
3793
|
*
|
|
3794
3794
|
* @returns {*} The result of the main callback function: res.script, fn, or bbn.fn.defaultLinkFunction
|
|
3795
3795
|
*/
|
|
3796
|
-
const callback = function (url, res
|
|
3796
|
+
const callback = function (url, res, fn = null, fn2 = null, ele = null) {
|
|
3797
3797
|
let tmp = false;
|
|
3798
3798
|
if (res) {
|
|
3799
3799
|
tmp = true;
|
|
@@ -3813,7 +3813,7 @@
|
|
|
3813
3813
|
res.url = url;
|
|
3814
3814
|
}
|
|
3815
3815
|
/* Case where a callback is defined */
|
|
3816
|
-
if (fn) {
|
|
3816
|
+
if (fn && (0, isFunction_4.isFunction)(fn)) {
|
|
3817
3817
|
tmp = fn(res, ele);
|
|
3818
3818
|
}
|
|
3819
3819
|
else {
|
|
@@ -3849,7 +3849,7 @@
|
|
|
3849
3849
|
}
|
|
3850
3850
|
}
|
|
3851
3851
|
/* Case where a callback is defined */
|
|
3852
|
-
if (tmp && fn2) {
|
|
3852
|
+
if (tmp && fn2 && (0, isFunction_4.isFunction)(fn2)) {
|
|
3853
3853
|
fn2(res);
|
|
3854
3854
|
}
|
|
3855
3855
|
else if (isObj && defaultPostLinkFunction_1.defaultPostLinkFunction) {
|
|
@@ -33,5 +33,5 @@
|
|
|
33
33
|
*
|
|
34
34
|
* @returns {*} The result of the main callback function: res.script, fn, or bbn.fn.defaultLinkFunction
|
|
35
35
|
*/
|
|
36
|
-
declare const callback: (url:
|
|
36
|
+
declare const callback: (url: any, res: any, fn?: any, fn2?: any, ele?: any) => boolean;
|
|
37
37
|
export { callback };
|
package/dist/fn/ajax/callback.js
CHANGED
|
@@ -39,7 +39,7 @@ import { defaultAlertFunction } from '../default/defaultAlertFunction';
|
|
|
39
39
|
*
|
|
40
40
|
* @returns {*} The result of the main callback function: res.script, fn, or bbn.fn.defaultLinkFunction
|
|
41
41
|
*/
|
|
42
|
-
const callback = function (url, res
|
|
42
|
+
const callback = function (url, res, fn = null, fn2 = null, ele = null) {
|
|
43
43
|
let tmp = false;
|
|
44
44
|
if (res) {
|
|
45
45
|
tmp = true;
|
|
@@ -59,7 +59,7 @@ const callback = function (url, res = null, fn = null, fn2 = null, ele = null) {
|
|
|
59
59
|
res.url = url;
|
|
60
60
|
}
|
|
61
61
|
/* Case where a callback is defined */
|
|
62
|
-
if (fn) {
|
|
62
|
+
if (fn && isFunction(fn)) {
|
|
63
63
|
tmp = fn(res, ele);
|
|
64
64
|
}
|
|
65
65
|
else {
|
|
@@ -95,7 +95,7 @@ const callback = function (url, res = null, fn = null, fn2 = null, ele = null) {
|
|
|
95
95
|
}
|
|
96
96
|
}
|
|
97
97
|
/* Case where a callback is defined */
|
|
98
|
-
if (tmp && fn2) {
|
|
98
|
+
if (tmp && fn2 && isFunction(fn2)) {
|
|
99
99
|
fn2(res);
|
|
100
100
|
}
|
|
101
101
|
else if (isObj && defaultPostLinkFunction) {
|
package/dist/fn.d.ts
CHANGED
|
@@ -28,7 +28,7 @@ declare const fn: {
|
|
|
28
28
|
baseName: (path: string, suffix?: string) => string;
|
|
29
29
|
br2nl: (st: any) => string;
|
|
30
30
|
calendar: (d?: string | number | Date, wrong_result?: string) => any;
|
|
31
|
-
callback: (url:
|
|
31
|
+
callback: (url: any, res: any, fn?: any, fn2?: any, ele?: any) => boolean;
|
|
32
32
|
camelize: (str: any) => any;
|
|
33
33
|
camelToCss: (str: any) => any;
|
|
34
34
|
canvasToImage: (canvas: any) => HTMLImageElement;
|