content-grade 1.1.1 → 1.1.2

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.
@@ -125,7 +125,7 @@ function getUpgradeMessage() {
125
125
  return '';
126
126
  }
127
127
 
128
- // Show usage-aware upgrade CTA after each free run.
128
+ // Show usage quota + upgrade CTA in a visually distinct box after each free run.
129
129
  // count = daily usage AFTER this run.
130
130
  function showFreeTierCTA(count) {
131
131
  const limit = TIER_LIMITS.free;
@@ -135,29 +135,24 @@ function showFreeTierCTA(count) {
135
135
  const ctaStrength = remaining === 0 ? 'strong' : remaining <= 1 ? 'warning' : 'nudge';
136
136
  recordEvent({ event: 'upgrade_prompt_shown', run_count: count, cta_strength: ctaStrength, cta_context: 'post_run' });
137
137
 
138
+ const quotaColor = remaining === 0 ? RD : remaining <= 1 ? YL : CY;
139
+ const bar = '█'.repeat(count) + '░'.repeat(Math.max(0, limit - count));
140
+ const remainText = remaining === 0
141
+ ? `come back tomorrow for ${limit} more`
142
+ : `${remaining} remaining today`;
143
+ const SEP = '─'.repeat(60);
144
+
138
145
  blank();
139
- hr();
146
+ console.log(` ${D}╭${SEP}${R}`);
147
+ console.log(` ${D}│${R} ${quotaColor}${B}${count}/${limit}${R} ${quotaColor}free runs used today${R} ${D}[${bar}] ${remainText}${R}`);
148
+ console.log(` ${D}│${R}`);
149
+ console.log(` ${D}│${R} ${WH}Pro unlocks:${R} ${D}Unlimited analyses · Priority processing${R}`);
150
+ console.log(` ${D}│${R} ${D}JSON/HTML export · Bulk grading · CI mode${R}`);
151
+ console.log(` ${D}│${R}`);
152
+ console.log(` ${D}│${R} ${GN}→ Get Pro${R} ${WH}$19/mo, cancel anytime${R}`);
153
+ console.log(` ${D}│${R} ${CY}${UPGRADE_LINKS.free}${R}`);
154
+ console.log(` ${D}╰${SEP}${R}`);
140
155
 
141
- if (remaining === 0) {
142
- // Variant D — power user, last run of the day
143
- console.log(` ${YL}${B}${count}/${limit} — that's all your free runs for today.${R}`);
144
- blank();
145
- console.log(` ${WH}You're clearly using this. $9/month removes the cap entirely —${R}`);
146
- console.log(` ${WH}unlimited analyses, JSON/HTML export, bulk mode. Cancel anytime.${R}`);
147
- blank();
148
- console.log(` ${CY}→ ${UPGRADE_LINKS.free}${R}`);
149
- console.log(` ${D}Or come back tomorrow for ${limit} more free runs.${R}`);
150
- } else {
151
- // Variant C — compact post-run teaser with command-relevant Pro feature
152
- const proFeatureMap = {
153
- grade: 'Bulk-grade entire directories · CI exit codes · JSON output',
154
- headline: 'Batch-test 50 headlines at once · CSV export',
155
- analyze: 'CI integration · exit 1 on below-threshold · JSON pipeline output',
156
- };
157
- const feature = proFeatureMap[cmd] || 'Unlimited runs · CI mode · bulk grading';
158
- console.log(` ${D}[ ${count}/${limit} free runs today · ${R}${WH}Pro: ${feature}${R}${D} · ${CY}${UPGRADE_LINKS.free}${R}${D} ]${R}`);
159
- }
160
- hr();
161
156
  maybeShowFeedbackCTA(count);
162
157
  }
163
158
 
@@ -225,20 +220,15 @@ function showCommunityNudge() {
225
220
  console.log(` ${D}💬 Questions or feedback? Discussions: ${CY}${DISCUSSIONS_URL}${R}`);
226
221
  }
227
222
 
228
- // Single-line usage counter appended after every command run.
223
+ // Usage quota + upgrade nudge shown after batch runs.
229
224
  // count = daily runs used (after this run).
230
225
  function showUsageFooter(count) {
231
226
  if (isProUser()) return;
232
227
  const limit = TIER_LIMITS.free;
233
228
  const remaining = Math.max(0, limit - count);
229
+ const quotaColor = remaining === 0 ? RD : remaining <= 1 ? YL : D;
234
230
  blank();
235
- if (remaining === 0) {
236
- console.log(` ${RD}[ You've used ${limit}/${limit} free runs today · Pro: unlimited, JSON/HTML export, bulk mode — $9/mo → ${UPGRADE_LINKS.free} ]${R}`);
237
- } else if (remaining <= 1) {
238
- console.log(` ${YL}[ You've used ${count}/${limit} free runs today · ${remaining} remaining · Pro: unlimited ($9/mo) → ${UPGRADE_LINKS.free} ]${R}`);
239
- } else {
240
- console.log(` ${D}[ You've used ${count}/${limit} free runs today · ${remaining} remaining · Pro: unlimited ($9/mo) → ${UPGRADE_LINKS.free} ]${R}`);
241
- }
231
+ console.log(` ${quotaColor}${B}${count}/${limit}${R} ${quotaColor}free runs used today${R} ${D}· Pro: unlimited → ${CY}${UPGRADE_LINKS.free}${R}`);
242
232
  maybeShowEarlyAdopterCTA(count);
243
233
  maybeShowFeedbackCTA(count);
244
234
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "content-grade",
3
- "version": "1.1.1",
3
+ "version": "1.1.2",
4
4
  "description": "AI-powered content analysis CLI. Score any blog post, landing page, or ad copy in under 30 seconds — runs on Claude CLI, no API key needed.",
5
5
  "type": "module",
6
6
  "bin": {