@viibestack/ui 0.7.7 → 0.7.9

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@viibestack/ui",
3
- "version": "0.7.7",
3
+ "version": "0.7.9",
4
4
  "description": "Dependency-free React UI kit -- icons, core components (Button, Card, Input, Modal, etc.), a TeamGrid/TeamMemberCard people-grid pattern, gamification primitives (PointsDisplay, StreakCounter, Achievements, Leaderboard, fireReward), a real per-app data client for browser code (listRows/listRowsPage/getRow/upsertRow/deleteRow/captureClientError) plus server-safe variants for Route Handlers/Server Components (listRowsServer/listRowsPageServer/getRowServer/upsertRowServer/deleteRowServer/resolveAppIdByHostname), a real per-app end-user auth client (signUp/logIn/logOut/getCurrentUser/reportError), and a self-gating PoweredByBadge component -- backed by ViibeStack's own platform-managed data store.",
5
5
  "type": "module",
6
6
  "main": "./src/index.ts",
package/src/auth.ts CHANGED
@@ -303,6 +303,15 @@ export interface MonetizationStatus {
303
303
  status: string; // mirrors Stripe verbatim: trialing/active/past_due/canceled/...
304
304
  trial_end: string | null;
305
305
  seats: number; // 1 unless the app owner set pricing_model to per-seat
306
+ // ISO timestamp of this subscription's current billing period end (its
307
+ // next charge date), straight from Stripe's own subscription object --
308
+ // null only until the first customer.subscription.created/updated event
309
+ // lands (moments after checkout, not before). Lets an app show a
310
+ // subscriber their real next-charge date instead of leaving them to
311
+ // guess -- see 140_monetization_current_period_end.sql's own comment for
312
+ // why this was added (a subscriber billed twice in 12 days with no way
313
+ // for the app -- or its owner -- to see or predict their next charge).
314
+ current_period_end: string | null;
306
315
  }
307
316
 
308
317
  // Redirects the browser to Stripe Checkout to start (or restart) the
package/src/badge.tsx CHANGED
@@ -110,22 +110,43 @@ export function PoweredByBadge() {
110
110
  setDismissed(true);
111
111
  }}
112
112
  style={{
113
+ // Tap target is 2.75rem (44px, Apple's/Android's usual minimum
114
+ // recommendation) even though the visible glyph stays the same
115
+ // small size below -- was a literal 1rem (16px) box, reported as
116
+ // hard to hit on mobile. Negative margin cancels the extra size
117
+ // from the pill's own layout (this flex row centers on cross-axis
118
+ // with no fixed height, so a bigger child would otherwise stretch
119
+ // the whole badge taller) -- the button still visually reads as
120
+ // the same small pill, just easier to actually tap.
113
121
  display: "flex",
114
122
  alignItems: "center",
115
123
  justifyContent: "center",
116
- width: "1rem",
117
- height: "1rem",
124
+ width: "2.75rem",
125
+ height: "2.75rem",
126
+ margin: "-0.875rem",
118
127
  padding: 0,
119
128
  border: "none",
120
129
  borderRadius: "9999px",
121
- background: "rgba(255, 255, 255, 0.15)",
130
+ background: "transparent",
122
131
  color: "#fff",
123
132
  fontSize: "0.7rem",
124
133
  lineHeight: 1,
125
134
  cursor: "pointer",
126
135
  }}
127
136
  >
128
- ✕
137
+ <span
138
+ style={{
139
+ display: "flex",
140
+ alignItems: "center",
141
+ justifyContent: "center",
142
+ width: "1rem",
143
+ height: "1rem",
144
+ borderRadius: "9999px",
145
+ background: "rgba(255, 255, 255, 0.15)",
146
+ }}
147
+ >
148
+ &#x2715;
149
+ </span>
129
150
  </button>
130
151
  </span>
131
152
  );