@snapback/cli 3.0.0 → 3.0.1

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.
@@ -584,26 +584,6 @@ var TIER_LIMITS = {
584
584
  unlimited_workspaces: null
585
585
  }
586
586
  };
587
- var PIONEER_TIER_THRESHOLDS = {
588
- // Note: Thresholds now represent behavioral milestone index, not points
589
- pioneer: 0,
590
- active_pioneer: 1,
591
- contributing_pioneer: 2,
592
- founding_pioneer: 3
593
- };
594
- function calculatePioneerTier(milestoneIndex) {
595
- if (milestoneIndex >= 3) {
596
- return "founding_pioneer";
597
- }
598
- if (milestoneIndex >= 2) {
599
- return "contributing_pioneer";
600
- }
601
- if (milestoneIndex >= 1) {
602
- return "active_pioneer";
603
- }
604
- return "pioneer";
605
- }
606
- __name(calculatePioneerTier, "calculatePioneerTier");
607
587
  function getTierFeatures(tier) {
608
588
  const effectiveTier = getEffectiveTier(tier);
609
589
  return TIER_FEATURES[effectiveTier] || [];
@@ -642,29 +622,6 @@ var ErrorCategory;
642
622
  ErrorCategory2["EXTERNAL"] = "EXTERNAL";
643
623
  ErrorCategory2["INTERNAL"] = "INTERNAL";
644
624
  })(ErrorCategory || (ErrorCategory = {}));
645
-
646
- // ../../packages/contracts/dist/eventBus.js
647
- var EventBus = class {
648
- static {
649
- __name(this, "EventBus");
650
- }
651
- m = /* @__PURE__ */ new Map();
652
- on(k, h) {
653
- const set = this.m.get(k) ?? /* @__PURE__ */ new Set();
654
- set.add(h);
655
- this.m.set(k, set);
656
- return () => set.delete(h);
657
- }
658
- emit(k, p) {
659
- const handlers = this.m.get(k);
660
- if (handlers) {
661
- const handlersArray = Array.from(handlers);
662
- for (const h of handlersArray) {
663
- h(p);
664
- }
665
- }
666
- }
667
- };
668
625
  var SnapBackEvent;
669
626
  (function(SnapBackEvent2) {
670
627
  SnapBackEvent2["SNAPSHOT_CREATED"] = "snapshot:created";
@@ -1552,44 +1509,6 @@ var SpanKind;
1552
1509
  SpanKind2[SpanKind2["PRODUCER"] = 3] = "PRODUCER";
1553
1510
  SpanKind2[SpanKind2["CONSUMER"] = 4] = "CONSUMER";
1554
1511
  })(SpanKind || (SpanKind = {}));
1555
-
1556
- // ../../packages/contracts/dist/pioneer-service.js
1557
- var PIONEER_ACTION_POINTS = {
1558
- first_snapshot: 50,
1559
- first_check: 25,
1560
- first_review: 25,
1561
- first_complete: 50,
1562
- daily_snapshot: 10,
1563
- share_snapshot: 20,
1564
- refer_signup: 200,
1565
- refer_activation: 100,
1566
- milestone_reached: 100
1567
- };
1568
- function getActionPoints(action) {
1569
- return PIONEER_ACTION_POINTS[action] || 0;
1570
- }
1571
- __name(getActionPoints, "getActionPoints");
1572
- function isFirstTimeAction(action) {
1573
- return action.startsWith("first_");
1574
- }
1575
- __name(isFirstTimeAction, "isFirstTimeAction");
1576
- function generateIdempotencyKey(userId, action, metadata) {
1577
- if (metadata?.snapshotId) {
1578
- return `${action}_${metadata.snapshotId}`;
1579
- }
1580
- if (isFirstTimeAction(action)) {
1581
- return `${userId}_${action}`;
1582
- }
1583
- if (action === "daily_snapshot") {
1584
- const date = (/* @__PURE__ */ new Date()).toISOString().split("T")[0];
1585
- return `${userId}_${action}_${date}`;
1586
- }
1587
- if (metadata?.referralCode) {
1588
- return `${action}_${metadata.referralCode}`;
1589
- }
1590
- return `${userId}_${action}_${Date.now()}`;
1591
- }
1592
- __name(generateIdempotencyKey, "generateIdempotencyKey");
1593
1512
  z.object({
1594
1513
  id: z.string().min(1),
1595
1514
  source: z.string().min(1),
@@ -3732,4 +3651,4 @@ z.discriminatedUnion("status", [
3732
3651
  lastActivityTime: (/* @__PURE__ */ new Date()).toISOString()
3733
3652
  }});
3734
3653
 
3735
- export { EventBus, FEATURE_FLAGS, FeatureManager, LogLevel, NoOpInstrumentationProvider, PIONEER_TIER_THRESHOLDS, TIER_UPGRADE_SAGA, calculatePioneerTier, createLogger, extractErrorCode, generateIdempotencyKey, getActionPoints, getTierFeatures, getTierLimit, isFeatureAvailableAtTier, isFirstTimeAction, shouldMergeAttribution, validateTelemetryEvent };
3654
+ export { FEATURE_FLAGS, FeatureManager, LogLevel, NoOpInstrumentationProvider, TIER_UPGRADE_SAGA, createLogger, extractErrorCode, getTierFeatures, getTierLimit, isFeatureAvailableAtTier, shouldMergeAttribution, validateTelemetryEvent };