react-cheminfo 0.58.0 → 0.60.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 (149) hide show
  1. package/README.md +7 -2
  2. package/lib/about/ui/AboutBuildDetails.d.ts +15 -0
  3. package/lib/about/ui/AboutBuildDetails.d.ts.map +1 -0
  4. package/lib/about/ui/AboutBuildDetails.js +17 -0
  5. package/lib/about/ui/AboutBuildDetails.js.map +1 -0
  6. package/lib/about/ui/AboutPage.d.ts +8 -0
  7. package/lib/about/ui/AboutPage.d.ts.map +1 -1
  8. package/lib/about/ui/AboutPage.js +12 -3
  9. package/lib/about/ui/AboutPage.js.map +1 -1
  10. package/lib/about/ui/AboutSignIn.d.ts +33 -0
  11. package/lib/about/ui/AboutSignIn.d.ts.map +1 -0
  12. package/lib/about/ui/AboutSignIn.js +28 -0
  13. package/lib/about/ui/AboutSignIn.js.map +1 -0
  14. package/lib/about/ui/AboutVersion.d.ts +4 -2
  15. package/lib/about/ui/AboutVersion.d.ts.map +1 -1
  16. package/lib/about/ui/AboutVersion.js +21 -3
  17. package/lib/about/ui/AboutVersion.js.map +1 -1
  18. package/lib/about/ui/index.d.ts +2 -2
  19. package/lib/about/ui/index.d.ts.map +1 -1
  20. package/lib/about/ui/index.js +1 -1
  21. package/lib/about/ui/index.js.map +1 -1
  22. package/lib/chart/ui/ChartTrackingLayer.js +3 -1
  23. package/lib/chart/ui/ChartTrackingLayer.js.map +1 -1
  24. package/lib/chart/ui/useChartSize.d.ts +16 -0
  25. package/lib/chart/ui/useChartSize.d.ts.map +1 -1
  26. package/lib/chart/ui/useChartSize.js +34 -1
  27. package/lib/chart/ui/useChartSize.js.map +1 -1
  28. package/lib/chrome/ui/NavEntry.d.ts +16 -0
  29. package/lib/chrome/ui/NavEntry.d.ts.map +1 -0
  30. package/lib/chrome/ui/NavEntry.js +27 -0
  31. package/lib/chrome/ui/NavEntry.js.map +1 -0
  32. package/lib/chrome/ui/SiteHeader.d.ts +11 -4
  33. package/lib/chrome/ui/SiteHeader.d.ts.map +1 -1
  34. package/lib/chrome/ui/SiteHeader.js +4 -26
  35. package/lib/chrome/ui/SiteHeader.js.map +1 -1
  36. package/lib/core.d.ts +2 -0
  37. package/lib/core.d.ts.map +1 -1
  38. package/lib/core.js +2 -0
  39. package/lib/core.js.map +1 -1
  40. package/lib/ecosystem/core/types.d.ts +1 -1
  41. package/lib/ecosystem/core/types.d.ts.map +1 -1
  42. package/lib/ecosystem/core/unlistedSites.d.ts.map +1 -1
  43. package/lib/ecosystem/core/unlistedSites.js +14 -0
  44. package/lib/ecosystem/core/unlistedSites.js.map +1 -1
  45. package/lib/ecosystem/ui/glyphs.d.ts.map +1 -1
  46. package/lib/ecosystem/ui/glyphs.js +3 -0
  47. package/lib/ecosystem/ui/glyphs.js.map +1 -1
  48. package/lib/i18n/core/chromeCatalog.d.ts +1 -1
  49. package/lib/i18n/core/chromeCatalog.d.ts.map +1 -1
  50. package/lib/locales/de.json +36 -3
  51. package/lib/locales/en.json +36 -3
  52. package/lib/locales/es.json +36 -3
  53. package/lib/locales/fr.json +36 -3
  54. package/lib/locales/it.json +36 -3
  55. package/lib/moleculesSources/core/index.d.ts +3 -0
  56. package/lib/moleculesSources/core/index.d.ts.map +1 -0
  57. package/lib/moleculesSources/core/index.js +2 -0
  58. package/lib/moleculesSources/core/index.js.map +1 -0
  59. package/lib/moleculesSources/core/moleculesSources.d.ts +55 -0
  60. package/lib/moleculesSources/core/moleculesSources.d.ts.map +1 -0
  61. package/lib/moleculesSources/core/moleculesSources.js +63 -0
  62. package/lib/moleculesSources/core/moleculesSources.js.map +1 -0
  63. package/lib/moleculesSources/ui/MoleculesSourceBadge.d.ts +18 -0
  64. package/lib/moleculesSources/ui/MoleculesSourceBadge.d.ts.map +1 -0
  65. package/lib/moleculesSources/ui/MoleculesSourceBadge.js +22 -0
  66. package/lib/moleculesSources/ui/MoleculesSourceBadge.js.map +1 -0
  67. package/lib/moleculesSources/ui/SourceBadge.d.ts +57 -0
  68. package/lib/moleculesSources/ui/SourceBadge.d.ts.map +1 -0
  69. package/lib/moleculesSources/ui/SourceBadge.js +29 -0
  70. package/lib/moleculesSources/ui/SourceBadge.js.map +1 -0
  71. package/lib/moleculesSources/ui/index.d.ts +7 -0
  72. package/lib/moleculesSources/ui/index.d.ts.map +1 -0
  73. package/lib/moleculesSources/ui/index.js +4 -0
  74. package/lib/moleculesSources/ui/index.js.map +1 -0
  75. package/lib/moleculesSources/ui/useSourceLooks.d.ts +24 -0
  76. package/lib/moleculesSources/ui/useSourceLooks.d.ts.map +1 -0
  77. package/lib/moleculesSources/ui/useSourceLooks.js +53 -0
  78. package/lib/moleculesSources/ui/useSourceLooks.js.map +1 -0
  79. package/lib/moleculesToken/core/index.d.ts +4 -0
  80. package/lib/moleculesToken/core/index.d.ts.map +1 -0
  81. package/lib/moleculesToken/core/index.js +3 -0
  82. package/lib/moleculesToken/core/index.js.map +1 -0
  83. package/lib/moleculesToken/core/moleculesToken.d.ts +101 -0
  84. package/lib/moleculesToken/core/moleculesToken.d.ts.map +1 -0
  85. package/lib/moleculesToken/core/moleculesToken.js +137 -0
  86. package/lib/moleculesToken/core/moleculesToken.js.map +1 -0
  87. package/lib/moleculesToken/core/tokenFix.d.ts +18 -0
  88. package/lib/moleculesToken/core/tokenFix.d.ts.map +1 -0
  89. package/lib/moleculesToken/core/tokenFix.js +27 -0
  90. package/lib/moleculesToken/core/tokenFix.js.map +1 -0
  91. package/lib/moleculesToken/ui/MoleculesTokenFix.d.ts +22 -0
  92. package/lib/moleculesToken/ui/MoleculesTokenFix.d.ts.map +1 -0
  93. package/lib/moleculesToken/ui/MoleculesTokenFix.js +35 -0
  94. package/lib/moleculesToken/ui/MoleculesTokenFix.js.map +1 -0
  95. package/lib/moleculesToken/ui/MoleculesTokenTable.d.ts +37 -0
  96. package/lib/moleculesToken/ui/MoleculesTokenTable.d.ts.map +1 -0
  97. package/lib/moleculesToken/ui/MoleculesTokenTable.js +56 -0
  98. package/lib/moleculesToken/ui/MoleculesTokenTable.js.map +1 -0
  99. package/lib/moleculesToken/ui/index.d.ts +5 -0
  100. package/lib/moleculesToken/ui/index.d.ts.map +1 -0
  101. package/lib/moleculesToken/ui/index.js +3 -0
  102. package/lib/moleculesToken/ui/index.js.map +1 -0
  103. package/lib/moleculesToken/ui/tokenDetails.d.ts +13 -0
  104. package/lib/moleculesToken/ui/tokenDetails.d.ts.map +1 -0
  105. package/lib/moleculesToken/ui/tokenDetails.js +73 -0
  106. package/lib/moleculesToken/ui/tokenDetails.js.map +1 -0
  107. package/lib/ui.d.ts +2 -0
  108. package/lib/ui.d.ts.map +1 -1
  109. package/lib/ui.js +2 -0
  110. package/lib/ui.js.map +1 -1
  111. package/package.json +1 -1
  112. package/src/about/ui/AboutBuildDetails.tsx +45 -0
  113. package/src/about/ui/AboutPage.tsx +27 -13
  114. package/src/about/ui/AboutSignIn.tsx +63 -0
  115. package/src/about/ui/AboutVersion.tsx +27 -9
  116. package/src/about/ui/index.ts +2 -2
  117. package/src/chart/ui/ChartTrackingLayer.tsx +3 -1
  118. package/src/chart/ui/useChartSize.ts +44 -1
  119. package/src/chrome/ui/NavEntry.tsx +41 -0
  120. package/src/chrome/ui/SiteHeader.tsx +15 -41
  121. package/src/core.ts +2 -0
  122. package/src/ecosystem/core/types.ts +2 -1
  123. package/src/ecosystem/core/unlistedSites.ts +14 -0
  124. package/src/ecosystem/ui/glyphs.tsx +10 -0
  125. package/src/locales/de.json +36 -3
  126. package/src/locales/en.json +36 -3
  127. package/src/locales/es.json +36 -3
  128. package/src/locales/fr.json +36 -3
  129. package/src/locales/it.json +36 -3
  130. package/src/moleculesSources/core/index.ts +11 -0
  131. package/src/moleculesSources/core/moleculesSources.ts +102 -0
  132. package/src/moleculesSources/ui/MoleculesSourceBadge.tsx +44 -0
  133. package/src/moleculesSources/ui/SourceBadge.tsx +117 -0
  134. package/src/moleculesSources/ui/index.ts +6 -0
  135. package/src/moleculesSources/ui/useSourceLooks.ts +70 -0
  136. package/src/moleculesToken/core/index.ts +12 -0
  137. package/src/moleculesToken/core/moleculesToken.ts +256 -0
  138. package/src/moleculesToken/core/tokenFix.ts +37 -0
  139. package/src/moleculesToken/ui/MoleculesTokenFix.tsx +95 -0
  140. package/src/moleculesToken/ui/MoleculesTokenTable.tsx +175 -0
  141. package/src/moleculesToken/ui/index.ts +4 -0
  142. package/src/moleculesToken/ui/tokenDetails.tsx +91 -0
  143. package/src/ui.ts +2 -0
  144. package/styles/chrome.css +194 -0
  145. package/lib/about/ui/AboutBuild.d.ts +0 -18
  146. package/lib/about/ui/AboutBuild.d.ts.map +0 -1
  147. package/lib/about/ui/AboutBuild.js +0 -37
  148. package/lib/about/ui/AboutBuild.js.map +0 -1
  149. package/src/about/ui/AboutBuild.tsx +0 -54
