@ethlete/components 1.0.0-next.107 → 1.0.0-next.109

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ethlete/components",
3
- "version": "1.0.0-next.107",
3
+ "version": "1.0.0-next.109",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/ethlete-io/ethdk",
@@ -4,7 +4,7 @@
4
4
  align-items: center;
5
5
  box-sizing: border-box;
6
6
  block-size: 100%;
7
- padding-inline: 8px;
7
+ padding-inline-end: 8px;
8
8
  font-size: 16px;
9
9
  font-weight: 700;
10
10
  line-height: 1.3;
@@ -48,8 +48,6 @@
48
48
  .et-bracket-section-title-sticky {
49
49
  position: sticky;
50
50
  inset-inline-start: 0;
51
- box-sizing: border-box;
52
- padding-inline-start: var(--et-scrollable-start-fade-size, 0px);
53
51
  inline-size: max-content;
54
52
  max-inline-size: 100%;
55
53
  block-size: 100%;
@@ -37,6 +37,12 @@
37
37
  initial-value: 12px;
38
38
  }
39
39
 
40
+ @property --et-carousel-control-icon-size {
41
+ syntax: '<length>';
42
+ inherits: true;
43
+ initial-value: 14px;
44
+ }
45
+
40
46
  .et-carousel {
41
47
  display: flex;
42
48
  flex-direction: column;
@@ -146,9 +152,10 @@
146
152
  }
147
153
  }
148
154
 
