driggsby 0.7.4 → 0.7.6

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.
@@ -7,10 +7,6 @@ import { defaultCredentialEnvironment, } from "../credentials/store.js";
7
7
  import { quotedForTerminal, wrapProse } from "../terminal-text.js";
8
8
  import { deployFailure, MAX_SERVER_TEXT_CHARS, requireDeploySession, } from "./api-session.js";
9
9
  const DEPLOY_RETRY_COMMAND = "npx driggsby@latest deploy";
10
- // Driggsby's Dashboards page runs every dashboard live in its tile, phones
11
- // included, so a heavy page opens slowly there: past this, the deploy says
12
- // so. A source map never loads with the page, so it doesn't count.
13
- const PAGE_WEIGHT_BUDGET_BYTES = 1_000_000;
14
10
  function defaultDeployIo() {
15
11
  return {
16
12
  out: (text) => {
@@ -65,10 +61,6 @@ export async function runDeploy(options, environment = defaultCredentialEnvironm
65
61
  if (collected.skippedSymlinks.length > 0) {
66
62
  io.out(`\n${symlinkNote(collected.skippedSymlinks)}\n`);
67
63
  }
68
- const weight = pageWeight(collected.files);
69
- if (weight > PAGE_WEIGHT_BUDGET_BYTES) {
70
- io.out(`\n${weightNote(weight)}\n`);
71
- }
72
64
  if (createdApp !== null) {
73
65
  io.out(`\n${wrapProse(`This deploy created your app. Its address is assigned by Driggsby — the name you picked plus a unique ending — and it's saved in driggsby.json, so every later deploy targets it. If this project lives in git, commit the updated driggsby.json: it's the only record of your app's address, and a fresh checkout without it would create a second app.`)}\n`);
74
66
  }
@@ -121,18 +113,6 @@ function symlinkNote(skipped) {
121
113
  const more = skipped.length > 3 ? ` and ${skipped.length - 3} more` : "";
122
114
  return wrapProse(`Note: symlinks don't deploy — skipped ${shown}${more}.`);
123
115
  }
124
- function pageWeight(files) {
125
- return files
126
- .filter((file) => !file.path.toLowerCase().endsWith(".map"))
127
- .reduce((total, file) => total + file.byteSize, 0);
128
- }
129
- function weightNote(bytes) {
130
- // formatBytes rounds to a tenth, so a weight just past the budget reads
131
- // as the budget itself; it says so rather than "1 MB ... past 1 MB".
132
- const budget = formatBytes(PAGE_WEIGHT_BUDGET_BYTES);
133
- const size = formatBytes(bytes) === budget ? `just over ${budget}` : formatBytes(bytes);
134
- return wrapProse(`Note: this app is ${size}. Driggsby's Dashboards page runs each dashboard live in its tile, phones included, and past ${budget} it opens there slowly. Keep what the page loads under ${budget}.`);
135
- }
136
116
  function nextSection(outcome) {
137
117
  if (!outcome.live) {
138
118
  return ("Next:\n" +
@@ -13,8 +13,8 @@
13
13
  export const STYLES_CSS = `/* Driggsby's console palette, so this page reads as part of the app it
14
14
  opens inside. Change these together if you re-theme (all but
15
15
  --font-sans, which stays as it is); keep --bg-app equal to the
16
- "background" in driggsby.json. The status tones are the console's own,
17
- for gains, losses, warnings, and a live dot. */
16
+ "background" in driggsby.json. The status tones are for gains, losses,
17
+ warnings, and a live dot. */
18
18
  :root {
19
19
  color-scheme: dark;
20
20
  --bg-app: #000000;
@@ -35,18 +35,14 @@ export const STYLES_CSS = `/* Driggsby's console palette, so this page reads as
35
35
  --ease: cubic-bezier(0.2, 0, 0, 1);
36
36
  }
37
37
 
38
- /* Inter, which Driggsby serves at /-/inter.woff2 on this app's own origin
39
- (driggsby dev serves the same file there), so nothing loads from another
40
- site. Inter is the only font a dashboard uses: set all text with
41
- var(--font-sans), keep that stack as it is (the faces after Inter only
42
- stand in if the font is slow or fails to load, or lacks a character),
43
- and name no other font anywhere else. A <canvas> or a chart library's
44
- font setting can't read var(): name "Inter" there, followed only by
45
- sans-serif, and draw a canvas after document.fonts.ready. A face the
46
- page doesn't bring with it falls back to whatever the viewer's device
47
- has, and looks different on every phone and computer. Text waits for
48
- the font (font-display: block, preloaded) rather than flash another
49
- face first. */
38
+ /* Inter, from this page's own address, so it looks the same everywhere
39
+ it's shown. Inter is the only font a dashboard uses: set all text with
40
+ var(--font-sans), keep that stack as it is, and name no other font
41
+ anywhere else. A <canvas> or a chart library's font setting can't read
42
+ var(): name "Inter" there, followed only by sans-serif, and draw a
43
+ canvas after document.fonts.ready. Text waits for the font
44
+ (font-display: block, preloaded) rather than flash another face
45
+ first. */
50
46
  @font-face {
51
47
  font-family: "Inter";
52
48
  src: url("/-/inter.woff2") format("woff2");
@@ -79,8 +75,7 @@ textarea {
79
75
  }
80
76
 
81
77
  /* A compact column: a few figures and a short list read best close
82
- together. The console's own pages run wider (75rem); widen this as the
83
- page grows. */
78
+ together. Widen it as the page grows. */
84
79
  main {
85
80
  max-width: 800px;
86
81
  margin: 0 auto;
@@ -105,8 +100,7 @@ h2 {
105
100
  letter-spacing: -0.02em;
106
101
  }
107
102
 
108
- /* The console's stat tiles: a card per figure, 16px apart, the row
109
- capped at the console's 920px. */
103
+ /* A card per figure, 16px apart. */
110
104
  .stat-grid {
111
105
  display: grid;
112
106
  grid-template-columns: repeat(4, minmax(0, 1fr));
@@ -114,9 +114,8 @@ export const APP_JS = `// Your app's code. Edit anything — driggsby dev reload
114
114
  // search_cash_transactions bank and card transaction search
115
115
  // search_investment_activity trades, dividends, and transfers
116
116
  //
117
- // Params mirror Driggsby's public MCP tools of the same names, with one
118
- // simplification: those tools require a "reason" string, but a watch can
119
- // leave it out — Driggsby fills one in naming the dashboard.
117
+ // Params mirror Driggsby's public MCP tools of the same names; a watch
118
+ // needs no "reason".
120
119
  //
121
120
  // To see a tool's exact result shape before writing render code, run it
122
121
  // once from the terminal — the JSON it prints is what the callback gets:
@@ -236,9 +235,9 @@ function renderAccounts(result) {
236
235
  const displayName = asText(account.account_display_name);
237
236
  const institution = asText(account.institution_name);
238
237
  const mask = asText(account.account_mask_last4);
239
- // The institution's initial on a round pill, the way Driggsby's own
240
- // account rows draw it. Array.from keeps an emoji-leading name from
241
- // breaking the render (it splits by whole character, not UTF-16 half).
238
+ // The institution's initial on a round pill. Array.from keeps an
239
+ // emoji-leading name from breaking the render (it splits by whole
240
+ // character, not UTF-16 half).
242
241
  const initialSource = (institution || displayName).trim();
243
242
  const initial = (Array.from(initialSource)[0] || "?").toUpperCase();
244
243
  const institutionLine = [institution, mask ? "····" + mask : ""].filter(Boolean).join(" ");
@@ -353,9 +352,8 @@ function settledRenderer(render) {
353
352
 
354
353
  // ---------------------------------------------------------------------------
355
354
  // When a call fails. A watch whose call fails never runs its callback; it
356
- // runs onError instead, with { message, kind }, once for each new failure —
357
- // after Driggsby has already retried a call that failed because it was busy
358
- // or slow. The section says why where its data would be: in place of its
355
+ // runs onError instead, with { message, kind }, once for each new failure.
356
+ // The section says why where its data would be: in place of its
359
357
  // skeleton, so a failure never looks like a page still loading, or under
360
358
  // the data it already shows, which stays. The watch asks again on its own
361
359
  // the next time your data changes, and the next good result repaints the
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "driggsby",
3
- "version": "0.7.4",
3
+ "version": "0.7.6",
4
4
  "description": "Set up and build on Driggsby, the MCP server for personal finance.",
5
5
  "license": "Apache-2.0 AND OFL-1.1",
6
6
  "repository": {
@@ -30,7 +30,7 @@
30
30
  "node": ">=18"
31
31
  },
32
32
  "dependencies": {
33
- "@driggsby/deploy": "0.7.4",
34
- "@driggsby/sdk": "0.7.4"
33
+ "@driggsby/deploy": "0.7.6",
34
+ "@driggsby/sdk": "0.7.6"
35
35
  }
36
36
  }