@wireai/activation 0.7.0 → 0.9.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.
Files changed (94) hide show
  1. package/AGENTS.md +29 -5
  2. package/CHANGELOG.md +198 -6
  3. package/README.md +105 -10
  4. package/dist/analytics/index.d.mts +12 -8
  5. package/dist/analytics/index.d.ts +12 -8
  6. package/dist/analytics/index.js +525 -55
  7. package/dist/analytics/index.js.map +1 -1
  8. package/dist/analytics/index.mjs +525 -55
  9. package/dist/analytics/index.mjs.map +1 -1
  10. package/dist/coachmarks/index.d.mts +2 -2
  11. package/dist/coachmarks/index.d.ts +2 -2
  12. package/dist/coachmarks/index.js.map +1 -1
  13. package/dist/coachmarks/index.mjs.map +1 -1
  14. package/dist/{currentSession-CxnP7gAa.d.ts → currentSession-61dcm3V-.d.ts} +19 -3
  15. package/dist/{currentSession-BJBB7i4-.d.mts → currentSession-Bs2JfTJ8.d.mts} +19 -3
  16. package/dist/{decision-BzbiKwk3.d.mts → decision-Bl_M2y3r.d.mts} +1 -1
  17. package/dist/{decision-plDEOCkt.d.ts → decision-Cau5KmP6.d.ts} +1 -1
  18. package/dist/index.d.mts +620 -13
  19. package/dist/index.d.ts +620 -13
  20. package/dist/index.js +1194 -369
  21. package/dist/index.js.map +1 -1
  22. package/dist/index.mjs +1015 -201
  23. package/dist/index.mjs.map +1 -1
  24. package/dist/questionnaire/index.d.mts +69 -23
  25. package/dist/questionnaire/index.d.ts +69 -23
  26. package/dist/questionnaire/index.js +643 -172
  27. package/dist/questionnaire/index.js.map +1 -1
  28. package/dist/questionnaire/index.mjs +608 -137
  29. package/dist/questionnaire/index.mjs.map +1 -1
  30. package/dist/reviews/index.d.mts +24 -12
  31. package/dist/reviews/index.d.ts +24 -12
  32. package/dist/reviews/index.js +507 -173
  33. package/dist/reviews/index.js.map +1 -1
  34. package/dist/reviews/index.mjs +462 -129
  35. package/dist/reviews/index.mjs.map +1 -1
  36. package/dist/showcase/index.d.mts +2 -2
  37. package/dist/showcase/index.d.ts +2 -2
  38. package/dist/showcase/index.js.map +1 -1
  39. package/dist/showcase/index.mjs.map +1 -1
  40. package/dist/transport-DzU-TqZz.d.ts +86 -0
  41. package/dist/transport-f5VVB5hH.d.mts +86 -0
  42. package/dist/{types-GL_hQ0TN.d.mts → types-BcmagF6K.d.mts} +1 -1
  43. package/dist/{types-GL_hQ0TN.d.ts → types-BcmagF6K.d.ts} +1 -1
  44. package/dist/{types-BhpXJGlg.d.ts → types-Buj9Lw9t.d.ts} +15 -3
  45. package/dist/{types-CMuOexw0.d.mts → types-CKFhyrMu.d.mts} +1 -1
  46. package/dist/{types-CMuOexw0.d.ts → types-CKFhyrMu.d.ts} +1 -1
  47. package/dist/{types-A6pTxIZV.d.mts → types-CNUqMK0D.d.mts} +15 -3
  48. package/metro/index.d.ts +18 -1
  49. package/metro/index.js +80 -0
  50. package/package.json +9 -1
  51. package/src/WireOnboarding.tsx +4 -0
  52. package/src/analytics/analyticsFacade.ts +55 -10
  53. package/src/analytics/currentSession.ts +1 -1
  54. package/src/cards/CardGridSelectCard.tsx +253 -0
  55. package/src/cards/ChipSelectCard.tsx +1 -1
  56. package/src/cards/SelectionCard.tsx +15 -19
  57. package/src/cards/index.ts +13 -1
  58. package/src/cards/optionSchema.ts +65 -0
  59. package/src/coachmarks/types.ts +1 -1
  60. package/src/components/CardHandoff.tsx +39 -7
  61. package/src/components/DoneCheck.tsx +94 -0
  62. package/src/components/ModalPaneHost.tsx +141 -0
  63. package/src/components/StepDots.tsx +112 -0
  64. package/src/context/deviceId.ts +43 -0
  65. package/src/device/appVersion.ts +29 -8
  66. package/src/device/deviceContext.ts +14 -1
  67. package/src/device/deviceModel.ts +106 -0
  68. package/src/features/cache.ts +1 -1
  69. package/src/haptics/expo-haptics.d.ts +31 -0
  70. package/src/haptics/haptics.ts +58 -0
  71. package/src/icons/IconRegistry.tsx +53 -0
  72. package/src/icons/WireIcon.tsx +85 -0
  73. package/src/icons/expoIcons.ts +165 -0
  74. package/src/icons/index.ts +18 -0
  75. package/src/icons/vocabulary.ts +154 -0
  76. package/src/index.ts +22 -0
  77. package/src/questionnaire/QuestionnaireGate.tsx +315 -164
  78. package/src/questionnaire/decision.ts +4 -2
  79. package/src/questionnaire/index.ts +3 -2
  80. package/src/questionnaire/steps.ts +261 -0
  81. package/src/questionnaire/types.ts +33 -12
  82. package/src/reviews/ReviewGate.tsx +250 -152
  83. package/src/reviews/index.ts +7 -3
  84. package/src/reviews/transport.ts +77 -3
  85. package/src/reviews/types.ts +13 -0
  86. package/src/session/persistedSession.ts +1 -1
  87. package/src/session-analytics/lifecycle.ts +1 -1
  88. package/src/session-analytics/useSessionStart.ts +2 -2
  89. package/src/showcase/FeatureShowcase.tsx +1 -1
  90. package/src/showcase/showcaseColors.ts +1 -1
  91. package/src/theme/mergeThemeOver.ts +27 -0
  92. package/src/types.ts +8 -0
  93. package/dist/transport-BeO_Brcu.d.mts +0 -40
  94. package/dist/transport-DLpd1v5_.d.ts +0 -40
