@ethlete/components 1.0.0-next.116 → 1.0.0-next.118

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/CHANGELOG.md CHANGED
@@ -1,5 +1,25 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.0.0-next.118
4
+
5
+ ### Minor Changes
6
+
7
+ - `et-bracket-skeleton` can now draw a Swiss stage with a placeholder header for each record group.
8
+ - Add `et-scrollable-placeholder` for static skeleton tracks and document its use in the CDK migration map.
9
+
10
+ ### Patch Changes
11
+
12
+ - The `et-italic` icon draws its glyph as a path, so it looks the same on every system instead of using the system serif font.
13
+ - A left or right sheet that fills the viewport width now has square corners instead of rounded ones.
14
+
15
+ ## 1.0.0-next.117
16
+
17
+ ### Patch Changes
18
+
19
+ - An iOS edge swipe back out of a query-param overlay now goes back one history entry instead of two.
20
+ - An overlay router shows the destination route at once when the browser already animated a Back or Forward gesture between two of its routes, so Safari no longer flashes a frame of the old route.
21
+ - An open accordion or collapse inside a parent with `visibility: hidden` stays hidden instead of showing through.
22
+
3
23
  ## 1.0.0-next.116
4
24
 
5
25
  ### Patch Changes
@@ -6,12 +6,6 @@
6
6
  color: var(--et-surface-text);
7
7
  }
8
8
 
9
- @layer components {
10
- .et-badge:where([data-variant='filled'], [data-variant='tonal']) {
11
- --_et-badge-border-color: var(--et-tone-text);
12
- }
13
- }
14
-
15
9
  .badge-frame-narrow {
16
10
  inline-size: 16rem;
17
11
  }
@@ -43,7 +43,7 @@ const longLabel = (variant: Variant): Props => ({
43
43
 
44
44
  export default definePart({
45
45
  note: 'Decided rules only',
46
- madeBy: ['claude-opus-5-5', 'claude-sonnet-5-5'],
46
+ madeBy: ['claude-opus-5-5', 'claude-sonnet-5-5', 'opus'],
47
47
  states: {
48
48
  filled: themed('filled'),
49
49
  tonal: themed('tonal'),
@@ -3376,8 +3376,15 @@ const MIN_PARTICIPANTS = {
3376
3376
  "single-elimination": 2,
3377
3377
  "double-elimination": 4
3378
3378
  };
3379
- const assertParticipantCount = (shape) => {
3379
+ const MAX_SWISS_ROUNDS = 171;
3380
+ const assertPlaceholderShape = (shape) => {
3380
3381
  const { participantCount, mode } = shape;
3382
+ if (mode === TOURNAMENT_MODE.SWISS) {
3383
+ if (!Number.isSafeInteger(participantCount) || participantCount < 4 || participantCount % 2 !== 0) throw new BracketRuntimeError(BRACKET_ERROR_CODES.PLACEHOLDER_SHAPE_INVALID, `A Swiss placeholder bracket needs an even participantCount of at least 4, got ${participantCount}.`);
3384
+ const { roundCount } = shape;
3385
+ if (!Number.isInteger(roundCount) || roundCount < 1 || roundCount > MAX_SWISS_ROUNDS) throw new BracketRuntimeError(BRACKET_ERROR_CODES.PLACEHOLDER_SHAPE_INVALID, `A Swiss placeholder bracket needs an integer roundCount from 1 through ${MAX_SWISS_ROUNDS}, got ${roundCount}.`);
3386
+ return;
3387
+ }
3381
3388
  const min = MIN_PARTICIPANTS[mode];
3382
3389
  const isPowerOfTwo = Number.isInteger(participantCount) && (participantCount & participantCount - 1) === 0;
3383
3390
  if (participantCount < min || !isPowerOfTwo) throw new BracketRuntimeError(BRACKET_ERROR_CODES.PLACEHOLDER_SHAPE_INVALID, `A ${mode} placeholder bracket needs a power-of-two participantCount of at least ${min}, got ${participantCount}.`);
@@ -3388,7 +3395,7 @@ const halvingCounts = (from) => {
3388
3395
  return counts;
3389
3396
  };
3390
3397
  const createPlaceholderBracketSource = (shape) => {
3391
- assertParticipantCount(shape);
3398
+ assertPlaceholderShape(shape);
3392
3399
  const rounds = [];
3393
3400
  const matches = [];
3394
3401
  const addRound = (round) => {
@@ -3410,6 +3417,18 @@ const createPlaceholderBracketSource = (shape) => {
3410
3417
  });
3411
3418
  };
3412
3419
  const { participantCount } = shape;
3420
+ if (shape.mode === TOURNAMENT_MODE.SWISS) {
3421
+ for (let index = 0; index < shape.roundCount; index++) addRound({
3422
+ id: `r${index}`,
3423
+ type: SWISS_BRACKET_ROUND_TYPE.SWISS,
3424
+ matchCount: participantCount / 2
3425
+ });
3426
+ return {
3427
+ mode: shape.mode,
3428
+ rounds,
3429
+ matches
3430
+ };
3431
+ }
3413
3432
  if (shape.mode === TOURNAMENT_MODE.SINGLE_ELIMINATION) {
3414
3433
  const counts = halvingCounts(participantCount / 2);
3415
3434
  counts.forEach((matchCount, index) => {