package/styles/chrome.css CHANGED
@@ -354,6 +354,144 @@ button {
354
354
  font-size: 0.75rem;
355
355
  }
356
356
 
357
+ /* ── Where a molecule comes from ─────────────────────────────────────────── */
358
+
359
+ /* A source's own colour, softened: a pale tint behind the name and the hue
360
+ darkened for the text, so a row of badges stays calm whatever colours the
361
+ sources chose. The colour is set inline from what molecules publishes. */
362
+ .source-badge {
363
+ --source: var(--brand);
364
+
365
+ display: inline-flex;
366
+ align-items: baseline;
367
+ padding: calc(0.1rem - 1px) calc(0.55rem - 1px);
368
+ border: 1px solid color-mix(in oklab, var(--source) 28%, white);
369
+ border-radius: 999px;
370
+ background: color-mix(in oklab, var(--source) 12%, white);
371
+ color: color-mix(in oklab, var(--source) 55%, var(--text));
372
+ /* Never lighter than an ink, so a pale colour a source chose stays readable. */
373
+ color: oklch(from var(--source) min(l, 0.45) c h);
374
+ font-size: 0.8125rem;
375
+ font-weight: 600;
376
+ gap: 0.35rem;
377
+ line-height: 1.5;
378
+ text-decoration: none;
379
+ white-space: nowrap;
380
+ }
381
+
382
+ /* A source with no look of its own. */
383
+ .source-badge--neutral {
384
+ --source: var(--text-muted);
385
+ }
386
+
387
+ a.source-badge:hover {
388
+ background: color-mix(in oklab, var(--source) 20%, white);
389
+ text-decoration: none;
390
+ }
391
+
392
+ /* The logo sits on a white chip of its own, so it reads on any badge colour. */
393
+ .source-badge__logo {
394
+ display: inline-flex;
395
+ width: 1.1rem;
396
+ height: 1.1rem;
397
+ flex: none;
398
+ align-items: center;
399
+ justify-content: center;
400
+ align-self: center;
401
+ border-radius: 50%;
402
+ margin-left: -0.35rem;
403
+ background: var(--surface);
404
+ }
405
+
406
+ .source-badge__logo img {
407
+ display: block;
408
+ max-width: 0.8rem;
409
+ max-height: 0.8rem;
410
+ }
411
+
412
+ .source-badge__id {
413
+ font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
414
+ font-weight: 500;
415
+ opacity: 0.9;
416
+ }
417
+
418
+ .source-badge__count {
419
+ font-weight: 500;
420
+ opacity: 0.75;
421
+ }
422
+
423
+ .source-badge--compact {
424
+ padding: 0 calc(0.45rem - 1px);
425
+ font-size: 0.6875rem;
426
+ }
427
+
428
+ .source-badge--compact .source-badge__logo {
429
+ width: 0.95rem;
430
+ height: 0.95rem;
431
+ margin-left: -0.3rem;
432
+ }
433
+
434
+ .source-badge--compact .source-badge__logo img {
435
+ max-width: 0.7rem;
436
+ max-height: 0.7rem;
437
+ }
438
+
439
+ /* What a release's badge leaves to its hover: a header, then the commit and the
440
+ instant as a label/value grid. The values are what a report quotes, so they
441
+ never wrap and their digits line up. */
442
+ .build-tooltip .bp6-popover-content {
443
+ width: auto;
444
+ padding: 6px 10px;
445
+ font-size: 12px;
446
+ line-height: 1.4;
447
+ white-space: nowrap;
448
+ }
449
+
450
+ .build-tooltip__header {
451
+ padding-bottom: 4px;
452
+ border-bottom: 1px solid var(--border);
453
+ margin-bottom: 4px;
454
+ font-size: 13px;
455
+ font-weight: 700;
456
+ }
457
+
458
+ .build-tooltip__rows {
459
+ display: grid;
460
+ margin: 0;
461
+ column-gap: 16px;
462
+ grid-template-columns: auto auto;
463
+ }
464
+
465
+ .build-tooltip__rows dt {
466
+ color: var(--text-muted);
467
+ }
468
+
469
+ .build-tooltip__rows dd {
470
+ margin: 0;
471
+ font-variant-numeric: tabular-nums;
472
+ font-weight: 600;
473
+ text-align: right;
474
+ }
475
+
476
+ /* Signing in starts on the About, under the build badge: quiet at rest, in the
477
+ type of the badge beside it, and a link only to whoever looks for one. */
478
+ .about-sign-in {
479
+ padding: 0;
480
+ border: 0;
481
+ background: none;
482
+ color: var(--text-muted);
483
+ cursor: pointer;
484
+ font-family: inherit;
485
+ font-size: 13px;
486
+ text-decoration: none;
487
+ }
488
+
489
+ .about-sign-in:hover,
490
+ .about-sign-in:focus-visible {
491
+ color: var(--accent);
492
+ text-decoration: underline;
493
+ }
494
+
357
495
  /* The share dialog: the ready-made links above, the options and the page they
358
496
  write side by side, and the three things one does with the link in the
359
497
  footer, never scrolled away. */
