@crewlethq/ui 0.85.0 → 0.86.1

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 (38) hide show
  1. package/README.md +18 -4
  2. package/dist/DataView/index.js +2 -2
  3. package/dist/InboxList/InboxList.d.ts +14 -3
  4. package/dist/InboxList/index.js +1 -1
  5. package/dist/{InboxList-X5Q5WWAI.css → InboxList-NVPIL3WU.css} +61 -28
  6. package/dist/KeyValueRows/KeyValueRows.d.ts +125 -0
  7. package/dist/KeyValueRows/index.d.ts +3 -0
  8. package/dist/KeyValueRows/index.js +12 -0
  9. package/dist/KeyValueRows-US5KW7JK.css +44 -0
  10. package/dist/ListDetail/index.js +1 -1
  11. package/dist/{ListDetail-Q7SFVKSO.css → ListDetail-WXBCLONL.css} +7 -1
  12. package/dist/RailList/RailList.d.ts +74 -0
  13. package/dist/RailList/index.d.ts +3 -0
  14. package/dist/RailList/index.js +17 -0
  15. package/dist/RailList-N2ZBPRM2.css +97 -0
  16. package/dist/RelatedRow/index.js +2 -2
  17. package/dist/SetupWizard/index.js +2 -2
  18. package/dist/ShareDialog/index.js +1 -1
  19. package/dist/TableCells/TableCells.d.ts +60 -0
  20. package/dist/TableCells/index.d.ts +2 -2
  21. package/dist/TableCells/index.js +2 -1
  22. package/dist/{TableCells-TKSNLRK3.css → TableCells-ZALZLLEF.css} +28 -0
  23. package/dist/Text/Text.d.ts +25 -3
  24. package/dist/Text/index.js +1 -1
  25. package/dist/{chunk-AFLS26AC.js → chunk-3CALM534.js} +36 -2
  26. package/dist/{chunk-EAHEJNVJ.js → chunk-CL3FWLDO.js} +1 -1
  27. package/dist/{chunk-QP2P6GDQ.js → chunk-O5CEG7TQ.js} +14 -0
  28. package/dist/{chunk-SNJM5KPV.js → chunk-P33VNG7Q.js} +1 -1
  29. package/dist/chunk-REWKR3S4.js +73 -0
  30. package/dist/chunk-TRZS7DLB.js +159 -0
  31. package/dist/{chunk-F6ZUM66S.js → chunk-VKNZQB2G.js} +44 -23
  32. package/dist/generated/index.d.ts +2 -0
  33. package/dist/generated/index.js +65 -63
  34. package/dist/index.js +65 -63
  35. package/dist/styles.css +246 -32
  36. package/package.json +3 -3
  37. package/dist/{chunk-VIX3GZCD.js → chunk-PAGITACP.js} +0 -0
  38. package/dist/{chunk-3BVNNQZY.js → chunk-WRZPO4YL.js} +1 -1
package/dist/styles.css CHANGED
@@ -22736,7 +22736,7 @@ a.crewlet-icon-btn {
22736
22736
  }
22737
22737
 
22738
22738
 
22739
- /* InboxList-X5Q5WWAI.css */
22739
+ /* InboxList-NVPIL3WU.css */
22740
22740
  /*
22741
22741
  * The inbox's column: groups of rows, each row a control with the task it is
22742
22742
  * about under it, and the quiet toggles at the end.
@@ -22962,19 +22962,36 @@ a.crewlet-icon-btn {
22962
22962
  }
22963
22963
 
22964
22964
  /*
22965
- * The avatar is centred on the head's line, the name it belongs to: its box
22966
- * is one line tall and the avatar, a target taller than the line, overflows
22967
- * it evenly into the control's top pad. Hung from the line's top by a pixel
22968
- * it stood 3.6px under the name's middle, its top a step further from the
22969
- * row's edge than its side.
22965
+ * THE LEADING SLOT FITS WHAT IT HOLDS. It is at least a target square (and at
22966
+ * least a line tall), with its mark centred in it, and it grows to a larger
22967
+ * mark, such as a 32px face, rather than letting it spill: a fixed one-line
22968
+ * box let a 32px face overflow it by 8px, up and to the left, until it all but
22969
+ * touched the row's edge.
22970
+ *
22971
+ * THE NAME'S LINE IS CENTRED ON A TARGET-SIZED MARK by moving the words down
22972
+ * rather than the mark up: the words start half the difference between the
22973
+ * target and a line lower, and the control's top pad is that much shorter, so
22974
+ * a row with a target-sized avatar keeps its height and its name where they
22975
+ * were, with the avatar inside the control instead of over its pad. A larger
22976
+ * mark hangs from the same top, beside the name's line and the one under it.
22970
22977
  */
