fansunited-management-components 1.53.4 → 1.53.6

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": "fansunited-management-components",
3
- "version": "1.53.4",
3
+ "version": "1.53.6",
4
4
  "main": "index.es.js",
5
5
  "module": "index.es.js",
6
6
  "types": "index.es.d.ts",
@@ -1,6 +1,6 @@
1
1
  import { default as React } from 'react';
2
2
 
3
- interface PlayerOption {
3
+ type PlayerOption = {
4
4
  id: string;
5
5
  name: string;
6
6
  avatar?: string;
@@ -11,8 +11,8 @@ interface PlayerOption {
11
11
  name: string;
12
12
  logo: string;
13
13
  }>;
14
- }
15
- interface PlayersProps {
14
+ };
15
+ type PlayersProps = {
16
16
  labels: {
17
17
  searchPlayersPlaceholder?: string;
18
18
  getPlayersErrorMessage: string;
@@ -20,7 +20,18 @@ interface PlayersProps {
20
20
  teamIds: string[];
21
21
  selectedPlayers: string[];
22
22
  onChangePlayers: (players: PlayerOption[]) => void;
23
- }
23
+ };
24
+ /**
25
+ * Multi-select players search with dual mode support: team-based filtering or global search.
26
+ *
27
+ * In team mode (when teamIds provided), loads all players from specified teams and filters locally.
28
+ * In search mode (when no teamIds), performs debounced API search by player name.
29
+ *
30
+ * @property {object} labels - Custom labels (searchPlayersPlaceholder, getPlayersErrorMessage).
31
+ * @property {string[]} teamIds - Team IDs to filter players by. When provided, enables team mode.
32
+ * @property {string[]} selectedPlayers - Initial selected player IDs.
33
+ * @property {(players: PlayerOption[]) => void} onChangePlayers - Emits selected player options.
34
+ */
24
35
  declare const PlayersSearchSelect: React.FC<PlayersProps>;
25
36
  export default PlayersSearchSelect;
26
37
  //# sourceMappingURL=PlayersSearchSelect.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PlayersSearchSelect.d.ts","sourceRoot":"","sources":["../../../../../src/components/Select/SearchSelect/PlayersSearchSelect.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAiE,MAAM,OAAO,CAAC;AAmBtF,UAAU,YAAY;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,KAAK,CAAC;QACb,EAAE,EAAE,MAAM,CAAC;QACX,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,EAAE,MAAM,CAAC;KACb,CAAC,CAAC;CACH;AAED,UAAU,YAAY;IACrB,MAAM,EAAE;QAAE,wBAAwB,CAAC,EAAE,MAAM,CAAC;QAAC,sBAAsB,EAAE,MAAM,CAAA;KAAE,CAAC;IAC9E,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,eAAe,EAAE,MAAM,EAAE,CAAC;IAC1B,eAAe,EAAE,CAAC,OAAO,EAAE,YAAY,EAAE,KAAK,IAAI,CAAC;CACnD;AAqID,QAAA,MAAM,mBAAmB,EAAE,KAAK,CAAC,EAAE,CAAC,YAAY,CA8M/C,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
1
+ {"version":3,"file":"PlayersSearchSelect.d.ts","sourceRoot":"","sources":["../../../../../src/components/Select/SearchSelect/PlayersSearchSelect.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAiE,MAAM,OAAO,CAAC;AAmBtF,KAAK,YAAY,GAAG;IACnB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,KAAK,CAAC;QACb,EAAE,EAAE,MAAM,CAAC;QACX,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,EAAE,MAAM,CAAC;KACb,CAAC,CAAC;CACH,CAAC;AAEF,KAAK,YAAY,GAAG;IACnB,MAAM,EAAE;QAAE,wBAAwB,CAAC,EAAE,MAAM,CAAC;QAAC,sBAAsB,EAAE,MAAM,CAAA;KAAE,CAAC;IAC9E,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,eAAe,EAAE,MAAM,EAAE,CAAC;IAC1B,eAAe,EAAE,CAAC,OAAO,EAAE,YAAY,EAAE,KAAK,IAAI,CAAC;CACnD,CAAC;AAqIF;;;;;;;;;;GAUG;AACH,QAAA,MAAM,mBAAmB,EAAE,KAAK,CAAC,EAAE,CAAC,YAAY,CA8M/C,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
@@ -10,9 +10,9 @@ type BooleanSwitchProps = {
10
10
  descriptionColor: ColorPaletteProp;
11
11
  disabled: boolean;
12
12
  sx?: {
13
- switch: SxProps;
14
- container: SxProps;
15
- label: SxProps;
13
+ switch?: SxProps;
14
+ container?: SxProps;
15
+ label?: SxProps;
16
16
  };
17
17
  onChange: (checked: boolean) => void;
18
18
  };
@@ -23,9 +23,9 @@ type BooleanSwitchProps = {
23
23
  * @property {'start'|'end'} [labelPosition='start'] - Where to place the switch relative to the label.
24
24
  * @property {boolean} defaultValue - Initial checked state.
25
25
  * @property {string} description - Optional helper text shown under the label.
26
- * @property {import('@mui/joy').ColorPaletteProp} descriptionColor - Color of the helper text.
26
+ * @property {ColorPaletteProp} descriptionColor - Color of the helper text.
27
27
  * @property {boolean} disabled - Disables interaction.
28
- * @property {{ switch?: import('@mui/material').SxProps; container?: import('@mui/material').SxProps }} [sx] - Style overrides.
28
+ * @property {{ switch?: SxProps; container?: SxProps; label?: SxProps }} [sx] - Style overrides.
29
29
  * @property {(checked: boolean) => void} onChange - Called when the switch is toggled.
30
30
  */
31
31
  declare const BooleanSwitch: React.FC<BooleanSwitchProps>;
@@ -1 +1 @@
1
- {"version":3,"file":"BooleanSwitch.d.ts","sourceRoot":"","sources":["../../../../src/components/Switch/BooleanSwitch.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAO,gBAAgB,EAAq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K,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC;IAChE,QAAQ,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;CACrC,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,QAAA,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CA2C/C,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -91,9 +91,9 @@ export declare const components: {
91
91
  descriptionColor: import('@mui/joy').ColorPaletteProp;
92
92
  disabled: boolean;
93
93
  sx?: {
94
- switch: import('@mui/material').SxProps;
95
- container: import('@mui/material').SxProps;
96
- label: import('@mui/material').SxProps;
94
+ switch?: import('@mui/material').SxProps;
95
+ container?: import('@mui/material').SxProps;
96
+ label?: import('@mui/material').SxProps;
97
97
  };
98
98
  onChange: (checked: boolean) => void;
99
99
  }>;
@@ -451,6 +451,32 @@ export declare const components: {
451
451
  sx?: import('@mui/material').SxProps;
452
452
  tooltipPlacement?: "bottom-end" | "bottom-start" | "bottom" | "left-end" | "left-start" | "left" | "right-end" | "right-start" | "right" | "top-end" | "top-start" | "top";
453
453
  }>;
454
+ /**
455
+ * Multi-select players search with dual mode support: team-based filtering or global search.
456
+ *
457
+ * In team mode (when teamIds provided), loads all players from specified teams and filters locally.
458
+ * In search mode (when no teamIds), performs debounced API search by player name.
459
+ */
460
+ readonly PlayersSearchSelect: import('react').FC<{
461
+ labels: {
462
+ searchPlayersPlaceholder?: string;
463
+ getPlayersErrorMessage: string;
464
+ };
465
+ teamIds: string[];
466
+ selectedPlayers: string[];
467
+ onChangePlayers: (players: {
468
+ id: string;
469
+ name: string;
470
+ avatar?: string;
471
+ countryName: string;
472
+ countryFlag: string;
473
+ teams?: Array<{
474
+ id: string;
475
+ name: string;
476
+ logo: string;
477
+ }>;
478
+ }[]) => void;
479
+ }>;
454
480
  };
455
481
  export type ComponentsMap = typeof components;
456
482
  //# sourceMappingURL=components.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"components.d.ts","sourceRoot":"","sources":["../../../src/constants/components.ts"],"names":[],"mappings":"AAiDA,eAAO,MAAM,UAAU;IACtB;;OAEG;;;;;IAEH;;OAEG;;;;;;;;;;;;IAEH;;OAEG;;;;;;;;;;IAEH;;OAEG;;;;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;;;;IAEH;;OAEG;;;;;;;;;;;;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;IAEH;;OAEG;;;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;;;;IAEH;;OAEG;;;;;;;;IAEH;;;;OAIG;;;;;;;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;;;IAEH;;;;;;;;OAQG;;;;;;;;IAEH;;OAEG;;;;;;;;;;IAEH;;OAEG;;;;;;;;IAEH;;OAEG;;;;;;;;;;;;;IAEH;;OAEG;;;;;;;;;;;;;;;IAEH;;OAEG;;;;;IAEH;;;;;OAKG;;;;;;;;;IAEH;;OAEG;;;;;;;IAEH;;OAEG;;;;;IAEH;;OAEG;;;;;;IAEH;;OAEG;;;;;;CAEM,CAAC;AAEX,MAAM,MAAM,aAAa,GAAG,OAAO,UAAU,CAAC"}
1
+ {"version":3,"file":"components.d.ts","sourceRoot":"","sources":["../../../src/constants/components.ts"],"names":[],"mappings":"AAkDA,eAAO,MAAM,UAAU;IACtB;;OAEG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
72
72
  sx?: {
73
- switch: import('@mui/material').SxProps;
74
- container: import('@mui/material').SxProps;
75
- label: import('@mui/material').SxProps;
73
+ switch?: import('@mui/material').SxProps;
74
+ container?: import('@mui/material').SxProps;
75
+ label?: import('@mui/material').SxProps;
76
76
  };
77
77
  onChange: (checked: boolean) => void;
78
78
  }>;
@@ -308,6 +308,26 @@ declare const ComponentContext: React.Context<{
308
308
  sx?: import('@mui/material').SxProps;
309
309
  tooltipPlacement?: "bottom-end" | "bottom-start" | "bottom" | "left-end" | "left-start" | "left" | "right-end" | "right-start" | "right" | "top-end" | "top-start" | "top";
310
310
  }>;
311
+ readonly PlayersSearchSelect: React.FC<{
312
+ labels: {
313
+ searchPlayersPlaceholder?: string;
314
+ getPlayersErrorMessage: string;
315
+ };
316
+ teamIds: string[];
317
+ selectedPlayers: string[];
318
+ onChangePlayers: (players: {
319
+ id: string;
320
+ name: string;
321
+ avatar?: string;
322
+ countryName: string;
323
+ countryFlag: string;
324
+ teams?: Array<{
325
+ id: string;
326
+ name: string;
327
+ logo: string;
328
+ }>;
329
+ }[]) => void;
330
+ }>;
311
331
  } | null>;
312
332
  /**
313
333
  * Provider that exposes the components registry to descendants with preserved types.
@@ -1 +1 @@
1
- {"version":3,"file":"ComponentContext.d.ts","sourceRoot":"","sources":["../../../src/context/ComponentContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAiB,iBAAiB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAG3E,KAAK,sBAAsB,GAAG;IAC7B,MAAM,CAAC,EAAE,GAAG,CAAC;IACb,QAAQ,CAAC,EAAE,SAAS,CAAC;CACrB,CAAC;AAEF,QAAA,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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