149
- .et-carousel-control-icon {
150
- inline-size: 14px;
151
- block-size: 14px;
155
+ .et-carousel .et-carousel-control .et-icon-button-icon .et-carousel-control-icon {
156
+ inline-size: var(--et-carousel-control-icon-size);
157
+ block-size: var(--et-carousel-control-icon-size);
158
+ flex-shrink: 0;
152
159
 
153
160
  &:where(.et-carousel-control-icon--previous) {
154
161
  rotate: -90deg;
@@ -48,17 +48,20 @@
48
48
  #000 calc(100% - var(--_et-scrollable-mask-end)),
49
49
  transparent 100%
50
50
  ),
51
- linear-gradient(#000 0 0), linear-gradient(#000 0 0), linear-gradient(#000 0 0);
51
+ linear-gradient(#000 0 0), linear-gradient(#000 0 0), linear-gradient(#000 0 0),
52
+ var(--_et-scrollable-mask-hole-image, linear-gradient(transparent 0 0));
52
53
  mask-size:
53
54
  100% calc(100% - var(--_et-scrollable-scrollbar-size, 0px)),
54
55
  100% var(--_et-scrollable-scrollbar-size, 0px),
55
56
  var(--et-scrollable-mask-inset-start, 0px) 100%,
56
- var(--et-scrollable-mask-inset-end, 0px) 100%;
57
+ var(--et-scrollable-mask-inset-end, 0px) 100%,
58
+ var(--_et-scrollable-mask-hole-size, 0px 0px);
57
59
  mask-position:
58
60
  left top,
59
61
  left bottom,
60
62
  left top,
61
- right top;
63
+ right top,
64
+ var(--_et-scrollable-mask-hole-position, 0px 0px);
62
65
  mask-repeat: no-repeat;
63
66
 
64
67
  &:dir(rtl) {
@@ -70,12 +73,14 @@
70
73
  #000 calc(100% - var(--_et-scrollable-mask-end)),
71
74
  transparent 100%
72
75
  ),
73
- linear-gradient(#000 0 0), linear-gradient(#000 0 0), linear-gradient(#000 0 0);
76
+ linear-gradient(#000 0 0), linear-gradient(#000 0 0), linear-gradient(#000 0 0),
77
+ var(--_et-scrollable-mask-hole-image, linear-gradient(transparent 0 0));
74
78
  mask-position:
75
79
  right top,
76
80
  right bottom,
77
81
  right top,
78
- left top;
82
+ left top,
83
+ var(--_et-scrollable-mask-hole-position, 0px 0px);
79
84
  }
80
85
  }
81
86
 
@@ -93,24 +98,28 @@
93
98
  #000 calc(100% - var(--_et-scrollable-mask-end)),
94
99
  transparent 100%
95
100
  ),
96
- linear-gradient(#000 0 0), linear-gradient(#000 0 0), linear-gradient(#000 0 0);
101
+ linear-gradient(#000 0 0), linear-gradient(#000 0 0), linear-gradient(#000 0 0),
102
+ var(--_et-scrollable-mask-hole-image, linear-gradient(transparent 0 0));
97
103
  mask-size:
98
104
  calc(100% - var(--_et-scrollable-scrollbar-size, 0px)) 100%,
99
105
  var(--_et-scrollable-scrollbar-size, 0px) 100%,
100
106
  100% var(--et-scrollable-mask-inset-start, 0px),
101
- 100% var(--et-scrollable-mask-inset-end, 0px);
107
+ 100% var(--et-scrollable-mask-inset-end, 0px),
108
+ var(--_et-scrollable-mask-hole-size, 0px 0px);
102
109
  mask-position:
103
110
  left top,
104
111
  right top,
105
112
  left top,
106
- left bottom;
113
+ left bottom,
114
+ var(--_et-scrollable-mask-hole-position, 0px 0px);
107
115
 
108
116
  &:dir(rtl) {
109
117
  mask-position:
110
118
  right top,
111
119
  left top,
112
120
  right top,
113
- right bottom;
121
+ right bottom,
122
+ var(--_et-scrollable-mask-hole-position, 0px 0px);
114
123
  }
115
124
  }
116
125
 
@@ -265,8 +265,11 @@ export declare const TOURNAMENT_MODE: {
265
265
  readonly SINGLE_ELIMINATION: "single-elimination";
266
266
  readonly DOUBLE_ELIMINATION: "double-elimination";
267
267
  readonly SWISS_WITH_ELIMINATION: "swiss-with-elimination";
268
+ readonly SWISS: "swiss";
268
269
  };
269
270
  export type TournamentMode = (typeof TOURNAMENT_MODE)[keyof typeof TOURNAMENT_MODE];
271
+ /** Whether a stage is drawn as swiss record groups: `'swiss-with-elimination'` or `'swiss'`, which eliminates nobody. */
272
+ export declare const isSwissMode: (mode: TournamentMode) => mode is "swiss-with-elimination" | "swiss";
270
273
  /** Wins that advance a participant out of a swiss stage. */
271
274
  export declare const SWISS_ADVANCE_WINS = 3;
272
275
  /** Losses that eliminate a participant from a swiss stage. */
@@ -464,6 +467,8 @@ export type BracketRoundSwissGroup<TRoundData, TMatchData> = {
464
467
  name: string;
465
468
  matches: BracketMap<BracketMatchId, BracketMatch<TRoundData, TMatchData>>;
466
469
  allowedMatchCount: number;
470
+ /** The record tone of the group - see {@link getSwissGroupColorType}. */
471
+ colorType: BracketSwissGroupColorType;
467
472
  };
468
473
  export type BracketRoundSwissGroupMap<TRoundData, TMatchData> = Map<BracketRoundSwissGroupId, BracketRoundSwissGroup<TRoundData, TMatchData>>;
469
474
  export type BracketRoundSwissData<TRoundData, TMatchData> = {
@@ -490,8 +495,11 @@ export type BracketSwissGroupColorType = (typeof BRACKET_SWISS_GROUP_COLOR_TYPE)
490
495
  * which default to `--et-surface-border`).
491
496
  */
492
497
  export type BracketSwissColors = Partial<Record<BracketSwissGroupColorType, string>>;
493
- export declare const getSwissGroupColorType: (wins: number, losses: number) => BracketSwissGroupColorType;
494
- export declare const getAvailableSwissGroupsForRound: (roundNumber: number, totalMatchesInRound: number) => {
498
+ /** The record tone of a swiss group. A `'swiss'` stage eliminates nobody, so it has no negative tone. */
499
+ export declare const getSwissGroupColorType: (wins: number, losses: number, mode?: TournamentMode) => BracketSwissGroupColorType;
500
+ export declare const getAvailableSwissGroupsForRound: (roundNumber: number, totalMatchesInRound: number, mode?: TournamentMode) => {
501
+ wins: number;
502
+ losses: number;
495
503
  id: BracketRoundSwissGroupId;
496
504
  name: string;
497
505
  matchesInGroup: number;
@@ -1079,6 +1087,7 @@ export declare const gutterPath: (from: BracketPosition, to: BracketPosition, op
1079
1087
  export type BracketLayoutRegistration = {
1080
1088
  name: string;
1081
1089
  mode: TournamentMode;
1090
+ extraModes?: readonly TournamentMode[];
1082
1091
  };
1083
1092
  /** Returns the first registered layout matching the tournament mode. */
1084
1093
  export declare const resolveBracketLayout: <TLayout extends BracketLayoutRegistration>(layouts: readonly TLayout[] | undefined, mode: TournamentMode) => TLayout;
@@ -2205,6 +2205,8 @@ export type BracketLayout<TRoundData = any, TMatchData = any> = {
2205
2205
  * match in the registered array wins.
2206
2206
  */
2207
2207
  mode: TournamentMode$1;
2208
+ /** More tournament modes this layout draws - `swissBracketLayout()` draws `'swiss'` too. */
2209
+ extraModes?: readonly TournamentMode$1[];
2208
2210
  /** Positions the linked bracket's rounds and matches into a grid of columns. */
2209
2211
  createGrid: (bracket: Bracket$1<TRoundData, TMatchData>, options: CreateBracketGridConfig$1, components: BracketComponents$1<TRoundData, TMatchData>) => ComputedBracketGrid$1<TRoundData, TMatchData>;
2210
2212
  /**
@@ -3623,9 +3625,9 @@ export type SwissBracketLayoutOptions<TRoundData = any, TMatchData = any> = {
3623
3625
  roundHeaderComponent?: BracketRoundHeaderComponent$1<TRoundData, TMatchData>;
3624
3626
  };
3625
3627
  /**
3626
- * Draws a swiss stage (with elimination) as standings groups per round - winners climbing, losers
3627
- * sinking, group-to-group connection lines instead of match-to-match. What a `mode` of
3628
- * `'swiss-with-elimination'` renders once this is registered.
3628
+ * Draws a swiss stage as standings groups per round - winners climbing, losers sinking, group-to-group
3629
+ * connection lines instead of match-to-match. What a `mode` of `'swiss-with-elimination'` or `'swiss'`
3630
+ * renders once this is registered.
3629
3631
  *
3630
3632
  * @example
3631
3633
  * provideBracketConfig({ layouts: [swissBracketLayout()] });
@@ -5806,9 +5808,30 @@ export declare class ScrollableLoadingTemplateDirective {
5806
5808
  };
5807
5809
  }, {}, never, never, true, never>;
5808
5810
  }
5811
+ /**
5812
+ * Keeps the box of this element out of the scrollable's edge masks, so a sticky child stays fully
5813
+ * visible at the edge while the content around it still fades. Put it on a descendant of `et-scrollable`.
5814
+ */
5815
+ export declare class ScrollableMaskHoleDirective {
5816
+ private scrollable;
5817
+ private element;
5818
+ enabled: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
5819
+ private dimensions;
5820
+ constructor();
5821
+ static ɵfac: i0.ɵɵFactoryDeclaration<ScrollableMaskHoleDirective, never>;
5822
+ static ɵdir: i0.ɵɵDirectiveDeclaration<ScrollableMaskHoleDirective, "[etScrollableMaskHole]", never, {
5823
+ "enabled": {
5824
+ "alias": "etScrollableMaskHole";
5825
+ "required": false;
5826
+ "isSignal": true;
5827
+ };
5828
+ }, {}, never, never, true, never>;
5829
+ }
5809
5830
  export declare class ScrollableMasksComponent {
5810
5831
  private scrollable;
5832
+ private renderer;
5811
5833
  constructor();
5834
+ private writeMaskHoles;
5812
5835
  static ɵfac: i0.ɵɵFactoryDeclaration<ScrollableMasksComponent, never>;
5813
5836
  static ɵcmp: i0.ɵɵComponentDeclaration<ScrollableMasksComponent, "et-scrollable-masks, [et-scrollable-masks]", never, {}, {}, never, never, true, never>;
5814
5837
  }
@@ -5967,10 +5990,10 @@ export declare class ScrollableComponent {
5967
5990
  }
5968
5991
  /**
5969
5992
  * The base scrollable: the track, its edge masks, the loading template and the active-child /
5970
- * ignore-child markers. Deliberately lean - the chrome and the gestures ship as their own imports
5993
+ * ignore-child / mask-hole markers. Deliberately lean - the chrome and the gestures ship as their own imports
5971
5994
  * arrays, so a track you only scroll never pulls in the buttons' icon button or the drag primitives.
5972
5995
  */
5973
- export declare const SCROLLABLE_IMPORTS: readonly [typeof ScrollableComponent, typeof ScrollableActiveChildDirective, typeof ScrollableIgnoreChildDirective, typeof ScrollableLoadingTemplateDirective];
5996
+ export declare const SCROLLABLE_IMPORTS: readonly [typeof ScrollableComponent, typeof ScrollableActiveChildDirective, typeof ScrollableIgnoreChildDirective, typeof ScrollableLoadingTemplateDirective, typeof ScrollableMaskHoleDirective];
5974
5997
  /**
5975
5998
  * The scrollable's decorative chrome, applied on the `<et-scrollable>` itself: `etScrollableButtons` for
5976
5999
  * the previous/next buttons, `etScrollableNavigation` for the dots. Pulls in the icon button (and with it
@@ -6501,6 +6524,8 @@ export declare class CarouselComponent {
6501
6524
  autoplay: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
6502
6525
  /** Render the previous/next controls. @default true */
6503
6526
  showControls: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
6527
+ /** Registered icon name for the previous and next controls. Use artwork that points up. */
6528
+ controlIcon: import("@angular/core").InputSignal<string>;
6504
6529
  /** Render the slide dots, which double as the autoplay progress indicator. @default true */
6505
6530
  showDots: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
6506
6531
  /**
@@ -6546,6 +6571,11 @@ export declare class CarouselComponent {
6546
6571
  "required": false;
6547
6572
  "isSignal": true;
6548
6573
  };
6574
+ "controlIcon": {
6575
+ "alias": "controlIcon";
6576
+ "required": false;
6577
+ "isSignal": true;
6578
+ };
6549
6579
  "showDots": {
6550
6580
  "alias": "showDots";
6551
6581
  "required": false;
@@ -35936,6 +35966,8 @@ export declare class TabBarDirective {
35936
35966
  * per breakpoint; other `etScrollableButtons` options are accepted too. Wins over `provideScrollableConfig`.
35937
35967
  */
35938
35968
  scrollableButtons: import("@angular/core").InputSignal<boolean | ScrollableButtonsConfig | undefined>;
35969
+ /** Fades the bar's edges while it can scroll there, like a plain `<et-scrollable>`. */
35970
+ renderMasks: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
35939
35971
  private registeredTriggers;
35940
35972
  focusedIndex: import("@angular/core").WritableSignal<number>;
35941
35973
  selectedIndex: import("@angular/core").WritableSignal<number>;
@@ -35989,6 +36021,11 @@ export declare class TabBarDirective {
35989
36021
  "required": false;
35990
36022
  "isSignal": true;
35991
36023
  };
36024
+ "renderMasks": {
36025
+ "alias": "renderMasks";
36026
+ "required": false;
36027
+ "isSignal": true;
36028
+ };
35992
36029
  }, {}, never, never, true, never>;
35993
36030
  }
35994
36031
  export declare const TAB_BAR_TOKEN: InjectionToken<TabBarDirective>;
@@ -36126,6 +36163,7 @@ export declare class NavTabsComponent {
36126
36163
  "activeUnderline": "activeUnderline";
36127
36164
  "underlineWidth": "underlineWidth";
36128
36165
  "scrollableButtons": "scrollableButtons";
36166
+ "renderMasks": "renderMasks";
36129
36167
  };
36130
36168
  outputs: {};
36131
36169
  }, {
@@ -36323,6 +36361,7 @@ export declare class TabGroupComponent {
36323
36361
  "activeUnderline": "activeUnderline";
36324
36362
  "underlineWidth": "underlineWidth";
36325
36363
  "scrollableButtons": "scrollableButtons";
36364
+ "renderMasks": "renderMasks";
36326
36365
  };
36327
36366
  outputs: {};
36328
36367
  }, {
@@ -37557,5 +37596,5 @@ export declare const provideUnsavedChangesLabels: (labels: import("@ethlete/core
37557
37596
  export declare const injectUnsavedChangesLabels: () => import("@angular/core").Signal<UnsavedChangesLabels>;
37558
37597
  export declare const UNSAVED_CHANGES_LABELS: import("@angular/core").InjectionToken<import("@ethlete/core").LabelsSource<UnsavedChangesLabels>>;
37559
37598
  /** The version of `@ethlete/components` this build was cut from. */
37560
- export declare const COMPONENTS_VERSION = "1.0.0-next.107";
37599
+ export declare const COMPONENTS_VERSION = "1.0.0-next.109";
37561
37600
  export { type AlertDialogComponentSlot, type AlertDialogSlot, type AlertDialogTemplateSlot, type AppointmentTreeNode, BRACKET_DATA_LAYOUT, BRACKET_ERROR_CODES, BRACKET_FINAL_ALIGNMENT, BRACKET_ROUND_MIRROR_TYPE, BRACKET_SECTION_KEY, BRACKET_SWISS_GROUP_COLOR_TYPE, type Bracket, type BracketByeSlotSource, type BracketComponents, type BracketContinueComponent, type BracketDataLayout, type BracketDataSource, type BracketDrawing, type BracketEdge, type BracketExternalSlotSource, type BracketFinalAlignment, type BracketGradient, type BracketGradientStop, type BracketGridSection, type BracketLayoutSettings, BracketMap, type BracketMatch, type BracketMatchComponent, type BracketMatchFactor, type BracketMatchId, type BracketMatchInputs, type BracketMatchOutcomeSlotSource, type BracketMatchParticipant, type BracketMatchPosition, type BracketMatchRelation, type BracketMatchRelationNone, type BracketMatchRelationNothingToOne, type BracketMatchRelationOneToNothing, type BracketMatchRelationOneToOne, type BracketMatchRelationTwoToNothing, type BracketMatchRelationTwoToOne, type BracketMatchShortId, type BracketMatchSlot, type BracketMatchSource, type BracketMatchStatus, type BracketParticipant, type BracketParticipantMatch, type BracketPickMigration, type BracketPickMigrationOptions, type BracketPickSet, type BracketRect, type BracketRound, type BracketRoundHeaderComponent, type BracketRoundId, type BracketRoundMapWithSwissData, type BracketRoundMirrorType, type BracketRoundPosition, type BracketRoundRelation, type BracketRoundRelationNone, type BracketRoundRelationNothingToOne, type BracketRoundRelationOneToNothing, type BracketRoundRelationOneToOne, type BracketRoundRelationTwoToNothing, type BracketRoundRelationTwoToOne, type BracketRoundShortId, type BracketRoundSource, type BracketRoundSwissData, type BracketRoundSwissGroup, type BracketRoundSwissGroupId, type BracketRoundSwissGroupMap, type BracketRoundType, BracketRuntimeError, type BracketSectionKey, type BracketSectionTitleComponent, type BracketSeedSlotSource, type BracketSlotResolutionPolicy, type BracketSlotSource, type BracketSlotSourceKind, type BracketStandingRankSide, type BracketStandingRankSlotSource, type BracketSwissBucketSlotSource, type BracketSwissColors, type BracketSwissGroupColorType, type BracketWarning, COMMON_BRACKET_ROUND_TYPE, type CalendarBandPosition, type CalendarInterval, type CalendarPrecision, type CalendarSelectionFlags, type CalendarView, type CalendarWeekStartsOn, type CascaderCompareWith, type CascaderDataSource, type CascaderNode, type CommonBracketRoundType, type ComputedBracketGrid, type CreateBracketGridConfig, type CreateBracketOptions, type CreateGridAdapterOptions, DOUBLE_ELIMINATION_BRACKET_ROUND_TYPE, type DateRangeSide, type DateRangeSide as TimeRangeInputSide, type DateRangeValue, type DateRangeValue as DateTimeRangeValue, type DateRangeValue as TimeRangeValue, type DoubleEliminationBracketRoundType, type DropzoneCropConfig, type DropzoneCropCorner, type DropzoneCropRect, type DropzoneCropShape, type DurationFormatSpec, type DurationSegment, type DurationUnit, GROUP_BRACKET_ROUND_TYPE, type GridAdapter, type GridAdapterBreakpoints, type GridConfig, type GroupBracketRoundType, type MatchParticipantId, type MatchParticipantShortId, type MatchParticipantSide, type ParticipantMatchResult, type PlaceholderBracketShape, type RichTextEditorHeadingLevel, type RichTextEditorImageFailure, type RichTextEditorImageFailureReason, type RichTextEditorImageUpload, type RichTextEditorImageUploadContext, type RichTextEditorImageUploadFn, type RichTextEditorTokenChip, type RichTextEditorTokenCodec, SINGLE_ELIMINATION_BRACKET_ROUND_TYPE, SWISS_BRACKET_ROUND_TYPE, type SchedulerAgendaDay, type SchedulerMonthDayCell, type SchedulerTimeGridAllDayEntry, type SchedulerTimeGridBlock, type SchedulerTimeGridDay, type SchedulerTimeGridSegment, type ScrollableActiveChildRef, type ScrollableButtonPosition, type ScrollableButtonsConfig, type ScrollableButtonsDefaults, type ScrollableChrome, type ScrollableChromeSlot, type ScrollableConfig, type ScrollableDirection, type ScrollableIntersectionChange, type ScrollableItemSize, type ScrollableLoadingTemplatePosition, type ScrollableLoadingTemplateRef, type ScrollableMaskVariant, type ScrollableNavigation, type ScrollableNavigationConfig, type ScrollableNavigationItem, type ScrollableResponsive, type ScrollableScrollMode, type ScrollableScrollOrigin, type ScrollableScrollState, type ScrollbarGeometry, type ScrollbarOrientation, type ScrollbarTarget, type SerializeOptions, type SingleEliminationBracketRoundType, type StandingPick, type StandingPickOutcome, type SwissBracketRoundType, TOURNAMENT_MODE, type TournamentMode, bracketSlot, createBracket, createPlaceholderBracketSource, injectRichTextEditorTools, isBracketSlotPredictable, migrateBracketPicks, resolveBracketSlot, standingRankSides, swapStandingRank, validateBracketSource };