trx-cli 0.1.11

A Modern Cross-Platform Package Manager TUI
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
/*
 * Matrix Theme Overlay
 * ─────────────────────────────────────────────────────────────
 * Layered on top of the existing design system.
 * Touches: CSS custom properties, utility classes, keyframes.
 * Does not touch: component structure, spacing, layout grid,
 *                 Tailwind config, or existing Tailwind classes.
 *
 * To apply: add the utility classes below to JSX elements.
 * See matrix-tokens.ts for the JS-side token mirror.
 */

/* ── Design Tokens ─────────────────────────────────────────── */
@layer base {
  :root {
    /*
     * Muted emerald palette.
     * Deep fills → mid borders → bright text, in that order of
     * darkness. The "text" value (#52B788) is the only one safe
     * for actual typographic content (WCAG AA: ~7.9:1 on #0b0b0b,
     * ~7.0:1 on #111111).  All darker values are for non-text use.
     */
    --mx-emerald-deep:   #162E25;
    --mx-emerald:        #1F4A3A;
    --mx-emerald-mid:    #2D6B54;
    --mx-emerald-bright: #3D8F6E;
    --mx-emerald-text:   #52B788;

    /* rgba fills — use for backgrounds, never body text */
    --mx-emerald-subtle: rgba(31, 74, 58, 0.10);
    --mx-emerald-glow:   rgba(31, 74, 58, 0.20);

    /* Desaturated teal — secondary accent */
    --mx-teal:           #1A3A3F;
    --mx-teal-border:    rgba(26, 58, 63, 0.35);

    /* Cool gunmetal — alternate surface accent */
    --mx-gunmetal:       #1C2428;

    /*
     * 1px borders — never fills.
     * "border" is subtle at rest; "border-mid" on hover;
     * "border-bright" on active / focus.
     */
    --mx-border:         rgba(45, 107, 84, 0.25);
    --mx-border-mid:     rgba(61, 143, 110, 0.38);
    --mx-border-bright:  rgba(82, 183, 136, 0.55);

    /* Emerald focus glow — use as box-shadow on :focus-visible */
    --mx-focus-shadow:
      0 0 0 2px rgba(31, 74, 58, 0.55),
      0 0 0 4px rgba(31, 74, 58, 0.22),
      0 0 16px rgba(31, 74, 58, 0.28);

    /* Grid overlay */
    --mx-grid-size:  32px;
    --mx-grid-color: rgba(45, 107, 84, 0.12);

    /* Scanlines */
    --mx-scan-gap:     3px;
    --mx-scan-stripe:  rgba(0, 0, 0, 0.055);

    /* Monospace stack for labels, numerics, prefixes */
    --mx-mono: var(--font-geist-mono, 'IBM Plex Mono', 'JetBrains Mono', monospace);
  }
}

/* ── Grid Overlay ──────────────────────────────────────────── */
/*
 * Apply to a <section> or wrapper to add a faint lattice behind
 * content. Works best on hero or features sections — not every
 * section, or it loses impact.
 *
 * Usage: className="mx-grid"
 */
.mx-grid {
  background-image:
    linear-gradient(var(--mx-grid-color) 1px, transparent 1px),
    linear-gradient(90deg, var(--mx-grid-color) 1px, transparent 1px);
  background-size: var(--mx-grid-size) var(--mx-grid-size);
  background-position: center top;
}

/* ── Scanline Texture ──────────────────────────────────────── */
/*
 * Horizontal scanline texture rendered as a ::before overlay.
 * Uses isolation so child z-indices work correctly.
 * The ::before sits at z-index: 2 — content in the container
 * should be relatively positioned with z-index: 1+ to appear
 * over the scanlines.
 *
 * Usage: className="mx-scanlines"
 *
 * Good candidates: HeroTerminal wrapper, feature card inset wells,
 * the curl install block.
 */
.mx-scanlines {
  isolation: isolate;
  position: relative;
}

.mx-scanlines::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  z-index: 2;
  background: repeating-linear-gradient(
    to bottom,
    transparent 0px,
    transparent calc(var(--mx-scan-gap) * 2 - 1px),
    var(--mx-scan-stripe) calc(var(--mx-scan-gap) * 2 - 1px),
    var(--mx-scan-stripe) calc(var(--mx-scan-gap) * 2)
  );
}

/* ── 1px Accent Border ─────────────────────────────────────── */
/*
 * Thin emerald border, dims at rest, brightens on hover.
 * Layer over existing RAISED_BORDER (white/5) — they coexist.
 *
 * Usage: className="mx-border"
 */
