@plaidev/karte-action-sdk 1.1.270-29270413.6a2b1dc5c → 1.1.270-29271309.7b6ffcd9a
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/functions.d.ts +1 -1
- package/dist/hydrate/functions.d.ts +1 -1
- package/dist/hydrate/index.es.js +14 -4
- package/dist/hydrate/prop.d.ts +4 -0
- package/dist/index.es.js +14 -4
- package/dist/prop.d.ts +4 -0
- package/dist/svelte5/functions.d.ts +1 -1
- package/dist/svelte5/hydrate/functions.d.ts +1 -1
- package/dist/svelte5/hydrate/index.es.js +14 -4
- package/dist/svelte5/hydrate/prop.d.ts +4 -0
- package/dist/svelte5/index.es.js +14 -4
- package/dist/svelte5/index.front2.es.js +14 -4
- package/dist/svelte5/prop.d.ts +4 -0
- package/package.json +1 -1
package/dist/functions.d.ts
CHANGED
@@ -5,7 +5,7 @@ export declare const none: () => () => void;
|
|
5
5
|
/** @internal */
|
6
6
|
export declare const moveTo: (to: string) => () => void;
|
7
7
|
/** @internal */
|
8
|
-
export declare const linkTo: (to: string, targetBlank?: boolean, decode?: boolean) => () => void;
|
8
|
+
export declare const linkTo: (to: string, targetBlank?: boolean, decode?: boolean, keepNativeActionViewed?: boolean) => () => void;
|
9
9
|
/** @internal */
|
10
10
|
export declare const closeApp: (trigger: CloseTrigger) => () => void;
|
11
11
|
/** @internal */
|
@@ -5,7 +5,7 @@ export declare const none: () => () => void;
|
|
5
5
|
/** @internal */
|
6
6
|
export declare const moveTo: (to: string) => () => void;
|
7
7
|
/** @internal */
|
8
|
-
export declare const linkTo: (to: string, targetBlank?: boolean, decode?: boolean) => () => void;
|
8
|
+
export declare const linkTo: (to: string, targetBlank?: boolean, decode?: boolean, keepNativeActionViewed?: boolean) => () => void;
|
9
9
|
/** @internal */
|
10
10
|
export declare const closeApp: (trigger: CloseTrigger) => () => void;
|
11
11
|
/** @internal */
|
package/dist/hydrate/index.es.js
CHANGED
@@ -372,6 +372,11 @@ const OnClickOperationOptions = [
|
|
372
372
|
name: "decode",
|
373
373
|
type: "BooleanKeyword",
|
374
374
|
default: false
|
375
|
+
},
|
376
|
+
{
|
377
|
+
name: "keep_native_action_viewed",
|
378
|
+
type: "BooleanKeyword",
|
379
|
+
default: false
|
375
380
|
}
|
376
381
|
]
|
377
382
|
},
|
@@ -3791,7 +3796,7 @@ const moveTo = (to) => () => {
|
|
3791
3796
|
_moveTo(to);
|
3792
3797
|
};
|
3793
3798
|
/** @internal */
|
3794
|
-
const linkTo = (to, targetBlank = true, decode = false) => () => {
|
3799
|
+
const linkTo = (to, targetBlank = true, decode = false, keepNativeActionViewed = false) => () => {
|
3795
3800
|
const decodedTo = decode ? decodeURI(to) : to;
|
3796
3801
|
const { target } = getActionRunnerContext() ?? {};
|
3797
3802
|
async function sleep(ms) {
|
@@ -3804,7 +3809,8 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3804
3809
|
});
|
3805
3810
|
await sleep(450);
|
3806
3811
|
}
|
3807
|
-
|
3812
|
+
let doTransitionByLocation = true;
|
3813
|
+
if (target === "native" && targetBlank && keepNativeActionViewed) {
|
3808
3814
|
const win = window;
|
3809
3815
|
const nativeMessageName = "open_url";
|
3810
3816
|
const nativeMessageData = {
|
@@ -3813,9 +3819,13 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3813
3819
|
};
|
3814
3820
|
win.NativeBridge?.onReceivedMessage(nativeMessageName, JSON.stringify(nativeMessageData));
|
3815
3821
|
win.webkit?.messageHandlers[nativeMessageName]?.postMessage(nativeMessageData);
|
3816
|
-
|
3822
|
+
doTransitionByLocation = false;
|
3823
|
+
} else if (target === "web" && targetBlank) {
|
3824
|
+
window.open(decodedTo, "_blank");
|
3825
|
+
doTransitionByLocation = false;
|
3826
|
+
}
|
3817
3827
|
Promise.race([_send(), sleep(650)]).then(() => {
|
3818
|
-
if (
|
3828
|
+
if (doTransitionByLocation) location.href = decodedTo;
|
3819
3829
|
});
|
3820
3830
|
};
|
3821
3831
|
/** @internal */
|
package/dist/hydrate/prop.d.ts
CHANGED
@@ -104,6 +104,10 @@ export declare const OnClickOperationOptions: readonly [{
|
|
104
104
|
readonly name: "decode";
|
105
105
|
readonly type: "BooleanKeyword";
|
106
106
|
readonly default: false;
|
107
|
+
}, {
|
108
|
+
readonly name: "keep_native_action_viewed";
|
109
|
+
readonly type: "BooleanKeyword";
|
110
|
+
readonly default: false;
|
107
111
|
}];
|
108
112
|
}, {
|
109
113
|
readonly operation: "moveTo";
|
package/dist/index.es.js
CHANGED
@@ -372,6 +372,11 @@ const OnClickOperationOptions = [
|
|
372
372
|
name: "decode",
|
373
373
|
type: "BooleanKeyword",
|
374
374
|
default: false
|
375
|
+
},
|
376
|
+
{
|
377
|
+
name: "keep_native_action_viewed",
|
378
|
+
type: "BooleanKeyword",
|
379
|
+
default: false
|
375
380
|
}
|
376
381
|
]
|
377
382
|
},
|
@@ -3786,7 +3791,7 @@ const moveTo = (to) => () => {
|
|
3786
3791
|
_moveTo(to);
|
3787
3792
|
};
|
3788
3793
|
/** @internal */
|
3789
|
-
const linkTo = (to, targetBlank = true, decode = false) => () => {
|
3794
|
+
const linkTo = (to, targetBlank = true, decode = false, keepNativeActionViewed = false) => () => {
|
3790
3795
|
const decodedTo = decode ? decodeURI(to) : to;
|
3791
3796
|
const { target } = getActionRunnerContext() ?? {};
|
3792
3797
|
async function sleep(ms) {
|
@@ -3799,7 +3804,8 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3799
3804
|
});
|
3800
3805
|
await sleep(450);
|
3801
3806
|
}
|
3802
|
-
|
3807
|
+
let doTransitionByLocation = true;
|
3808
|
+
if (target === "native" && targetBlank && keepNativeActionViewed) {
|
3803
3809
|
const win = window;
|
3804
3810
|
const nativeMessageName = "open_url";
|
3805
3811
|
const nativeMessageData = {
|
@@ -3808,9 +3814,13 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3808
3814
|
};
|
3809
3815
|
win.NativeBridge?.onReceivedMessage(nativeMessageName, JSON.stringify(nativeMessageData));
|
3810
3816
|
win.webkit?.messageHandlers[nativeMessageName]?.postMessage(nativeMessageData);
|
3811
|
-
|
3817
|
+
doTransitionByLocation = false;
|
3818
|
+
} else if (target === "web" && targetBlank) {
|
3819
|
+
window.open(decodedTo, "_blank");
|
3820
|
+
doTransitionByLocation = false;
|
3821
|
+
}
|
3812
3822
|
Promise.race([_send(), sleep(650)]).then(() => {
|
3813
|
-
if (
|
3823
|
+
if (doTransitionByLocation) location.href = decodedTo;
|
3814
3824
|
});
|
3815
3825
|
};
|
3816
3826
|
/** @internal */
|
package/dist/prop.d.ts
CHANGED
@@ -104,6 +104,10 @@ export declare const OnClickOperationOptions: readonly [{
|
|
104
104
|
readonly name: "decode";
|
105
105
|
readonly type: "BooleanKeyword";
|
106
106
|
readonly default: false;
|
107
|
+
}, {
|
108
|
+
readonly name: "keep_native_action_viewed";
|
109
|
+
readonly type: "BooleanKeyword";
|
110
|
+
readonly default: false;
|
107
111
|
}];
|
108
112
|
}, {
|
109
113
|
readonly operation: "moveTo";
|
@@ -5,7 +5,7 @@ export declare const none: () => () => void;
|
|
5
5
|
/** @internal */
|
6
6
|
export declare const moveTo: (to: string) => () => void;
|
7
7
|
/** @internal */
|
8
|
-
export declare const linkTo: (to: string, targetBlank?: boolean, decode?: boolean) => () => void;
|
8
|
+
export declare const linkTo: (to: string, targetBlank?: boolean, decode?: boolean, keepNativeActionViewed?: boolean) => () => void;
|
9
9
|
/** @internal */
|
10
10
|
export declare const closeApp: (trigger: CloseTrigger) => () => void;
|
11
11
|
/** @internal */
|
@@ -5,7 +5,7 @@ export declare const none: () => () => void;
|
|
5
5
|
/** @internal */
|
6
6
|
export declare const moveTo: (to: string) => () => void;
|
7
7
|
/** @internal */
|
8
|
-
export declare const linkTo: (to: string, targetBlank?: boolean, decode?: boolean) => () => void;
|
8
|
+
export declare const linkTo: (to: string, targetBlank?: boolean, decode?: boolean, keepNativeActionViewed?: boolean) => () => void;
|
9
9
|
/** @internal */
|
10
10
|
export declare const closeApp: (trigger: CloseTrigger) => () => void;
|
11
11
|
/** @internal */
|
@@ -371,6 +371,11 @@ const OnClickOperationOptions = [
|
|
371
371
|
name: "decode",
|
372
372
|
type: "BooleanKeyword",
|
373
373
|
default: false
|
374
|
+
},
|
375
|
+
{
|
376
|
+
name: "keep_native_action_viewed",
|
377
|
+
type: "BooleanKeyword",
|
378
|
+
default: false
|
374
379
|
}
|
375
380
|
]
|
376
381
|
},
|
@@ -3663,7 +3668,7 @@ const moveTo = (to) => () => {
|
|
3663
3668
|
_moveTo(to);
|
3664
3669
|
};
|
3665
3670
|
/** @internal */
|
3666
|
-
const linkTo = (to, targetBlank = true, decode = false) => () => {
|
3671
|
+
const linkTo = (to, targetBlank = true, decode = false, keepNativeActionViewed = false) => () => {
|
3667
3672
|
const decodedTo = decode ? decodeURI(to) : to;
|
3668
3673
|
const { target } = getActionRunnerContext() ?? {};
|
3669
3674
|
async function sleep(ms) {
|
@@ -3676,7 +3681,8 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3676
3681
|
});
|
3677
3682
|
await sleep(450);
|
3678
3683
|
}
|
3679
|
-
|
3684
|
+
let doTransitionByLocation = true;
|
3685
|
+
if (target === "native" && targetBlank && keepNativeActionViewed) {
|
3680
3686
|
const win = window;
|
3681
3687
|
const nativeMessageName = "open_url";
|
3682
3688
|
const nativeMessageData = {
|
@@ -3685,9 +3691,13 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3685
3691
|
};
|
3686
3692
|
win.NativeBridge?.onReceivedMessage(nativeMessageName, JSON.stringify(nativeMessageData));
|
3687
3693
|
win.webkit?.messageHandlers[nativeMessageName]?.postMessage(nativeMessageData);
|
3688
|
-
|
3694
|
+
doTransitionByLocation = false;
|
3695
|
+
} else if (target === "web" && targetBlank) {
|
3696
|
+
window.open(decodedTo, "_blank");
|
3697
|
+
doTransitionByLocation = false;
|
3698
|
+
}
|
3689
3699
|
Promise.race([_send(), sleep(650)]).then(() => {
|
3690
|
-
if (
|
3700
|
+
if (doTransitionByLocation) location.href = decodedTo;
|
3691
3701
|
});
|
3692
3702
|
};
|
3693
3703
|
/** @internal */
|
@@ -104,6 +104,10 @@ export declare const OnClickOperationOptions: readonly [{
|
|
104
104
|
readonly name: "decode";
|
105
105
|
readonly type: "BooleanKeyword";
|
106
106
|
readonly default: false;
|
107
|
+
}, {
|
108
|
+
readonly name: "keep_native_action_viewed";
|
109
|
+
readonly type: "BooleanKeyword";
|
110
|
+
readonly default: false;
|
107
111
|
}];
|
108
112
|
}, {
|
109
113
|
readonly operation: "moveTo";
|
package/dist/svelte5/index.es.js
CHANGED
@@ -371,6 +371,11 @@ const OnClickOperationOptions = [
|
|
371
371
|
name: "decode",
|
372
372
|
type: "BooleanKeyword",
|
373
373
|
default: false
|
374
|
+
},
|
375
|
+
{
|
376
|
+
name: "keep_native_action_viewed",
|
377
|
+
type: "BooleanKeyword",
|
378
|
+
default: false
|
374
379
|
}
|
375
380
|
]
|
376
381
|
},
|
@@ -3632,7 +3637,7 @@ const moveTo = (to) => () => {
|
|
3632
3637
|
_moveTo(to);
|
3633
3638
|
};
|
3634
3639
|
/** @internal */
|
3635
|
-
const linkTo = (to, targetBlank = true, decode = false) => () => {
|
3640
|
+
const linkTo = (to, targetBlank = true, decode = false, keepNativeActionViewed = false) => () => {
|
3636
3641
|
const decodedTo = decode ? decodeURI(to) : to;
|
3637
3642
|
const { target } = getActionRunnerContext() ?? {};
|
3638
3643
|
async function sleep(ms) {
|
@@ -3645,7 +3650,8 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3645
3650
|
});
|
3646
3651
|
await sleep(450);
|
3647
3652
|
}
|
3648
|
-
|
3653
|
+
let doTransitionByLocation = true;
|
3654
|
+
if (target === "native" && targetBlank && keepNativeActionViewed) {
|
3649
3655
|
const win = window;
|
3650
3656
|
const nativeMessageName = "open_url";
|
3651
3657
|
const nativeMessageData = {
|
@@ -3654,9 +3660,13 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3654
3660
|
};
|
3655
3661
|
win.NativeBridge?.onReceivedMessage(nativeMessageName, JSON.stringify(nativeMessageData));
|
3656
3662
|
win.webkit?.messageHandlers[nativeMessageName]?.postMessage(nativeMessageData);
|
3657
|
-
|
3663
|
+
doTransitionByLocation = false;
|
3664
|
+
} else if (target === "web" && targetBlank) {
|
3665
|
+
window.open(decodedTo, "_blank");
|
3666
|
+
doTransitionByLocation = false;
|
3667
|
+
}
|
3658
3668
|
Promise.race([_send(), sleep(650)]).then(() => {
|
3659
|
-
if (
|
3669
|
+
if (doTransitionByLocation) location.href = decodedTo;
|
3660
3670
|
});
|
3661
3671
|
};
|
3662
3672
|
/** @internal */
|
@@ -371,6 +371,11 @@ const OnClickOperationOptions = [
|
|
371
371
|
name: "decode",
|
372
372
|
type: "BooleanKeyword",
|
373
373
|
default: false
|
374
|
+
},
|
375
|
+
{
|
376
|
+
name: "keep_native_action_viewed",
|
377
|
+
type: "BooleanKeyword",
|
378
|
+
default: false
|
374
379
|
}
|
375
380
|
]
|
376
381
|
},
|
@@ -3632,7 +3637,7 @@ const moveTo = (to) => () => {
|
|
3632
3637
|
_moveTo(to);
|
3633
3638
|
};
|
3634
3639
|
/** @internal */
|
3635
|
-
const linkTo = (to, targetBlank = true, decode = false) => () => {
|
3640
|
+
const linkTo = (to, targetBlank = true, decode = false, keepNativeActionViewed = false) => () => {
|
3636
3641
|
const decodedTo = decode ? decodeURI(to) : to;
|
3637
3642
|
const { target } = getActionRunnerContext() ?? {};
|
3638
3643
|
async function sleep(ms) {
|
@@ -3645,7 +3650,8 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3645
3650
|
});
|
3646
3651
|
await sleep(450);
|
3647
3652
|
}
|
3648
|
-
|
3653
|
+
let doTransitionByLocation = true;
|
3654
|
+
if (target === "native" && targetBlank && keepNativeActionViewed) {
|
3649
3655
|
const win = window;
|
3650
3656
|
const nativeMessageName = "open_url";
|
3651
3657
|
const nativeMessageData = {
|
@@ -3654,9 +3660,13 @@ const linkTo = (to, targetBlank = true, decode = false) => () => {
|
|
3654
3660
|
};
|
3655
3661
|
win.NativeBridge?.onReceivedMessage(nativeMessageName, JSON.stringify(nativeMessageData));
|
3656
3662
|
win.webkit?.messageHandlers[nativeMessageName]?.postMessage(nativeMessageData);
|
3657
|
-
|
3663
|
+
doTransitionByLocation = false;
|
3664
|
+
} else if (target === "web" && targetBlank) {
|
3665
|
+
window.open(decodedTo, "_blank");
|
3666
|
+
doTransitionByLocation = false;
|
3667
|
+
}
|
3658
3668
|
Promise.race([_send(), sleep(650)]).then(() => {
|
3659
|
-
if (
|
3669
|
+
if (doTransitionByLocation) location.href = decodedTo;
|
3660
3670
|
});
|
3661
3671
|
};
|
3662
3672
|
/** @internal */
|
package/dist/svelte5/prop.d.ts
CHANGED
@@ -104,6 +104,10 @@ export declare const OnClickOperationOptions: readonly [{
|
|
104
104
|
readonly name: "decode";
|
105
105
|
readonly type: "BooleanKeyword";
|
106
106
|
readonly default: false;
|
107
|
+
}, {
|
108
|
+
readonly name: "keep_native_action_viewed";
|
109
|
+
readonly type: "BooleanKeyword";
|
110
|
+
readonly default: false;
|
107
111
|
}];
|
108
112
|
}, {
|
109
113
|
readonly operation: "moveTo";
|