@@ -737,6 +875,62 @@ button {
737
875
  }
738
876
  }
739
877
 
878
+ /* ── Tokens for molecules.cheminfo.org ─────────────────────────────────────── */
879
+
880
+ /* The heading, when the tokens were checked, and the button asking again, on
881
+ one line that wraps on a phone. */
882
+ .molecules-tokens__head {
883
+ display: flex;
884
+ flex-wrap: wrap;
885
+ align-items: center;
886
+ margin-bottom: 0.4rem;
887
+ gap: 0.25rem 0.75rem;
888
+ }
889
+
890
+ .molecules-tokens__title {
891
+ font-weight: 600;
892
+ }
893
+
894
+ .molecules-tokens__muted {
895
+ color: var(--text-muted);
896
+ font-size: 0.8125rem;
897
+ }
898
+
899
+ /* A phone scrolls the table within its box, never the page sideways. */
900
+ .molecules-tokens__scroll {
901
+ overflow-x: auto;
902
+ }
903
+
904
+ .molecules-tokens__table {
905
+ width: 100%;
906
+ }
907
+
908
+ /* A variable name breaks nowhere: it is copied into a .env as it reads. */
909
+ .molecules-tokens__table code {
910
+ white-space: nowrap;
911
+ }
912
+
913
+ .molecules-tokens__fix {
914
+ margin-bottom: 0.75rem;
915
+ }
916
+
917
+ .molecules-tokens__fix ol {
918
+ padding-left: 1.25rem;
919
+ margin: 0.25rem 0 0;
920
+ }
921
+
922
+ .molecules-tokens__fix li + li {
923
+ margin-top: 0.6rem;
924
+ }
925
+
926
+ .molecules-tokens__fix p {
927
+ margin: 0 0 0.25rem;
928
+ }
929
+
930
+ .molecules-tokens__fix p + p {
931
+ margin-top: 0.4rem;
932
+ }
933
+
740
934
  /* ── A narrow bar ────────────────────────────────────────────────────────── */
