@expiren/opencode-antigravity-auth 1.6.29 → 1.6.30
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.js +6 -4
- package/dist/index.js.map +2 -2
- package/dist/src/plugin.d.ts.map +1 -1
- package/dist/src/plugin.js +10 -5
- package/dist/src/plugin.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -13004,10 +13004,12 @@ Alternatively, you can:
|
|
|
13004
13004
|
const pct = `${color}${Math.round(remaining * 100)}%${colors.reset}`.padStart(4 + color.length + colors.reset.length);
|
|
13005
13005
|
return `${bar} ${pct}`;
|
|
13006
13006
|
};
|
|
13007
|
-
const formatReset = (resetTime) => {
|
|
13007
|
+
const formatReset = (resetTime, remainingFraction) => {
|
|
13008
13008
|
if (!resetTime) return "";
|
|
13009
13009
|
const ms = Date.parse(resetTime) - Date.now();
|
|
13010
|
-
if (ms <= 0)
|
|
13010
|
+
if (ms <= 0) {
|
|
13011
|
+
return remainingFraction !== void 0 && remainingFraction <= 0 ? " (unavailable)" : " (resetting...)";
|
|
13012
|
+
}
|
|
13011
13013
|
const hours = ms / (1e3 * 60 * 60);
|
|
13012
13014
|
if (hours >= 24) {
|
|
13013
13015
|
const days = Math.floor(hours / 24);
|
|
@@ -13031,7 +13033,7 @@ Alternatively, you can:
|
|
|
13031
13033
|
const isLast = idx === models.length - 1;
|
|
13032
13034
|
const connector = isLast ? "\u2514\u2500" : "\u251C\u2500";
|
|
13033
13035
|
const bar = createProgressBar(model.remainingFraction);
|
|
13034
|
-
const reset = formatReset(model.resetTime);
|
|
13036
|
+
const reset = formatReset(model.resetTime, model.remainingFraction);
|
|
13035
13037
|
const status = classifyGroupStatus({ remainingFraction: model.remainingFraction, resetTime: model.resetTime, modelCount: 1 });
|
|
13036
13038
|
const badge = formatQuotaStatusBadge(status);
|
|
13037
13039
|
const modelName = model.modelId.padEnd(29);
|
|
@@ -13055,7 +13057,7 @@ Alternatively, you can:
|
|
|
13055
13057
|
const isLast = idx === groupEntries.length - 1;
|
|
13056
13058
|
const connector = isLast ? "\u2514\u2500" : "\u251C\u2500";
|
|
13057
13059
|
const bar = createProgressBar(g.data.remainingFraction);
|
|
13058
|
-
const reset = formatReset(g.data.resetTime);
|
|
13060
|
+
const reset = formatReset(g.data.resetTime, g.data.remainingFraction);
|
|
13059
13061
|
const status = classifyGroupStatus(g.data);
|
|
13060
13062
|
const badge = formatQuotaStatusBadge(status);
|
|
13061
13063
|
const modelName = g.name.padEnd(29);
|