File tree Expand file tree Collapse file tree 4 files changed +9
-2
lines changed Expand file tree Collapse file tree 4 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ function detectLocation(): StrippedLocation {
15
15
const result = {
16
16
host : window . location . host ,
17
17
pathname : window . location . pathname ,
18
+ search : window . location . search ,
18
19
}
19
20
logger . debug ( "[gitcasso] detectLocation called, returning:" , result )
20
21
return result
Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ export interface CommentEvent {
26
26
export interface StrippedLocation {
27
27
host : string
28
28
pathname : string
29
+ search : string
29
30
}
30
31
31
32
/** Wraps the textareas of a given platform with Gitcasso's enhancements. */
Original file line number Diff line number Diff line change @@ -66,6 +66,7 @@ export function detectedSpots() {
66
66
const location : StrippedLocation = {
67
67
host : window . location . host ,
68
68
pathname : window . location . pathname ,
69
+ search : window . location . search ,
69
70
}
70
71
const detectionResults = [ ]
71
72
for ( const textarea of textareas ) {
@@ -86,6 +87,7 @@ export function tableUI() {
86
87
const location : StrippedLocation = {
87
88
host : window . location . host ,
88
89
pathname : window . location . pathname ,
90
+ search : window . location . search ,
89
91
}
90
92
const uiResults = [ ]
91
93
for ( const textarea of textareas ) {
Original file line number Diff line number Diff line change @@ -97,6 +97,7 @@ function getUrlParts(key: string) {
97
97
hostname : url . hostname ,
98
98
href : originalUrl ,
99
99
pathname : url . pathname ,
100
+ search : url . search ,
100
101
}
101
102
}
102
103
@@ -566,7 +567,8 @@ function createGitcassoScript(
566
567
// Set up mocked location
567
568
window.gitcassoMockLocation = {
568
569
host: '${ urlParts . host } ',
569
- pathname: '${ urlParts . pathname } '
570
+ pathname: '${ urlParts . pathname } ',
571
+ search: '${ urlParts . search } '
570
572
};
571
573
572
574
// Set up browser API mocks
@@ -603,7 +605,8 @@ function createGitcassoScript(
603
605
);
604
606
window.gitcassoMockLocation = {
605
607
host: '${ urlParts . host } ',
606
- pathname: '${ urlParts . pathname } '
608
+ pathname: '${ urlParts . pathname } ',
609
+ search: '${ urlParts . search } '
607
610
};
608
611
609
612
// Execute the patched script with browser API mocks prepended
You can’t perform that action at this time.
0 commit comments