741
935
 
742
936
  /* The menu the pages fold into, drawn only once they no longer fit. */
@@ -1,18 +0,0 @@
1
- import type { ReactElement } from 'react';
2
- import type { BuildInfo } from '../../build/core/buildInfo.ts';
3
- export interface AboutBuildProps {
4
- /** What the build published about itself. */
5
- build: BuildInfo;
6
- }
7
- /**
8
- * The one line that says when the build a visitor has open was made.
9
- *
10
- * A report of something going wrong is worth answering only when we know what
11
- * was running. The version itself is in the hero, where a reader is asked to
12
- * quote it from; this line carries the rest, so a report can name the exact
13
- * build the problem was seen on.
14
- * @param props - See {@link AboutBuildProps}.
15
- * @returns The line.
16
- */
17
- export declare function AboutBuild(props: AboutBuildProps): ReactElement;
18
- //# sourceMappingURL=AboutBuild.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AboutBuild.d.ts","sourceRoot":"","sources":["../../../src/about/ui/AboutBuild.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiB,YAAY,EAAE,MAAM,OAAO,CAAC;AAEzD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAC;AAI/D,MAAM,WAAW,eAAe;IAC9B,6CAA6C;IAC7C,KAAK,EAAE,SAAS,CAAC;CAClB;AAED;;;;;;;;;GASG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,eAAe,GAAG,YAAY,CAqB/D"}
@@ -1,37 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { formatBuiltAt, shortCommit } from "../../build/core/buildInfo.js";
3
- import { useChromeT } from "../../i18n/ui/useT.js";
4
- /**
5
- * The one line that says when the build a visitor has open was made.
6
- *
7
- * A report of something going wrong is worth answering only when we know what
8
- * was running. The version itself is in the hero, where a reader is asked to
9
- * quote it from; this line carries the rest, so a report can name the exact
10
- * build the problem was seen on.
11
- * @param props - See {@link AboutBuildProps}.
12
- * @returns The line.
13
- */
14
- export function AboutBuild(props) {
15
- const { build } = props;
16
- const t = useChromeT();
17
- const builtAt = formatBuiltAt(build.builtAt);
18
- if (build.commit === undefined) {
19
- return _jsx("p", { style: PARAGRAPH_STYLE, children: t('about.built', { builtAt }) });
20
- }
21
- // The commit sits inside a sentence whose word order is the translator's,
22
- // so the message names where it goes and is split there.
23
- const [before = '', after = ''] = t('about.builtFromCommit', {
24
- builtAt,
25
- }).split('{commit}');
26
- return (_jsxs("p", { style: PARAGRAPH_STYLE, children: [before, _jsx("code", { style: CODE_STYLE, children: shortCommit(build.commit) }), after] }));
27
- }
28
- const PARAGRAPH_STYLE = {
29
- margin: 0,
30
- color: 'var(--text-muted)',
31
- fontSize: 13,
32
- };
33
- const CODE_STYLE = {
34
- fontFamily: 'var(--font-mono, ui-monospace, monospace)',
35
- fontSize: 13,
36
- };
37
- //# sourceMappingURL=AboutBuild.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AboutBuild.js","sourceRoot":"","sources":["../../../src/about/ui/AboutBuild.tsx"],"names":[],"mappings":";AAGA,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AAC3E,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAOnD;;;;;;;;;GASG;AACH,MAAM,UAAU,UAAU,CAAC,KAAsB;IAC/C,MAAM,EAAE,KAAK,EAAE,GAAG,KAAK,CAAC;IACxB,MAAM,CAAC,GAAG,UAAU,EAAE,CAAC;IACvB,MAAM,OAAO,GAAG,aAAa,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IAC7C,IAAI,KAAK,CAAC,MAAM,KAAK,SAAS,EAAE,CAAC;QAC/B,OAAO,YAAG,KAAK,EAAE,eAAe,YAAG,CAAC,CAAC,aAAa,EAAE,EAAE,OAAO,EAAE,CAAC,GAAK,CAAC;IACxE,CAAC;IAED,0EAA0E;IAC1E,yDAAyD;IACzD,MAAM,CAAC,MAAM,GAAG,EAAE,EAAE,KAAK,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,uBAAuB,EAAE;QAC3D,OAAO;KACR,CAAC,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC;IAErB,OAAO,CACL,aAAG,KAAK,EAAE,eAAe,aACtB,MAAM,EACP,eAAM,KAAK,EAAE,UAAU,YAAG,WAAW,CAAC,KAAK,CAAC,MAAM,CAAC,GAAQ,EAC1D,KAAK,IACJ,CACL,CAAC;AACJ,CAAC;AAED,MAAM,eAAe,GAAG;IACtB,MAAM,EAAE,CAAC;IACT,KAAK,EAAE,mBAAmB;IAC1B,QAAQ,EAAE,EAAE;CACoB,CAAC;AAEnC,MAAM,UAAU,GAAG;IACjB,UAAU,EAAE,2CAA2C;IACvD,QAAQ,EAAE,EAAE;CACoB,CAAC"}
@@ -1,54 +0,0 @@
1
- import type { CSSProperties, ReactElement } from 'react';
2
-
3
- import type { BuildInfo } from '../../build/core/buildInfo.ts';
4
- import { formatBuiltAt, shortCommit } from '../../build/core/buildInfo.ts';
5
- import { useChromeT } from '../../i18n/ui/useT.ts';
6
-
7
- export interface AboutBuildProps {
8
- /** What the build published about itself. */
9
- build: BuildInfo;
10
- }
11
-
12
- /**
13
- * The one line that says when the build a visitor has open was made.
14
- *
15
- * A report of something going wrong is worth answering only when we know what
16
- * was running. The version itself is in the hero, where a reader is asked to
17
- * quote it from; this line carries the rest, so a report can name the exact
18
- * build the problem was seen on.
19
- * @param props - See {@link AboutBuildProps}.
20
- * @returns The line.
21
- */
22
- export function AboutBuild(props: AboutBuildProps): ReactElement {
23
- const { build } = props;
24
- const t = useChromeT();
25
- const builtAt = formatBuiltAt(build.builtAt);
26
- if (build.commit === undefined) {
27
- return <p style={PARAGRAPH_STYLE}>{t('about.built', { builtAt })}</p>;
28
- }
29
-
30
- // The commit sits inside a sentence whose word order is the translator's,
31
- // so the message names where it goes and is split there.
32
- const [before = '', after = ''] = t('about.builtFromCommit', {
33
- builtAt,
34
- }).split('{commit}');
35
-
36
- return (
37
- <p style={PARAGRAPH_STYLE}>
38
- {before}
39
- <code style={CODE_STYLE}>{shortCommit(build.commit)}</code>
40
- {after}
41
- </p>
42
- );
43
- }
44
-
45
- const PARAGRAPH_STYLE = {
46
- margin: 0,
47
- color: 'var(--text-muted)',
48
- fontSize: 13,
49
- } as const satisfies CSSProperties;
50
-
51
- const CODE_STYLE = {
52
- fontFamily: 'var(--font-mono, ui-monospace, monospace)',
53
- fontSize: 13,
54
- } as const satisfies CSSProperties;