@solidrt/core 0.0.32 → 0.0.34

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": "@solidrt/core",
3
- "version": "0.0.32",
3
+ "version": "0.0.34",
4
4
  "license": "MIT",
5
5
  "author": "Antoine van Wel",
6
6
  "type": "module",
@@ -27,7 +27,7 @@
27
27
  "colord": "^2.9.3"
28
28
  },
29
29
  "devDependencies": {
30
- "@solidrt/flux-types": "0.0.32"
30
+ "@solidrt/flux-types": "0.0.34"
31
31
  },
32
32
  "peerDependencies": {
33
33
  "@solidjs/signals": "2.0.0-beta.20",
@@ -51,6 +51,57 @@ declare module "srt:dev" {
51
51
  export function registerDebug(name: string, fn: (args?: any) => unknown): void
52
52
  }
53
53
 
54
+ // Installed-app management (lattice), the launcher's surface over the client's
55
+ // version store. Present only in go/dev client builds; elsewhere `available`
56
+ // is false, `list` returns [], and launch/remove are no-ops.
57
+ declare module "srt:apps" {
58
+ export const available: boolean
59
+ /**
60
+ * An installed app: id, display name (the installed manifest's displayName,
61
+ * defaulting to the id) and current version id (manifest hash).
62
+ */
63
+ export type InstalledApp = { id: string; name: string; version: string }
64
+ /** Installed apps, sorted by name. */
65
+ export function list(): InstalledApp[]
66
+ /** A stored version: id (manifest hash), bytes on disk, whether it is the current one. */
67
+ export type AppVersion = { id: string; size: number; current: boolean }
68
+ /** One file in a listing: a relative path and its size in bytes. */
69
+ export type AppFile = { path: string; size: number }
70
+ /**
71
+ * Usage details for one installed app: total bytes of its stored versions
72
+ * (assets shared between versions via hardlinks count in each) and of its
73
+ * data sandbox, plus the stored versions (current first, then newest first)
74
+ * and three file listings, each sorted by path. `assets` is the current
75
+ * version's manifest claim (declared sizes); `files` and `data` are disk
76
+ * walks of the current version dir and the data sandbox - the truth, so a
77
+ * divergence from the manifest is visible.
78
+ */
79
+ export type AppInfo = {
80
+ id: string
81
+ name: string
82
+ version: string
83
+ installSize: number
84
+ dataSize: number
85
+ versions: AppVersion[]
86
+ assets: AppFile[]
87
+ files: AppFile[]
88
+ data: AppFile[]
89
+ }
90
+ /** Usage details for an installed app. Throws when the app is not installed. */
91
+ export function info(id: string): AppInfo
92
+ /**
93
+ * Boot the app's installed current version, replacing the running app (the
94
+ * launcher). Throws when the app is not installed. Custom fonts of the
95
+ * launched app register at client startup only, not mid-session.
96
+ */
97
+ export function launch(id: string): void
98
+ /**
99
+ * Full uninstall: the app's versions, state and data sandbox. Throws when
100
+ * the app is not installed.
101
+ */
102
+ export function remove(id: string): void
103
+ }
104
+
54
105
  // Frame draw (lattice runner). renderFrame() synchronously renders the current
55
106
  // frame: layout, the postLayout hook, paint and hover refresh, then builds and
56
107
  // submits the display list. To schedule a future frame instead, use
package/src/types.d.ts CHANGED
@@ -306,7 +306,7 @@ export interface TextProps extends Position, PaintProps, PointerProps {
306
306
  w?: number
307
307
  // Reported-bounds height only; paragraph height always falls out of the text.
308
308
  h?: number
309
- fontFamily?: "sans" | "mono" | (string & {})
309
+ fontFamily?: "sans" | "serif" | "mono" | (string & {})
310
310
  fontSize?: number
311
311
  /**
312
312
  * Line height as a MULTIPLIER of fontSize, not pixels (the theme uses