@bigpixelrocket/uiok 0.2.3 → 0.3.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 (116) hide show
  1. package/CHANGELOG.md +26 -1
  2. package/dist/charts/Sparkline.d.ts +20 -0
  3. package/dist/charts/Sparkline.js +12 -0
  4. package/dist/charts/Sparkline.logic.d.ts +9 -0
  5. package/dist/charts/Sparkline.logic.js +27 -0
  6. package/dist/charts/charts.css +17 -0
  7. package/dist/charts/index.d.ts +2 -0
  8. package/dist/charts/index.js +2 -0
  9. package/dist/dialog/ConfirmDialog.d.ts +11 -1
  10. package/dist/dialog/ConfirmDialog.js +3 -2
  11. package/dist/dialog/ModalDialog.d.ts +8 -0
  12. package/dist/dialog/ModalDialog.js +4 -2
  13. package/dist/dialog/ProgressDialog.d.ts +34 -0
  14. package/dist/dialog/ProgressDialog.js +40 -0
  15. package/dist/dialog/TypedNameDialog.d.ts +36 -0
  16. package/dist/dialog/TypedNameDialog.js +17 -0
  17. package/dist/dialog/index.d.ts +5 -2
  18. package/dist/dialog/index.js +4 -1
  19. package/dist/field/Switch.d.ts +26 -0
  20. package/dist/field/Switch.js +20 -0
  21. package/dist/field/index.d.ts +3 -2
  22. package/dist/field/index.js +3 -2
  23. package/dist/frame/AppRoot.d.ts +44 -0
  24. package/dist/frame/AppRoot.js +26 -0
  25. package/dist/frame/Dock.d.ts +88 -0
  26. package/dist/frame/Dock.js +129 -0
  27. package/dist/frame/FilterChips.d.ts +28 -0
  28. package/dist/frame/FilterChips.js +14 -0
  29. package/dist/frame/PageParts.d.ts +69 -0
  30. package/dist/frame/PageParts.js +60 -0
  31. package/dist/frame/PaneSplit.d.ts +74 -0
  32. package/dist/frame/PaneSplit.js +197 -0
  33. package/dist/frame/SidebarResizer.d.ts +35 -0
  34. package/dist/frame/SidebarResizer.js +43 -0
  35. package/dist/frame/StatusNotice.d.ts +20 -0
  36. package/dist/frame/StatusNotice.js +13 -0
  37. package/dist/frame/Tree.d.ts +140 -0
  38. package/dist/frame/Tree.js +141 -0
  39. package/dist/frame/TreeToggle.d.ts +18 -0
  40. package/dist/frame/TreeToggle.js +17 -0
  41. package/dist/frame/WindowFrame.d.ts +57 -0
  42. package/dist/frame/WindowFrame.js +19 -0
  43. package/dist/frame/frame.css +801 -0
  44. package/dist/frame/index.d.ts +22 -0
  45. package/dist/frame/index.js +22 -0
  46. package/dist/frame/sharedRef.d.ts +8 -0
  47. package/dist/frame/sharedRef.js +26 -0
  48. package/dist/index.d.ts +3 -0
  49. package/dist/index.js +3 -0
  50. package/dist/labels/UiokLabels.d.ts +3 -0
  51. package/dist/labels/UiokLabels.js +3 -1
  52. package/dist/labels/dialog.d.ts +12 -0
  53. package/dist/labels/dialog.js +7 -1
  54. package/dist/labels/index.d.ts +1 -0
  55. package/dist/labels/index.js +1 -0
  56. package/dist/labels/settings.d.ts +46 -0
  57. package/dist/labels/settings.js +29 -0
  58. package/dist/listing/EmptyState.d.ts +40 -0
  59. package/dist/listing/EmptyState.js +14 -0
  60. package/dist/listing/index.d.ts +3 -1
  61. package/dist/listing/index.js +3 -1
  62. package/dist/listing/listing.css +66 -2
  63. package/dist/log/LogWell.d.ts +34 -0
  64. package/dist/log/LogWell.js +39 -0
  65. package/dist/log/LogWell.logic.d.ts +16 -0
  66. package/dist/log/LogWell.logic.js +26 -0
  67. package/dist/log/index.d.ts +8 -0
  68. package/dist/log/index.js +8 -0
  69. package/dist/log/log.css +57 -0
  70. package/dist/pane/Pane.d.ts +49 -0
  71. package/dist/pane/Pane.js +17 -0
  72. package/dist/pane/PaneKeys.d.ts +10 -3
  73. package/dist/pane/PaneKeys.js +26 -7
  74. package/dist/pane/index.d.ts +4 -2
  75. package/dist/pane/index.js +4 -2
  76. package/dist/pane/usePaneKeys.js +9 -11
  77. package/dist/shell/AboutWindow.d.ts +21 -0
  78. package/dist/shell/AboutWindow.js +10 -0
  79. package/dist/shell/LanguageChoice.d.ts +27 -0
  80. package/dist/shell/LanguageChoice.js +17 -0
  81. package/dist/shell/LoadFailure.d.ts +22 -0
  82. package/dist/shell/LoadFailure.js +15 -0
  83. package/dist/shell/Lockup.d.ts +52 -0
  84. package/dist/shell/Lockup.js +30 -0
  85. package/dist/shell/SettingsDialog.d.ts +97 -0
  86. package/dist/shell/SettingsDialog.js +219 -0
  87. package/dist/shell/SettingsDialog.logic.d.ts +33 -0
  88. package/dist/shell/SettingsDialog.logic.js +42 -0
  89. package/dist/shell/SettingsFiles.d.ts +55 -0
  90. package/dist/shell/SettingsFiles.js +30 -0
  91. package/dist/shell/SettingsPageKeys.d.ts +42 -0
  92. package/dist/shell/SettingsPageKeys.js +70 -0
  93. package/dist/shell/SettingsSubsection.d.ts +34 -0
  94. package/dist/shell/SettingsSubsection.js +30 -0
  95. package/dist/shell/SignIn.d.ts +61 -0
  96. package/dist/shell/SignIn.js +36 -0
  97. package/dist/shell/ThemePicker.d.ts +74 -0
  98. package/dist/shell/ThemePicker.js +96 -0
  99. package/dist/shell/ThemePicker.logic.d.ts +13 -0
  100. package/dist/shell/ThemePicker.logic.js +26 -0
  101. package/dist/shell/TitleBar.d.ts +44 -0
  102. package/dist/shell/TitleBar.js +23 -0
  103. package/dist/shell/UpdatePill.d.ts +26 -0
  104. package/dist/shell/UpdatePill.js +17 -0
  105. package/dist/shell/Updates.d.ts +99 -0
  106. package/dist/shell/Updates.js +72 -0
  107. package/dist/shell/index.d.ts +27 -0
  108. package/dist/shell/index.js +27 -0
  109. package/dist/shell/shell.css +243 -4
  110. package/dist/styles.css +2 -0
  111. package/dist/themes/catalog.js +4 -0
  112. package/dist/themes/themes.generated.css +244 -0
  113. package/dist/themes/tokens.d.ts +17 -5
  114. package/dist/themes/tokens.js +64 -1
  115. package/dist/tokens.css +11 -0
  116. package/package.json +1 -1