@@ -1,12 +1,12 @@
1
1
  import React__default from 'react';
2
- import { R as ReviewGateProps, a as ReviewPresentation, U as UseReviewGateOptions, b as ReviewGateController, c as ReviewDecision, d as ReviewStoreConfig } from '../types-A6pTxIZV.mjs';
3
- export { e as RatingRoute, f as ReviewConfig, g as ReviewGateEvent, h as ReviewGateEventName, i as ReviewSubmission, j as ReviewTarget } from '../types-A6pTxIZV.mjs';
2
+ import { R as ReviewGateProps, a as ReviewPresentation, U as UseReviewGateOptions, b as ReviewGateController, c as ReviewDecision, d as ReviewStoreConfig } from '../types-CNUqMK0D.mjs';
3
+ export { e as RatingRoute, f as ReviewConfig, g as ReviewDecisionResponse, h as ReviewGateEvent, i as ReviewGateEventName, j as ReviewSubmission, k as ReviewTarget } from '../types-CNUqMK0D.mjs';
4
4
  export { C as ReviewModal, a as ReviewModalHandle, b as ReviewModalProps } from '../CenteredModal-C3qQBHsA.mjs';
5
- export { G as GateRules, a as GateSignals, b as buildReviewSubmission, d as decideReview, e as evaluateGate, r as resolveRules, c as routeRating } from '../decision-BzbiKwk3.mjs';
5
+ export { G as GateRules, a as GateSignals, b as buildReviewSubmission, d as decideReview, e as evaluateGate, r as resolveRules, c as routeRating } from '../decision-Bl_M2y3r.mjs';
6
6
  import { c as OnboardingFonts } from '../types-BKfpdZzX.mjs';