22978
+ .crewlet-inbox-row__control--leading {
22979
+ --crewlet-inbox-row-lift: max(0px, (var(--size-target-min) - 1lh) / 2);
22980
+
22981
+ padding-top: calc(var(--spacing-2) + var(--spacing-1) / 2 - var(--crewlet-inbox-row-lift));
22982
+ }
22983
+
22984
+ .crewlet-inbox-row__control--leading > .crewlet-inbox-row__main {
22985
+ padding-top: var(--crewlet-inbox-row-lift);
22986
+ }
22987
+
22971
22988
  .crewlet-inbox-row__leading {
22972
22989
  display: inline-flex;
22973
22990
  flex: none;
22974
22991
  align-items: center;
22975
22992
  justify-content: center;
22976
- width: var(--size-target-min);
22977
- height: 1lh;
22993
+ min-width: var(--size-target-min);
22994
+ min-height: max(var(--size-target-min), 1lh);
22978
22995
  }
22979
22996
 
22980
22997
  .crewlet-inbox-row__main {
@@ -22984,24 +23001,49 @@ a.crewlet-icon-btn {
22984
23001
  min-width: 0;
22985
23002
  }
22986
23003
 
23004
+ /*
23005
+ * THE HEAD IS ONE RUN OF WORDS: who, then what they did, wrapping as words do
23006
+ * and stopping at two lines with an ellipsis. The name comes first, so it is
23007
+ * the last thing a long qualifier can push out of sight. As one line of boxes
23008
+ * the name was the only one allowed to shrink, so a qualifier longer than a
23009
+ * word ("replied to a thread in Product Manager") squeezed the name to
23010
+ * nothing and pushed the time past the row's edge.
23011
+ *
23012
+ * THE TIME FLOATS AT THE END OF THE FIRST LINE, so only that line gives up
23013
+ * room to it and the second runs the row's full width: "replied to a thread
23014
+ * in #engineering" keeps the room's name, the part of the line most worth
23015
+ * reading, where a column of its own took the time's width from both lines.
23016
+ * The float sits in a block of its own inside the clamp, which is where every
23017
+ * engine lays a float out and still counts the clamped lines.
23018
+ */
22987
23019
  .crewlet-inbox-row__head {
22988
- display: flex;
22989
- align-items: baseline;
22990
- gap: var(--spacing-1);
23020
+ display: -webkit-box;
23021
+ -webkit-box-orient: vertical;
23022
+ -webkit-line-clamp: 2;
23023
+ line-clamp: 2;
22991
23024
  min-width: 0;
23025
+ overflow: hidden;
23026
+ overflow-wrap: anywhere;
23027
+ color: var(--color-text-tertiary);
22992
23028
  }
22993
23029
 
22994
- .crewlet-inbox-row__title {
22995
- min-width: 0;
22996
- overflow: hidden;
22997
- text-overflow: ellipsis;
23030
+ .crewlet-inbox-row__head-text {
23031
+ display: block;
23032
+ }
23033
+
23034
+ /* The time (and any status), in the head's own line box, so the time sits on the name's baseline. */
23035
+ .crewlet-inbox-row__head-end {
23036
+ float: inline-end;
23037
+ margin-inline-start: var(--spacing-2);
22998
23038
  white-space: nowrap;
23039
+ }
23040
+
23041
+ .crewlet-inbox-row__title {
22999
23042
  font-weight: var(--font-weight-medium);
23000
23043
  color: var(--color-text-primary);
23001
23044
  }
23002
23045
 
23003
23046
  .crewlet-inbox-row__qualifier {
23004
- flex: none;
23005
23047
  font-size: var(--font-size-xs);
23006
23048
  color: var(--color-text-tertiary);
23007
23049
  }
@@ -23011,8 +23053,6 @@ a.crewlet-icon-btn {
23011
23053
  }
23012
23054
 
23013
23055
  .crewlet-inbox-row__meta {
23014
- flex: none;
23015
- margin-inline-start: auto;
23016
23056
  font-size: var(--font-size-xs);
23017
23057
  font-variant-numeric: tabular-nums;
23018
23058
  white-space: nowrap;
@@ -23060,21 +23100,12 @@ a.crewlet-icon-btn {
23060
23100
  color: var(--color-text-secondary);
23061
23101
  }
23062
23102
 
23103
+ /* At the end of the first line, before the time when the row has both. */
23063
23104
  .crewlet-inbox-row__status {
23064
23105
  display: inline-flex;
23065
- flex: none;
23066
23106
  align-items: center;
23067
23107
  }
23068
23108
 
23069
- /* With a status, the time stays at the end and the status sits beside it. */
23070
- .crewlet-inbox-row__status + .crewlet-inbox-row__meta {
23071
- margin-inline-start: 0;
23072
- }
23073
-
23074
- .crewlet-inbox-row__head > .crewlet-inbox-row__status {
23075
- margin-inline-start: auto;
23076
- }
23077
-
23078
23109
  /*
23079
23110
  * What came of the row: a glyph in the tone's ink, then words in the
23080
23111
  * secondary ink, on one line that wraps rather than cuts.
@@ -23130,7 +23161,9 @@ a.crewlet-icon-btn {
23130
23161
 
23131
23162
  /*
23132
23163
  * The task, under the words and lined up with them: the control's start pad,
23133
- * the leading slot and the gap after it.
23164
+ * a target-sized leading slot and the gap after it. The task sits outside the
23165
+ * control, so it lines up with the words for a mark of the target size, the
23166
+ * size `leading` asks for.
23134
23167
  */
23135
23168
  .crewlet-inbox-row__aside {
23136
23169
  min-width: 0;
@@ -24459,6 +24492,53 @@ a.crewlet-icon-btn {
24459
24492
  }
24460
24493
 
24461
24494
 
24495
+ /* KeyValueRows-US5KW7JK.css */
24496
+ /*
24497
+ * KeyValueRows: keys and their values as rows under one column head
24498
+ * (KeyValueRows.tsx).
24499
+ */
24500
+
24501
+ /* The rows, then Add under them, a row's gap apart. */
24502
+ .crewlet-key-value-rows__body,
24503
+ .crewlet-key-value-rows__table {
24504
+ display: flex;
24505
+ flex-direction: column;
24506
+ gap: var(--spacing-2);
24507
+ min-width: 0;
24508
+ }
24509
+
24510
+ /*
24511
+ * EVERY ROW STANDS ON ITS FIELDS' TOP EDGE, so a key's error grows its own
24512
+ * cell downward and nothing beside it moves. The last track is the remove
24513
+ * button's, a square the fields' height, and the head keeps it empty so the
24514
+ * value's name stands over the value column.
24515
+ */
24516
+ .crewlet-key-value-rows__head,
24517
+ .crewlet-key-value-rows__row {
24518
+ display: grid;
24519
+ grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) var(--size-control-md);
24520
+ align-items: start;
24521
+ gap: var(--spacing-2);
24522
+ }
24523
+
24524
+ /* The head stands over the first row at a field label's distance from its field. */
24525
+ .crewlet-key-value-rows__head {
24526
+ margin-block-end: calc(var(--spacing-1) - var(--spacing-2));
24527
+ }
24528
+
24529
+ .crewlet-key-value-rows__empty {
24530
+ margin: 0;
24531
+ font-size: var(--font-size-compact);
24532
+ line-height: var(--font-line-height-normal);
24533
+ color: var(--color-text-secondary);
24534
+ }
24535
+
24536
+ /* Add hugs its words, on the fields' start edge, rather than spanning the list. */
24537
+ .crewlet-key-value-rows__add {
24538
+ display: flex;
24539
+ }
24540
+
24541
+
24462
24542
  /* Layer-J222IFNX.css */
24463
24543
  /*
24464
24544
  * The portal target a LayerHost provides.
@@ -25411,7 +25491,7 @@ a.crewlet-link-card:hover .crewlet-link-card__title {
25411
25491
  }
25412
25492
 
25413
25493
 
25414
- /* ListDetail-Q7SFVKSO.css */
25494
+ /* ListDetail-WXBCLONL.css */
25415
25495
  /*
25416
25496
  * ListDetail: a list beside the detail of what is chosen in it, each scrolling
25417
25497
  * on its own in the height it is given, one pane where it is narrow
@@ -25479,6 +25559,12 @@ a.crewlet-link-card:hover .crewlet-link-card__title {
25479
25559
  min-height: 0;
25480
25560
  }
25481
25561
 
25562
+ /* A LIST THAT GROWS SCROLLS IN ITS OWN COLUMN, whatever it holds. The pane
25563
+ left the scrolling to its content, which a DirectoryList does for its
25564
+ groups and an InboxList does not: an activity list taller than the screen
25565
+ ran past the pane's end, where the screen clipped its later rows and its
25566
+ "older" link, with nothing to scroll them into view. A list that scrolls
25567
+ itself fills the pane and never makes it overflow. */
25482
25568
  .crewlet-list-detail__list {
25483
25569
  display: flex;
25484
25570
  flex-direction: column;
@@ -25486,6 +25572,7 @@ a.crewlet-link-card:hover .crewlet-link-card__title {
25486
25572
  min-height: 0;
25487
25573
  padding-right: var(--crewlet-list-detail-gutter);
25488
25574
  border-right: 1px solid var(--color-border-default);
25575
+ overflow-y: auto;
25489
25576
  }
25490
25577
 
25491
25578
  /* A DIRECTORY RUNS TO THE HAIRLINE. A DirectoryList is navigation: its lines
@@ -25520,7 +25607,6 @@ a.crewlet-link-card:hover .crewlet-link-card__title {
25520
25607
  .crewlet-list-detail__list {
25521
25608
  padding-right: 0;
25522
25609
  border-right: 0;
25523
- overflow-y: auto;
25524
25610
  }
25525
25611
 
25526
25612
  /* The list is the pane that scrolls now, and takes the detail's end where
@@ -31730,6 +31816,106 @@ button.crewlet-presence-stack__member:focus-visible {
31730
31816
  }
31731
31817
 
31732
31818
 
31819
+ /* RailList-N2ZBPRM2.css */
31820
+ /*
31821
+ * RailList: a directory in a card, a rail of groups beside the chosen
31822
+ * group's list, folding into a picker where the card is narrow
31823
+ * (RailList.tsx).
31824
+ *
31825
+ * SIZED BY ITS OWN WIDTH, NOT THE WINDOW'S, because the same directory stands
31826
+ * in a page and in a sheet: the root is an inline-size container, and under
31827
+ * the rail's room (44rem) the rail goes and the picker shows. Both are always
31828
+ * rendered and the stylesheet decides, so the fold costs no measurement and
31829
+ * never draws the wrong one first.
31830
+ */
31831
+ .crewlet-rail-list {
31832
+ container: crewlet-rail-list / inline-size;
31833
+ min-width: 0;
31834
+ }
31835
+
31836
+ /* The bar across the card's top: the caller's search and chips, and the folded picker. */
31837
+ .crewlet-rail-list__bar {
31838
+ display: flex;
31839
+ flex-wrap: wrap;
31840
+ align-items: center;
31841
+ gap: var(--spacing-2);
31842
+ padding: var(--spacing-3);
31843
+ border-block-end: 1px solid var(--color-border-default);
31844
+ }
31845
+
31846
+ /* Wide, the rail is the choice: the picker and a bar that holds nothing else are not drawn. */
31847
+ .crewlet-rail-list__picker,
31848
+ .crewlet-rail-list__bar--picker-only {
31849
+ display: none;
31850
+ }
31851
+
31852
+ /* The rail at a fixed width (13rem by default), the list taking the rest. */
31853
+ .crewlet-rail-list__body {
31854
+ display: grid;
31855
+ grid-template-columns: var(--crewlet-rail-list-rail, 13rem) minmax(0, 1fr);
31856
+ min-width: 0;
31857
+ }
31858
+
31859
+ /* The rail on a hairline of its own, its note a step under its rows. */
31860
+ .crewlet-rail-list__rail {
31861
+ display: flex;
31862
+ flex-direction: column;
31863
+ gap: var(--spacing-3);
31864
+ min-width: 0;
31865
+ padding: var(--spacing-2);
31866
+ border-inline-end: 1px solid var(--color-border-default);
31867
+ }
31868
+
31869
+ /* The note starts on the rows' words, inside the dense rail's own inset. */
31870
+ .crewlet-rail-list__note {
31871
+ margin: 0;
31872
+ padding-inline: var(--spacing-2);
31873
+ }
31874
+
31875
+ .crewlet-rail-list__list {
31876
+ display: flex;
31877
+ flex-direction: column;
31878
+ min-width: 0;
31879
+ }
31880
+
31881
+ /* What the chosen group holds, over its list on a hairline, at the list's own inset. */
31882
+ .crewlet-rail-list__about {
31883
+ margin: 0;
31884
+ padding: var(--spacing-2) var(--spacing-4);
31885
+ border-block-end: 1px solid var(--color-border-default);
31886
+ }
31887
+
31888
+ /*
31889
+ * A GRID AT THE LIST'S TOP TAKES NO RULE OF ITS OWN. A grid in a card draws
31890
+ * one rule above its head to part it from the card's head (DataGrid.css);
31891
+ * here the bar's hairline, the description's or the card's own edge is
31892
+ * already that rule, and the grid's drew a second line under it.
31893
+ */
31894
+ .crewlet-rail-list__list > .crewlet-data-grid:first-child,
31895
+ .crewlet-rail-list__about + .crewlet-data-grid {
31896
+ border-top: 0;
31897
+ }
31898
+
31899
+ /* Under the rail's room the list takes the card, and the picker takes the rail's place in the bar. */
31900
+ @container crewlet-rail-list (width < 44rem) {
31901
+ .crewlet-rail-list__body {
31902
+ grid-template-columns: minmax(0, 1fr);
31903
+ }
31904
+
31905
+ .crewlet-rail-list__rail {
31906
+ display: none;
31907
+ }
31908
+
31909
+ .crewlet-rail-list__picker {
31910
+ display: inline-flex;
31911
+ }
31912
+
31913
+ .crewlet-rail-list__bar--picker-only {
31914
+ display: flex;
31915
+ }
31916
+ }
31917
+
31918
+
31733
31919
  /* ReactionBar-XXI4V7XG.css */
31734
31920
  /*
31735
31921
  * A message's reactions: one pill to an emoji, then the add pill. A pill at
@@ -41233,7 +41419,7 @@ b.crewlet-switcher__match {
41233
41419
  }
41234
41420
 
41235
41421
 
41236
- /* TableCells-TKSNLRK3.css */
41422
+ /* TableCells-ZALZLLEF.css */
41237
41423
  /* The read-only table cells. Each one holds a single line and shrinks inside
41238
41424
  its column (`min-width: 0`), so a long value is cut with an ellipsis and
41239
41425
  its whole text on the title rather than standing the row two lines tall. */
@@ -41349,6 +41535,34 @@ b.crewlet-switcher__match {
41349
41535
  font-variant-numeric: tabular-nums;
41350
41536
  }
41351
41537
 
41538
+ /*
41539
+ * A VALUE OVER A QUIETER LINE (TableTwoLineCell), each line its own block cut
41540
+ * on one line. A column of boxes rather than two runs of text, so neither
41541
+ * line takes the line box of the words around it, and the cell is exactly
41542
+ * the two lines tall. `min-width: 0` lets the column shrink inside a grid's
41543
+ * cell, which is what cuts the lines rather than pushing the column wider.
41544
+ */
41545
+ .crewlet-table-cell__lines {
41546
+ display: flex;
41547
+ flex-direction: column;
41548
+ min-width: 0;
41549
+ max-width: 100%;
41550
+ }
41551
+
41552
+ /* The mark is centred against both lines, as an entity's badge is against its name. */
41553
+ .crewlet-table-cell__two-line {
41554
+ display: inline-flex;
41555
+ align-items: center;
41556
+ gap: var(--spacing-2);
41557
+ min-width: 0;
41558
+ max-width: 100%;
41559
+ }
41560
+
41561
+ /* The mark keeps its size: the lines give way to the column, never the mark. */
41562
+ .crewlet-table-cell__two-line > :first-child {
41563
+ flex: none;
41564
+ }
41565
+
41352
41566
 
41353
41567
  /* Tabs-M2ELSU3V.css */
41354
41568
  /*
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@crewlethq/ui",
3
- "version": "0.85.0",
3
+ "version": "0.86.1",
4
4
  "description": "Crewlet shared React components built on @crewlethq/tokens and @crewlethq/icons.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -42,8 +42,8 @@
42
42
  "clean": "rm -rf dist src/generated"
43
43
  },
44
44
  "dependencies": {
45
- "@crewlethq/icons": "0.85.0",
46
- "@crewlethq/tokens": "0.85.0",
45
+ "@crewlethq/icons": "0.86.1",
46
+ "@crewlethq/tokens": "0.86.1",
47
47
  "prosemirror-commands": "1.7.2",
48
48
  "prosemirror-gapcursor": "1.4.1",
49
49
  "prosemirror-history": "1.5.1",
File without changes
@@ -1,5 +1,5 @@
1
- import { PageHeader } from './chunk-FPDIHEM4.js';
2
1
  import { Stepper } from './chunk-TMML7BHT.js';
2
+ import { PageHeader } from './chunk-FPDIHEM4.js';
3
3
  import { useMediaMatch } from './chunk-YJQXESOJ.js';
4
4
  import { Disclosure } from './chunk-NAHA62WD.js';
5
5
  import { useHeadingLevel, nextHeadingLevel, headingTag, HeadingLevelProvider } from './chunk-PQADV6P6.js';