@@ -4,10 +4,11 @@
4
4
  a file's problems, the update cards and their notes), the update pill's
5
5
  failed state, the release channel tag, the About window's layout, the
6
6
  sign-in prompts, and the line a part of the window shows when it fails
7
- to load. None is a component: the app writes the markup with these
8
- classes (docs/components/shell.md). The header, the brand
9
- wordmark, the app's icon, window drag regions, and the startup screens
10
- stay the app's. */
7
+ to load, and the title bar (the lockup and the brand mark, the channel
8
+ marker, the update pill's place). The components of
9
+ @bigpixelrocket/uiok/shell draw them (docs/components/shell.md); a host
10
+ may write the same markup with these classes. The app's icon, its
11
+ brand mark's glyph, and its startup screens stay the app's. */
11
12
 
12
13
  /* ---- Settings dialog ---- */
13
14
 
@@ -910,6 +911,19 @@
910
911
 
911
912
  /* ---- Channel tag ---- */
912
913
 
914
+ /* The release channel an element wears (data-channel on the app's root or
915
+ the About window): its hue and its tag's words, from the theme's
916
+ channel tokens. A release build wears none. */
917
+ [data-channel='latest'] {
918
+ --channel: var(--channel-latest);
919
+ --channel-text: var(--channel-latest-text);
920
+ }
921
+
922
+ [data-channel='local'] {
923
+ --channel: var(--channel-local);
924
+ --channel-text: var(--channel-local-text);
925
+ }
926
+
913
927
  /* The release channel beside a lockup (an About window, a splash) on a
914
928
  build that is not the release: small caps on a pill of the channel's
915
929
  colour, so a screenshot always says which build it shows. An app that
@@ -1071,3 +1085,228 @@
1071
1085
  -webkit-user-select: text;
1072
1086
  user-select: text;
1073
1087
  }
1088
+
1089
+ /* ---- Title bar ---- */
1090
+
1091
+ /* A window's title bar where the native one is hidden (TitleBar): the
1092
+ lockup and, on a build that is not the release, its channel marker,
1093
+ standing on the window ground. It paints nothing, so tabs beside it
1094
+ stand on the same ground. The whole bar is a drag region except the
1095
+ marker, so it moves the window and a double click zooms it like a native
1096
+ title bar. A bar cut narrow cuts at its end. */
1097
+ .shell-topbar {
1098
+ display: flex;
1099
+ align-items: center;
1100
+ height: 100%;
1101
+ min-width: 0;
1102
+ padding: 0 var(--space-4) 0 var(--space-6);
1103
+ box-sizing: border-box;
1104
+ overflow: hidden;
1105
+ -webkit-app-region: drag;
1106
+ }
1107
+
1108
+ .shell-brand {
1109
+ display: flex;
1110
+ align-items: center;
1111
+ gap: var(--space-4);
1112
+ min-width: 0;
1113
+ white-space: nowrap;
1114
+ }
1115
+
1116
+ /* On macOS the brand clears the traffic lights by 4px; elsewhere the
1117
+ bar's own padding stands there. */
1118
+ .shell-topbar[data-traffic-lights] .shell-brand {
1119
+ margin-left: calc(var(--traffic-light-inset) - var(--space-6));
1120
+ }
1121
+
1122
+ /* Only the channel marker shrinks; the lockup keeps its size. */
1123
+ .shell-brand > * {
1124
+ flex: none;
1125
+ }
1126
+
1127
+ .shell-lockup {
1128
+ --lockup-size: 15px;
1129
+ }
1130
+
1131
+ /* The channel marker (ChannelMarker): a dot in the channel's colour, the
1132
+ channel's name, and its build number or branch, small and quiet. It opts
1133
+ out of the drag region: a draggable region takes no pointer events, so
1134
+ its tooltip would never show. */
1135
+ .shell-brand > .shell-channel {
1136
+ display: inline-flex;
1137
+ flex: 0 1 auto;
1138
+ align-items: center;
1139
+ gap: var(--space-2);
1140
+ min-width: 0;
1141
+ margin-left: var(--space-1);
1142
+ font-size: var(--font-size-caption);
1143
+ line-height: 1;
1144
+ transform: translateY(1px);
1145
+ -webkit-app-region: no-drag;
1146
+ }
1147
+
1148
+ /* Where a channel's colour sits near 2:1 on the bar, the dot wears the
1149
+ group marks' hairline ring (--group-dot-ring). */
1150
+ .shell-channel-dot {
1151
+ flex: none;
1152
+ width: var(--dot);
1153
+ height: var(--dot);
1154
+ border-radius: var(--radius-pill);
1155
+ background: var(--channel, var(--accent));
1156
+ box-shadow: var(--group-dot-ring);
1157
+ }
1158
+
1159
+ .shell-channel-name {
1160
+ flex: none;
1161
+ color: var(--channel-name);
1162
+ font-weight: var(--font-weight-medium);
1163
+ }
1164
+
1165
+ /* The build number or the branch gives way, up to 224px. */
1166
+ .shell-channel-detail {
1167
+ flex: 0 1 auto;
1168
+ min-width: 0;
1169
+ max-width: 224px;
1170
+ overflow: hidden;
1171
+ color: var(--channel-detail);
1172
+ font-variant-numeric: tabular-nums;
1173
+ font-weight: var(--font-weight-regular);
1174
+ text-overflow: ellipsis;
1175
+ }
1176
+
1177
+ .shell-channel-modified {
1178
+ flex: none;
1179
+ color: var(--channel-detail);
1180
+ font-size: var(--font-size-caption);
1181
+ }
1182
+
1183
+ /* The band's trailing end, after the main pane's tabs: the update pill,
1184
+ out of the drag region so it takes clicks. */
1185
+ .shell-trailing {
1186
+ display: flex;
1187
+ align-items: center;
1188
+ gap: var(--space-5);
1189
+ -webkit-app-region: no-drag;
1190
+ }
1191
+
1192
+ /* ---- Lockup and brand mark ---- */
1193
+
1194
+ /* A product's lockup (Lockup): the mark beside the wordmark, its last part
1195
+ heavier. The host sizes it with --lockup-size; the mark scales with it. */
1196
+ :where(.lockup) {
1197
+ --lockup-size: 40px;
1198
+ }
1199
+
1200
+ .lockup {
1201
+ display: inline-flex;
1202
+ align-items: center;
1203
+ gap: 0.4em;
1204
+ margin: 0;
1205
+ font-size: var(--lockup-size);
1206
+ font-weight: var(--font-weight-light);
1207
+ letter-spacing: -0.02em;
1208
+ line-height: 1;
1209
+ white-space: nowrap;
1210
+ }
1211
+
1212
+ .lockup-wordmark b {
1213
+ font-weight: var(--font-weight-heavy);
1214
+ }
1215
+
1216
+ /* The mark (BrandMark) stands a little taller than the wordmark's capitals,
1217
+ so the badge's overhang does not make the plate look smaller than the
1218
+ text. The plate wears the accent and the badge the success hue; under a
1219
+ dark appearance both deepen toward the constant plate tone, so the white
1220
+ glyph and check keep their contrast on a light accent. A glyph's cuts and
1221
+ the badge's ring are drawn in the plate's and the bar's own colours. */
1222
+ .brand-mark {
1223
+ --brand-mark-plate: var(--accent);
1224
+ --brand-mark-badge: var(--success);
1225
+
1226
+ flex: none;
1227
+ width: 1.4em;
1228
+ height: 1.4em;
1229
+ }
1230
+
1231
+ @media (prefers-color-scheme: dark) {
1232
+ .brand-mark {
1233
+ --brand-mark-plate: var(--brand-plate-dark);
1234
+ --brand-mark-badge: var(--brand-badge-dark);
1235
+ }
1236
+ }
1237
+
1238
+ .brand-mark-plate {
1239
+ fill: var(--brand-mark-plate);
1240
+ }
1241
+
1242
+ .brand-mark-glyph {
1243
+ fill: var(--brand-white);
1244
+ }
1245
+
1246
+ .brand-mark-cut {
1247
+ fill: none;
1248
+ stroke: var(--brand-mark-plate);
1249
+ stroke-width: 0.9;
1250
+ }
1251
+
1252
+ .brand-mark-line {
1253
+ fill: none;
1254
+ stroke: var(--brand-white);
1255
+ stroke-linecap: round;
1256
+ stroke-linejoin: round;
1257
+ stroke-width: 1.6;
1258
+ }
1259
+
1260
+ .brand-mark-badge {
1261
+ fill: var(--brand-mark-badge);
1262
+ stroke: var(--surface-header);
1263
+ stroke-width: 1.5;
1264
+ }
1265
+
1266
+ .brand-mark-check {
1267
+ fill: none;
1268
+ stroke: var(--brand-white);
1269
+ stroke-linecap: round;
1270
+ stroke-linejoin: round;
1271
+ stroke-width: 1.4;
1272
+ }
1273
+
1274
+ /* ---- About window: the drag regions and the icon ---- */
1275
+
1276
+ /* The panel drags the window under a hidden title bar; only the version
1277
+ line takes the pointer, so it can be selected. */
1278
+ .about-window {
1279
+ -webkit-app-region: drag;
1280
+ }
1281
+
1282
+ .about-version {
1283
+ -webkit-app-region: no-drag;
1284
+ }
1285
+
1286
+ /* The round patch on a transparent canvas, its drop shadow baked in. */
1287
+ .about-icon {
1288
+ width: 128px;
1289
+ height: 128px;
1290
+ margin-bottom: var(--space-4);
1291
+ }
1292
+
1293
+ .about-lockup-text {
1294
+ --lockup-size: 21px;
1295
+ }
1296
+
1297
+ /* ---- Settings: field widths ---- */
1298
+
1299
+ /* Restore default value: dim beside a setting off its default. */
1300
+ .settings-restore {
1301
+ color: var(--text-dim);
1302
+ }
1303
+
1304
+ /* A count is a few digits wide; a count whose empty field reads as a word
1305
+ ("No limit") fits every locale's word. */
1306
+ .settings-count.field {
1307
+ width: 9ch;
1308
+ }
1309
+
1310
+ .settings-count-or-word.field {
1311
+ width: 20ch;
1312
+ }
package/dist/styles.css CHANGED
@@ -37,6 +37,8 @@
37
37
  /* The shell's shared surfaces: Settings dialog, theme picker, update card,
38
38
  channel tag, sign-in prompts, load failure (docs/components/shell.md). */
39
39
  @import './shell/shell.css';
40
+ @import './frame/frame.css';
41
+ @import './log/log.css';
40
42
 
41
43
  /* ---- What the browser would otherwise draw in its own colours ---- */
42
44
 
@@ -52,6 +52,10 @@ const CATPPUCCIN_LATTE = {
52
52
  cursor: '#dc8a78'
53
53
  },
54
54
  overrides: {
55
+ // A channel tag's words, darkened past the least step that holds 4.5:1
56
+ // on its tint, so they keep 4.5:1 on the tint over the title bar too.
57
+ '--channel-latest-text': '#6d2ebf',
58
+ '--channel-local-text': '#983c07',
55
59
  // Lavender a step stronger than the primary hue itself, so the fill
56
60
  // carries white text at 4.7:1 where the hue stops at 3.2:1.
57
61
  '--primary': '#5468e4',