archidocs 1.3.2 → 1.3.3-beta.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.
@@ -39,10 +39,13 @@ export declare const SEQUENCE: {
39
39
  readonly nameSize: 13;
40
40
  readonly labelSize: 12;
41
41
  readonly subSize: 11;
42
- /** Room in a header beside its name: the Team stripe, code and padding. */
43
- readonly headerPad: 64;
42
+ /**
43
+ * Room in a header beside its name: the border, padding, the gaps either
44
+ * side of the name, and the widest Team code tile (three capitals). Headers
45
+ * have no maximum width, so a name is never cut.
46
+ */
47
+ readonly headerPad: 88;
44
48
  readonly minColumn: 116;
45
- readonly maxColumn: 200;
46
49
  readonly margin: 24;
47
50
  };
48
51
  export interface SequenceColumn {
@@ -17,10 +17,13 @@ export const SEQUENCE = {
17
17
  nameSize: 13,
18
18
  labelSize: 12,
19
19
  subSize: 11,
20
- /** Room in a header beside its name: the Team stripe, code and padding. */
21
- headerPad: 64,
20
+ /**
21
+ * Room in a header beside its name: the border, padding, the gaps either
22
+ * side of the name, and the widest Team code tile (three capitals). Headers
23
+ * have no maximum width, so a name is never cut.
24
+ */
25
+ headerPad: 88,
22
26
  minColumn: 116,
23
- maxColumn: 200,
24
27
  margin: 24,
25
28
  };
26
29
  /**
@@ -72,7 +75,7 @@ export function layoutSequence(view, options) {
72
75
  const messages = sequenceMessages(view, options);
73
76
  const ids = sequenceParticipants(view, options);
74
77
  const index = new Map(ids.map((id, i) => [id, i]));
75
- const widths = ids.map((id) => Math.min(S.maxColumn, Math.max(S.minColumn, textWidth(options.name(id), S.nameSize, 700) + S.headerPad)));
78
+ const widths = ids.map((id) => Math.max(S.minColumn, textWidth(options.name(id), S.nameSize, 700) + S.headerPad));
76
79
  const labelWidths = messages.map((m) => {
77
80
  const via = viaLine(m, options.name);
78
81
  return Math.max(textWidth(m.label, S.labelSize), via ? textWidth(via, S.subSize) : 0, m.note ? textWidth(m.note, S.subSize) : 0);