.mx-border {
  border: 1px solid var(--mx-border);
  transition: border-color 0.18s ease;
}
.mx-border:hover {
  border-color: var(--mx-border-mid);
}

/* ── Ambient Emerald Glow ──────────────────────────────────── */
/*
 * Soft outer glow. Use on 1–2 hero elements or the primary CTA
 * section — overusing kills the effect.
 *
 * Usage: className="mx-glow"
 */
.mx-glow {
  box-shadow:
    0 0 0 1px var(--mx-border),
    0 0 20px var(--mx-emerald-glow),
    0 0 40px rgba(31, 74, 58, 0.08);
  transition: box-shadow 0.3s ease;
}

.mx-glow:hover {
  box-shadow:
    0 0 0 1px var(--mx-border-mid),
    0 0 30px var(--mx-emerald-glow),
    0 0 60px rgba(31, 74, 58, 0.12);
}

/* ── Emerald Focus Ring ─────────────────────────────────────── */
/*
 * Drop onto interactive elements to replace the existing purple
 * ring from FOCUS_RING with an emerald Matrix variant.
 * If you keep FOCUS_RING on most elements, only apply this to
 * the install CTA or other high-visibility controls.
 *
 * Usage: className="mx-focus"
 */
.mx-focus:focus-visible {
  outline: none;
  box-shadow: var(--mx-focus-shadow);
}

/* ── Terminal Section Label ─────────────────────────────────── */
/*
 * Monospace uppercase label with a terminal prefix.
 * Three variants: // (section), > (status), $ (command).
 * All pass WCAG AA — #52B788 on #0b0b0b is ~7.9:1.
 *
 * Usage:
 *   <span className="mx-label">Features</span>        → // FEATURES
 *   <span className="mx-label mx-label-gt">Install</span> → > INSTALL
 *   <span className="mx-label mx-label-sh">Run</span>     → $ RUN
 */
.mx-label {
  display: inline-block;
  font-family: var(--mx-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mx-emerald-text);
  line-height: 1;
}

.mx-label::before {
  content: '// ';
  opacity: 0.5;
}

.mx-label.mx-label-gt::before {
  content: '> ';
  opacity: 0.5;
}

.mx-label.mx-label-sh::before {
  content: '$ ';
  opacity: 0.5;
}

/* ── Cursor Blink ───────────────────────────────────────────── */
/*
 * Appends a blinking block cursor after element text.
 * Interval is 530ms — intentionally matches HeroTerminal.tsx.
 *
 * Usage: className="mx-cursor"
 *   e.g. on an h2 or a status line span
 */
@keyframes mx-cursor-blink {
  0%,  49.9% { opacity: 1; }
  50%, 100%  { opacity: 0; }
}

.mx-cursor::after {
  content: '';
  display: inline-block;
  margin-left: 2px;
  color: var(--mx-emerald-text);
  animation: mx-cursor-blink 530ms step-end infinite;
  font-family: var(--mx-mono);
  font-size: 0.85em;
  line-height: 1;
  vertical-align: baseline;
}

/* ── Character Reveal ───────────────────────────────────────── */
/*
 * One-shot clip-path sweep, left → right. Reads as text being
 * typed into view. Use at most ONCE per page, on the primary h1.
 *
 * Motion is suppressed for users who prefer reduced motion.
 *
 * CSS var --mx-reveal-delay lets you stagger multiple lines:
 *   style={{ '--mx-reveal-delay': '0.1s' }}
 *
 * Usage:
 *   <h1 className="mx-reveal">...</h1>
 *   <span className="mx-reveal" style={{ '--mx-reveal-delay': '0.4s' }}>...</span>
 */
@keyframes mx-char-reveal {
  from { clip-path: inset(0 100% 0 0); }
  to   { clip-path: inset(0 0%   0 0); }
}

.mx-reveal {
  animation: mx-char-reveal 0.85s cubic-bezier(0.16, 1, 0.3, 1)
    var(--mx-reveal-delay, 0s) both;
}

@media (prefers-reduced-motion: reduce) {
  .mx-reveal {
    animation: none;
    clip-path: none;
    opacity: 1;
  }
  .mx-cursor::after {
    animation: none;
    opacity: 1;
  }
}