7
- export { R as ReportAppEventOptions, r as reportAppEvent, s as submitReview } from '../transport-BeO_Brcu.mjs';
8
- import '../types-GL_hQ0TN.mjs';
9
- import '../types-CMuOexw0.mjs';
7
+ export { F as FetchReviewDecisionOptions, R as ReportAppEventOptions, f as fetchReviewDecision, r as reportAppEvent, s as submitReview } from '../transport-f5VVB5hH.mjs';
8
+ import '../types-BcmagF6K.mjs';
9
+ import '../types-CKFhyrMu.mjs';
10
10
 
11
11
  /**
12
12
  * Runtime helpers for the review gate: the `wire_review_*` gate keys and small
@@ -27,17 +27,29 @@ declare const reviewSessionsKey: (id: string) => string;
27
27
  *
28
28
  * A NEUTRAL prompt ("Enjoying <app>?") over five tappable stars. The honest split:
29
29
  * • 5 stars → the native store review (expo-store-review when available, else the
30
- * configured store URL). Fires `store_review_requested`.
31
- * • 1-4 stars a feather-light feedback form: TWO optional inputs, the "why this
32
- * rating" opinion box (~4 lines) and a smaller "what can you suggest" box, POSTed
33
- * to the Wire server (`feedback_text` + `suggestion`). The rating is the only
34
- * mandatory action, so Send works with either box, both, or neither. Warm
35
- * thank-you state, never a dead end.
30
+ * configured store URL). Fires `store_review_requested`, and POSTs a text-less
31
+ * `stars=5` row carrying `meta.store_route` so promoters reach the server too
32
+ * (before 2026-07-16 this route posted nothing see `pickRating`).
33
+ * 1-4 stars a feedback form: the "why this rating" opinion box (~4 lines, MANDATORY
34
+ * as of Malik's 2026-07-16 ruling) and a smaller optional "what can you suggest" box,
35
+ * POSTed to the Wire server (`feedback_text` + `suggestion`). Warm thank-you state,
36
+ * never a dead end.
37
+ *
38
+ * EXACTLY ONE row is POSTed per gate, at the last responsible moment — see `postOnce`. A
39
+ * detractor who abandons instead of typing still has their rating posted (`meta.abandoned`),
40
+ * so forcing the text can never cost us the detractor data it exists to collect.
36
41
  *
37
42
  * The form NEVER asks for identity (no name / email / contact field): the host already
38
43
  * identifies the user via `sessionId` + `meta` (e.g. user_id, device_key), which is all
39
44
  * the POST body carries alongside the rating and the free text.
40
45
  *
46
+ * Motion (2026-07-16): the three phases used to swap IN PLACE with no transition. They now
47
+ * ride `ModalPaneHost`, the same pane-slide primitive the questionnaire steps use, and the
48
+ * thank-you plays the shared `DoneCheck` payoff before the existing 1500ms auto-close.
49
+ * Picking a star fires a haptic through the lazy, optional `expo-haptics` peer — silently
50
+ * absent when the host has not installed it. The popup's own entrance is unchanged: it is
51
+ * the CenteredModal shell's spring, which already animates.
52
+ *
41
53
  * Every visual value comes from the OnboardingTheme (useOnboardingTheme). Analytics are
42
54
  * callback-based (mirroring the coachmark convention): the host wires `onEvent` to its own
43
55
  * analytics. No PII in events — feedback text goes ONLY in the POST body.
@@ -1,12 +1,12 @@
1
1
  import React__default from 'react';
2
- import { R as ReviewGateProps, a as ReviewPresentation, U as UseReviewGateOptions, b as ReviewGateController, c as ReviewDecision, d as ReviewStoreConfig } from '../types-BhpXJGlg.js';
3
- export { e as RatingRoute, f as ReviewConfig, g as ReviewGateEvent, h as ReviewGateEventName, i as ReviewSubmission, j as ReviewTarget } from '../types-BhpXJGlg.js';
2
+ import { R as ReviewGateProps, a as ReviewPresentation, U as UseReviewGateOptions, b as ReviewGateController, c as ReviewDecision, d as ReviewStoreConfig } from '../types-Buj9Lw9t.js';
3
+ export { e as RatingRoute, f as ReviewConfig, g as ReviewDecisionResponse, h as ReviewGateEvent, i as ReviewGateEventName, j as ReviewSubmission, k as ReviewTarget } from '../types-Buj9Lw9t.js';
4
4
  export { C as ReviewModal, a as ReviewModalHandle, b as ReviewModalProps } from '../CenteredModal-Cdgns6--.js';
5
- export { G as GateRules, a as GateSignals, b as buildReviewSubmission, d as decideReview, e as evaluateGate, r as resolveRules, c as routeRating } from '../decision-plDEOCkt.js';
5
+ export { G as GateRules, a as GateSignals, b as buildReviewSubmission, d as decideReview, e as evaluateGate, r as resolveRules, c as routeRating } from '../decision-Cau5KmP6.js';
6
6
  import { c as OnboardingFonts } from '../types-BKfpdZzX.js';
7
- export { R as ReportAppEventOptions, r as reportAppEvent, s as submitReview } from '../transport-DLpd1v5_.js';
8
- import '../types-GL_hQ0TN.js';
9
- import '../types-CMuOexw0.js';
7
+ export { F as FetchReviewDecisionOptions, R as ReportAppEventOptions, f as fetchReviewDecision, r as reportAppEvent, s as submitReview } from '../transport-DzU-TqZz.js';
8
+ import '../types-BcmagF6K.js';
9
+ import '../types-CKFhyrMu.js';
10
10
 
11
11
  /**
12
12
  * Runtime helpers for the review gate: the `wire_review_*` gate keys and small
@@ -27,17 +27,29 @@ declare const reviewSessionsKey: (id: string) => string;
27
27
  *
28
28
  * A NEUTRAL prompt ("Enjoying <app>?") over five tappable stars. The honest split:
29
29
  * • 5 stars → the native store review (expo-store-review when available, else the
30
- * configured store URL). Fires `store_review_requested`.
31
- * • 1-4 stars a feather-light feedback form: TWO optional inputs, the "why this
32
- * rating" opinion box (~4 lines) and a smaller "what can you suggest" box, POSTed
33
- * to the Wire server (`feedback_text` + `suggestion`). The rating is the only
34
- * mandatory action, so Send works with either box, both, or neither. Warm
35
- * thank-you state, never a dead end.
30
+ * configured store URL). Fires `store_review_requested`, and POSTs a text-less
31
+ * `stars=5` row carrying `meta.store_route` so promoters reach the server too
32
+ * (before 2026-07-16 this route posted nothing see `pickRating`).
33
+ * 1-4 stars a feedback form: the "why this rating" opinion box (~4 lines, MANDATORY
34
+ * as of Malik's 2026-07-16 ruling) and a smaller optional "what can you suggest" box,
35
+ * POSTed to the Wire server (`feedback_text` + `suggestion`). Warm thank-you state,
36
+ * never a dead end.
37
+ *
38
+ * EXACTLY ONE row is POSTed per gate, at the last responsible moment — see `postOnce`. A
39
+ * detractor who abandons instead of typing still has their rating posted (`meta.abandoned`),
40
+ * so forcing the text can never cost us the detractor data it exists to collect.
36
41
  *
37
42
  * The form NEVER asks for identity (no name / email / contact field): the host already
38
43
  * identifies the user via `sessionId` + `meta` (e.g. user_id, device_key), which is all
39
44
  * the POST body carries alongside the rating and the free text.
40
45
  *
46
+ * Motion (2026-07-16): the three phases used to swap IN PLACE with no transition. They now
47
+ * ride `ModalPaneHost`, the same pane-slide primitive the questionnaire steps use, and the
48
+ * thank-you plays the shared `DoneCheck` payoff before the existing 1500ms auto-close.
49
+ * Picking a star fires a haptic through the lazy, optional `expo-haptics` peer — silently
50
+ * absent when the host has not installed it. The popup's own entrance is unchanged: it is
51
+ * the CenteredModal shell's spring, which already animates.
52
+ *
41
53
  * Every visual value comes from the OnboardingTheme (useOnboardingTheme). Analytics are
42
54
  * callback-based (mirroring the coachmark convention): the host wires `onEvent` to its own
43
55
  * analytics. No PII in events — feedback text goes ONLY in the POST body.