@followgate/js 0.10.0 → 0.11.0
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/index.d.mts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +11 -0
- package/dist/index.mjs +11 -0
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -518,6 +518,8 @@ var FollowGateClient = class {
|
|
|
518
518
|
theme: config.theme || "dark",
|
|
519
519
|
accentColor: config.accentColor || "#6366f1"
|
|
520
520
|
};
|
|
521
|
+
this.serverConfig = null;
|
|
522
|
+
this.configFetched = false;
|
|
521
523
|
this.restoreSession();
|
|
522
524
|
if (config.debug) {
|
|
523
525
|
console.log("[FollowGate] Initialized with appId:", config.appId);
|
|
@@ -580,6 +582,15 @@ var FollowGateClient = class {
|
|
|
580
582
|
return;
|
|
581
583
|
}
|
|
582
584
|
await this.fetchServerConfig();
|
|
585
|
+
if (this.config.twitter?.username && !this.hasUsername()) {
|
|
586
|
+
this.setUsername(this.config.twitter.username, "twitter");
|
|
587
|
+
if (this.config.debug) {
|
|
588
|
+
console.log(
|
|
589
|
+
"[FollowGate] Pre-filled username:",
|
|
590
|
+
this.config.twitter.username
|
|
591
|
+
);
|
|
592
|
+
}
|
|
593
|
+
}
|
|
583
594
|
this.injectStyles();
|
|
584
595
|
this.createModal();
|
|
585
596
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -492,6 +492,8 @@ var FollowGateClient = class {
|
|
|
492
492
|
theme: config.theme || "dark",
|
|
493
493
|
accentColor: config.accentColor || "#6366f1"
|
|
494
494
|
};
|
|
495
|
+
this.serverConfig = null;
|
|
496
|
+
this.configFetched = false;
|
|
495
497
|
this.restoreSession();
|
|
496
498
|
if (config.debug) {
|
|
497
499
|
console.log("[FollowGate] Initialized with appId:", config.appId);
|
|
@@ -554,6 +556,15 @@ var FollowGateClient = class {
|
|
|
554
556
|
return;
|
|
555
557
|
}
|
|
556
558
|
await this.fetchServerConfig();
|
|
559
|
+
if (this.config.twitter?.username && !this.hasUsername()) {
|
|
560
|
+
this.setUsername(this.config.twitter.username, "twitter");
|
|
561
|
+
if (this.config.debug) {
|
|
562
|
+
console.log(
|
|
563
|
+
"[FollowGate] Pre-filled username:",
|
|
564
|
+
this.config.twitter.username
|
|
565
|
+
);
|
|
566
|
+
}
|
|
567
|
+
}
|
|
557
568
|
this.injectStyles();
|
|
558
569
|
this.createModal();
|
|
559
570
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@followgate/js",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"description": "FollowGate SDK - Grow your audience with every download. Require social actions (follow, repost) before users can access your app.",
|
|
5
5
|
"author": "FollowGate <hello@followgate.app>",
|
|
6
6
|
"homepage": "https://followgate.app",
|