/* ── Heading Glitch ─────────────────────────────────────────── */
/*
 * Periodic visual glitch: micro-translate + skewX + chromatic
 * aberration via text-shadow. Fires ~every 9s.
 * Works on any element — no data-text attribute needed.
 * Does not override inline color styles (uses text-shadow instead).
 *
 * Usage: className="mx-glitch"
 * Combine with mx-reveal: className="mx-reveal mx-glitch"
 */
@keyframes mx-heading-glitch {
  /* Resting state — most of the cycle is clean */
  0%, 36%, 100% {
    transform: none;
    text-shadow: none;
    filter: none;
    opacity: 1;
  }

  /* ── Hit 1 ── hard slam left */
  37% {
    transform: translate(-12px, 0) skewX(-7deg);
    text-shadow:
      12px  0    rgba(52, 183, 136, 1),
      -10px 0    rgba(31,  74,  58, 0.95),
        0   0    40px rgba(52, 183, 136, 0.35);
    filter: blur(0.6px) brightness(1.2);
    opacity: 0.78;
  }
  /* snap right */
  38% {
    transform: translate(9px, -2px) skewX(5deg);
    text-shadow:
      -9px 0 rgba(52, 183, 136, 0.95),
       7px 0 rgba(61, 143, 110, 0.85);
    filter: none;
    opacity: 1;
  }
  /* settle */
  39% {
    transform: translate(-4px, 1px) skewX(-2deg);
    text-shadow:
      4px  0 rgba(52, 183, 136, 0.55),
      -3px 0 rgba(31,  74,  58, 0.45);
    opacity: 0.93;
  }
  /* back to clean */
  40% {
    transform: none;
    text-shadow: none;
    filter: none;
    opacity: 1;
  }

  /* ── Hit 2 ── stutter, opposite direction */
  42% {
    transform: translate(14px, 0) skewX(8deg);
    text-shadow:
      -14px 0 rgba(52, 183, 136, 1),
       11px 0 rgba(31,  74,  58, 0.9),
         0  0 50px rgba(52, 183, 136, 0.3);
    filter: blur(0.4px);
    opacity: 0.72;
  }
  43% {
    transform: translate(-7px, 2px) skewX(-4deg);
    text-shadow:
      7px  0 rgba(52, 183, 136, 0.80),
      -6px 0 rgba(61, 143, 110, 0.70);
    filter: none;
    opacity: 0.96;
  }
  44% {
    transform: translate(2px, 0);
    text-shadow: 2px 0 rgba(52, 183, 136, 0.25);
    opacity: 1;
  }
  45% {
    transform: none;
    text-shadow: none;
    filter: none;
    opacity: 1;
  }
}

.mx-glitch {
  animation: mx-heading-glitch 3.5s linear 1s infinite;
}

/* When both classes are present, run both animations on the same element */
.mx-reveal.mx-glitch {
  animation:
    mx-char-reveal 0.85s cubic-bezier(0.16, 1, 0.3, 1) var(--mx-reveal-delay, 0s) both,
    mx-heading-glitch 3.5s linear 1.5s infinite;
}

@media (prefers-reduced-motion: reduce) {
  .mx-glitch,
  .mx-reveal.mx-glitch {
    animation: none;
  }
}

/* ── Fade-up Entrance ───────────────────────────────────────── */
/*
 * Gentle fade + translate for secondary elements.
 * CSS var --mx-fade-delay for staggering.
 *
 * Usage: className="mx-fade-up"
 */
@keyframes mx-fade-up {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mx-fade-up {
  animation: mx-fade-up 0.5s ease-out var(--mx-fade-delay, 0s) both;
}

@media (prefers-reduced-motion: reduce) {
  .mx-fade-up {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

/* ── Accent Text ────────────────────────────────────────────── */
/*
 * Emerald-tinted monospace text. For numeric callouts, version
 * strings, or status values — not for body copy.
 *
 * Usage: className="mx-accent"
 */
.mx-accent {
  color: var(--mx-emerald-text);
  font-family: var(--mx-mono);
}

/* ── Status Badge ───────────────────────────────────────────── */
/*
 * Small dot-prefixed badge with emerald fill.
 * An alternative to raisedPill() for Matrix-accented tags.
 *
 * Usage: <span className="mx-badge">Active</span>
 */
.mx-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 9999px;
  font-family: var(--mx-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--mx-emerald-text);
  background: var(--mx-emerald-subtle);
  border: 1px solid var(--mx-border);
}

.mx-badge::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--mx-emerald-text);
  flex-shrink: 0;
  box-shadow: 0 0 6px var(--mx-emerald-glow);
}