@alfalab/core-components-picker-button 10.2.0 → 10.2.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 (49) hide show
  1. package/Component.d.ts +1 -1
  2. package/Component.js +2 -2
  3. package/Component.mobile.js +1 -1
  4. package/Component.responsive.d.ts +1 -1
  5. package/Component.responsive.js +1 -1
  6. package/cssm/index.d.ts +3 -2
  7. package/cssm/typings-85892853.d.ts +41 -1
  8. package/desktop.js +1 -1
  9. package/esm/Component.js +2 -2
  10. package/esm/Component.mobile.js +1 -1
  11. package/esm/Component.responsive.js +1 -1
  12. package/esm/desktop.js +1 -1
  13. package/esm/field/Component.js +2 -2
  14. package/esm/field/index.css +4 -4
  15. package/esm/field/index.js +1 -1
  16. package/esm/index.css +7 -7
  17. package/esm/index.d.ts +3 -2
  18. package/esm/index.js +1 -1
  19. package/esm/mobile.js +1 -1
  20. package/esm/option/Component.js +2 -2
  21. package/esm/option/index.css +4 -4
  22. package/esm/option/index.js +1 -1
  23. package/esm/responsive.js +1 -1
  24. package/esm/{tslib.es6-46fd1a84.d.ts → tslib.es6-b7613d2d.d.ts} +0 -0
  25. package/esm/{tslib.es6-46fd1a84.js → tslib.es6-b7613d2d.js} +0 -0
  26. package/esm/typings-85892853.d.ts +41 -1
  27. package/field/Component.js +2 -2
  28. package/field/index.css +4 -4
  29. package/field/index.js +1 -1
  30. package/index.css +7 -7
  31. package/index.d.ts +3 -2
  32. package/index.js +1 -1
  33. package/mobile.js +1 -1
  34. package/modern/Component.js +1 -1
  35. package/modern/field/Component.js +1 -1
  36. package/modern/field/index.css +4 -4
  37. package/modern/index.css +7 -7
  38. package/modern/index.d.ts +3 -2
  39. package/modern/option/Component.js +1 -1
  40. package/modern/option/index.css +4 -4
  41. package/modern/typings-85892853.d.ts +41 -1
  42. package/option/Component.js +2 -2
  43. package/option/index.css +4 -4
  44. package/option/index.js +1 -1
  45. package/package.json +2 -2
  46. package/responsive.js +1 -1
  47. package/{tslib.es6-287864ca.d.ts → tslib.es6-5a652c21.d.ts} +0 -0
  48. package/{tslib.es6-287864ca.js → tslib.es6-5a652c21.js} +0 -0
  49. package/typings-85892853.d.ts +42 -2
package/Component.d.ts CHANGED
@@ -21,7 +21,7 @@ type PickerButtonDesktopProps = Omit<BaseSelectProps, 'Field' | 'placeholder' |
21
21
  */
22
22
  variant?: PickerButtonVariant;
23
23
  };
24
- declare const PickerButtonDesktop: React.ForwardRefExoticComponent<Omit<BaseSelectProps, "size" | "placeholder" | "onFocus" | "selected" | "multiple" | "hint" | "options" | "autocomplete" | "allowUnselect" | "closeOnSelect" | "fieldProps" | "Arrow" | "Field"> & Pick<ButtonProps, "view" | "leftAddons" | "rightAddons" | "loading"> & {
24
+ declare const PickerButtonDesktop: React.ForwardRefExoticComponent<Omit<BaseSelectProps, "size" | "hint" | "placeholder" | "onFocus" | "selected" | "multiple" | "options" | "autocomplete" | "allowUnselect" | "closeOnSelect" | "fieldProps" | "Arrow" | "Field"> & Pick<ButtonProps, "leftAddons" | "rightAddons" | "view" | "loading"> & {
25
25
  options: Array<BaseSelectProps['options'][0] & {
26
26
  /**
27
27
  * Иконка, отображающаяся слева от текстового представления пункта
package/Component.js CHANGED
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var tslib_es6 = require('./tslib.es6-287864ca.js');
3
+ var tslib_es6 = require('./tslib.es6-5a652c21.js');
4
4
  var React = require('react');
5
5
  var cn = require('classnames');
6
6
  var coreComponentsSelect = require('@alfalab/core-components-select');
@@ -18,7 +18,7 @@ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'defau
18
18
  var React__default = /*#__PURE__*/_interopDefaultCompat(React);
19
19
  var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
20
20
 
21
- var styles = {"container":"picker-button__container_ygp5q","optionsPopover":"picker-button__optionsPopover_ygp5q","sideGap":"picker-button__sideGap_ygp5q","optionsListContainer":"picker-button__optionsListContainer_ygp5q","option":"picker-button__option_ygp5q"};
21
+ var styles = {"container":"picker-button__container_4p9wi","optionsPopover":"picker-button__optionsPopover_4p9wi","sideGap":"picker-button__sideGap_4p9wi","optionsListContainer":"picker-button__optionsListContainer_4p9wi","option":"picker-button__option_4p9wi"};
22
22
  require('./index.css')
23
23
 
24
24
  var SIDE_POSITIONS = ['right', 'right-start', 'right-end', 'left', 'left-start', 'left-end'];
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var tslib_es6 = require('./tslib.es6-287864ca.js');
3
+ var tslib_es6 = require('./tslib.es6-5a652c21.js');
4
4
  var React = require('react');
5
5
  var coreComponentsSelect = require('@alfalab/core-components-select');
6
6
  var field_Component = require('./field/Component.js');
@@ -11,7 +11,7 @@ type PickerButtonResponsiveProps = PickerButtonDesktopProps & AdditionalMobilePr
11
11
  */
12
12
  breakpoint?: number;
13
13
  };
14
- declare const PickerButtonResponsive: React.ForwardRefExoticComponent<Omit<import("@alfalab/core-components-select").BaseSelectProps, "size" | "placeholder" | "onFocus" | "selected" | "multiple" | "hint" | "options" | "autocomplete" | "allowUnselect" | "closeOnSelect" | "fieldProps" | "Arrow" | "Field"> & Pick<ButtonProps, "view" | "leftAddons" | "rightAddons" | "loading"> & {
14
+ declare const PickerButtonResponsive: React.ForwardRefExoticComponent<Omit<import("@alfalab/core-components-select").BaseSelectProps, "size" | "hint" | "placeholder" | "onFocus" | "selected" | "multiple" | "options" | "autocomplete" | "allowUnselect" | "closeOnSelect" | "fieldProps" | "Arrow" | "Field"> & Pick<ButtonProps, "leftAddons" | "rightAddons" | "view" | "loading"> & {
15
15
  options: ((import("@alfalab/core-components-select").OptionShape | import("@alfalab/core-components-select").GroupShape) & {
16
16
  icon?: React.FC<React.SVGProps<SVGSVGElement>> | undefined;
17
17
  })[];
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var tslib_es6 = require('./tslib.es6-287864ca.js');
3
+ var tslib_es6 = require('./tslib.es6-5a652c21.js');
4
4
  var React = require('react');
5
5
  var hooks = require('@alfalab/hooks');
6
6
  var Component = require('./Component.js');
package/cssm/index.d.ts CHANGED
@@ -1,2 +1,3 @@
1
- export { PickerButtonResponsive as PickerButton, PickerButtonResponsiveProps as PickerButtonProps } from "./responsive";
2
- export { PickerButtonDesktopProps, PickerButtonSize, PickerButtonVariant } from "./Component";
1
+ export { PickerButtonResponsive as PickerButton } from "./responsive";
2
+ export type { PickerButtonResponsiveProps as PickerButtonProps } from "./responsive";
3
+ export type { PickerButtonDesktopProps, PickerButtonSize, PickerButtonVariant } from "./Component";
@@ -358,6 +358,46 @@ declare const FormControl: React.ForwardRefExoticComponent<React.HTMLAttributes<
358
358
  dataTestId?: string | undefined;
359
359
  children?: ReactNode;
360
360
  } & React.RefAttributes<HTMLDivElement>>;
361
+ type BadgeProps = {
362
+ /**
363
+ * Дополнительный класс
364
+ */
365
+ className?: string;
366
+ /**
367
+ * Вид компонента
368
+ */
369
+ view: "icon" | "count";
370
+ /**
371
+ * Размер компонента (только для view=icon)
372
+ * //deprecated(используйте height для view=count )
373
+ */
374
+ size?: "s" | "m" | "l" | "xl";
375
+ /**
376
+ * Видимость белой обводки вокруг иконки
377
+ */
378
+ visibleIconOutline?: boolean;
379
+ /**
380
+ * Видимость цветной обводки вокруг иконки (только для view=icon)
381
+ */
382
+ visibleColorOutline?: boolean;
383
+ /**
384
+ * Контент компонента
385
+ */
386
+ content?: React.ReactElement | number;
387
+ /**
388
+ * Высота компонента, min = 16; max = 48 (только для view=count)
389
+ */
390
+ height?: number;
391
+ /**
392
+ * Цветовое оформление иконки
393
+ */
394
+ iconColor?: "positive" | "attention" | "link" | "negative" | "tertiary" | "secondary" | "primary";
395
+ /**
396
+ * Идентификатор для систем автоматизированного тестирования
397
+ */
398
+ dataTestId?: string;
399
+ };
400
+ declare const Badge: ({ className, size, view, visibleIconOutline, visibleColorOutline, content, height, iconColor, dataTestId }: BadgeProps) => JSX.Element;
361
401
  type PortalProps = {
362
402
  /** Контент */
363
403
  children?: ReactNode;
@@ -948,4 +988,4 @@ type CheckmarkProps = {
948
988
  */
949
989
  icon?: React.FC<React.SVGProps<SVGSVGElement>>;
950
990
  };
951
- export { InputProps, Input, Position, PopoverProps, Popover, FormControlProps, FormControl, PortalProps, Portal, stackingOrder, StackingContext, StackProps, Stack, PORTAL_CONTAINER_ATTRIBUTE, getDefaultPortalContainer, setRef, OptionShape, GroupShape, BaseSelectChangePayload, BaseSelectProps, FieldProps, ArrowProps, OptionsListProps, OptgroupProps, OptionProps, CheckmarkProps };
991
+ export { InputProps, Input, Position, PopoverProps, Popover, FormControlProps, FormControl, BadgeProps, Badge, PortalProps, Portal, stackingOrder, StackingContext, StackProps, Stack, PORTAL_CONTAINER_ATTRIBUTE, getDefaultPortalContainer, setRef, OptionShape, GroupShape, BaseSelectChangePayload, BaseSelectProps, FieldProps, ArrowProps, OptionsListProps, OptgroupProps, OptionProps, CheckmarkProps };
package/desktop.js CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var Component = require('./Component.js');
4
- require('./tslib.es6-287864ca.js');
4
+ require('./tslib.es6-5a652c21.js');
5
5
  require('react');
6
6
  require('classnames');
7
7
  require('@alfalab/core-components-select');
package/esm/Component.js CHANGED
@@ -1,4 +1,4 @@
1
- import { _ as __rest, a as __assign } from './tslib.es6-46fd1a84.js';
1
+ import { _ as __rest, a as __assign } from './tslib.es6-b7613d2d.js';
2
2
  import React, { forwardRef } from 'react';
3
3
  import cn from 'classnames';
4
4
  import { BaseSelect, OptionsList, Optgroup } from '@alfalab/core-components-select/esm';
@@ -11,7 +11,7 @@ import '@alfalab/icons-glyph/ChevronDownMIcon';
11
11
  import '@alfalab/icons-glyph/MoreMIcon';
12
12
  import '@alfalab/icons-glyph/MoreSIcon';
13
13
 
14
- var styles = {"container":"picker-button__container_ygp5q","optionsPopover":"picker-button__optionsPopover_ygp5q","sideGap":"picker-button__sideGap_ygp5q","optionsListContainer":"picker-button__optionsListContainer_ygp5q","option":"picker-button__option_ygp5q"};
14
+ var styles = {"container":"picker-button__container_4p9wi","optionsPopover":"picker-button__optionsPopover_4p9wi","sideGap":"picker-button__sideGap_4p9wi","optionsListContainer":"picker-button__optionsListContainer_4p9wi","option":"picker-button__option_4p9wi"};
15
15
  require('./index.css')
16
16
 
17
17
  var SIDE_POSITIONS = ['right', 'right-start', 'right-end', 'left', 'left-start', 'left-end'];
@@ -1,4 +1,4 @@
1
- import { _ as __rest, a as __assign } from './tslib.es6-46fd1a84.js';
1
+ import { _ as __rest, a as __assign } from './tslib.es6-b7613d2d.js';
2
2
  import React, { forwardRef } from 'react';
3
3
  import { SelectMobile, Optgroup } from '@alfalab/core-components-select/esm';
4
4
  import { Field } from './field/Component.js';
@@ -1,4 +1,4 @@
1
- import { _ as __rest, a as __assign } from './tslib.es6-46fd1a84.js';
1
+ import { _ as __rest, a as __assign } from './tslib.es6-b7613d2d.js';
2
2
  import React, { forwardRef } from 'react';
3
3
  import { useMedia } from '@alfalab/hooks';
4
4
  import { PickerButtonDesktop } from './Component.js';
package/esm/desktop.js CHANGED
@@ -1,5 +1,5 @@
1
1
  export { PickerButtonDesktop } from './Component.js';
2
- import './tslib.es6-46fd1a84.js';
2
+ import './tslib.es6-b7613d2d.js';
3
3
  import 'react';
4
4
  import 'classnames';
5
5
  import '@alfalab/core-components-select/esm';
@@ -1,4 +1,4 @@
1
- import { _ as __rest, a as __assign } from '../tslib.es6-46fd1a84.js';
1
+ import { _ as __rest, a as __assign } from '../tslib.es6-b7613d2d.js';
2
2
  import React, { Fragment } from 'react';
3
3
  import cn from 'classnames';
4
4
  import { Button } from '@alfalab/core-components-button/esm';
@@ -8,7 +8,7 @@ import '@alfalab/icons-glyph/ChevronDownMIcon';
8
8
  import '@alfalab/icons-glyph/MoreMIcon';
9
9
  import '@alfalab/icons-glyph/MoreSIcon';
10
10
 
11
- var styles = {"iconContainer":"picker-button__iconContainer_1l79r","addonsContainer":"picker-button__addonsContainer_1l79r","open":"picker-button__open_1l79r"};
11
+ var styles = {"iconContainer":"picker-button__iconContainer_dvipe","addonsContainer":"picker-button__addonsContainer_dvipe","open":"picker-button__open_dvipe"};
12
12
  require('./index.css')
13
13
 
14
14
  var Field = function (_a) {
@@ -1,4 +1,4 @@
1
- /* hash: lq5s9 */
1
+ /* hash: 20dyo */
2
2
  :root {
3
3
 
4
4
  /* Hard */
@@ -13,14 +13,14 @@
13
13
  :root {
14
14
  --arrow-transform: rotate(180deg);
15
15
  }
16
- .picker-button__iconContainer_1l79r {
16
+ .picker-button__iconContainer_dvipe {
17
17
  display: flex;
18
18
  transition: transform 0.15s ease-in-out;
19
19
  }
20
- .picker-button__addonsContainer_1l79r {
20
+ .picker-button__addonsContainer_dvipe {
21
21
  display: flex;
22
22
  margin-right: var(--gap-2xs);
23
23
  }
24
- .picker-button__open_1l79r {
24
+ .picker-button__open_dvipe {
25
25
  transform: var(--arrow-transform);
26
26
  }
@@ -1,5 +1,5 @@
1
1
  export { Field } from './Component.js';
2
- import '../tslib.es6-46fd1a84.js';
2
+ import '../tslib.es6-b7613d2d.js';
3
3
  import 'react';
4
4
  import 'classnames';
5
5
  import '@alfalab/core-components-button/esm';
package/esm/index.css CHANGED
@@ -1,4 +1,4 @@
1
- /* hash: hja1p */
1
+ /* hash: cb0x3 */
2
2
  :root {
3
3
 
4
4
  /* Hard */
@@ -15,22 +15,22 @@
15
15
  :root {
16
16
  --border-radius-m: 8px;
17
17
  }
18
- .picker-button__container_ygp5q {
18
+ .picker-button__container_4p9wi {
19
19
  min-width: auto;
20
20
  }
21
- .cc-picker-button.picker-button__optionsPopover_ygp5q {
21
+ .cc-picker-button.picker-button__optionsPopover_4p9wi {
22
22
  padding: var(--gap-2xs) 0
23
23
  }
24
- .cc-picker-button.picker-button__optionsPopover_ygp5q.picker-button__sideGap_ygp5q {
24
+ .cc-picker-button.picker-button__optionsPopover_4p9wi.picker-button__sideGap_4p9wi {
25
25
  padding: 0 var(--gap-xs);
26
26
  }
27
- .cc-picker-button .picker-button__optionsListContainer_ygp5q {
27
+ .cc-picker-button .picker-button__optionsListContainer_4p9wi {
28
28
  border-radius: var(--border-radius-m);
29
29
  }
30
- .cc-picker-button .picker-button__option_ygp5q {
30
+ .cc-picker-button .picker-button__option_4p9wi {
31
31
  padding: 0 var(--gap-m)
32
32
  }
33
- .cc-picker-button .picker-button__option_ygp5q:before {
33
+ .cc-picker-button .picker-button__option_4p9wi:before {
34
34
  /* Удаляем разделители у опций выпадающего списка. */
35
35
  display: none;
36
36
  }
package/esm/index.d.ts CHANGED
@@ -1,2 +1,3 @@
1
- export { PickerButtonResponsive as PickerButton, PickerButtonResponsiveProps as PickerButtonProps } from "./responsive";
2
- export { PickerButtonDesktopProps, PickerButtonSize, PickerButtonVariant } from "./Component";
1
+ export { PickerButtonResponsive as PickerButton } from "./responsive";
2
+ export type { PickerButtonResponsiveProps as PickerButtonProps } from "./responsive";
3
+ export type { PickerButtonDesktopProps, PickerButtonSize, PickerButtonVariant } from "./Component";
package/esm/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  export { PickerButtonResponsive as PickerButton } from './Component.responsive.js';
2
- import './tslib.es6-46fd1a84.js';
2
+ import './tslib.es6-b7613d2d.js';
3
3
  import 'react';
4
4
  import '@alfalab/hooks';
5
5
  import './Component.js';
package/esm/mobile.js CHANGED
@@ -1,5 +1,5 @@
1
1
  export { PickerButtonMobile } from './Component.mobile.js';
2
- import './tslib.es6-46fd1a84.js';
2
+ import './tslib.es6-b7613d2d.js';
3
3
  import 'react';
4
4
  import '@alfalab/core-components-select/esm';
5
5
  import './field/Component.js';
@@ -1,8 +1,8 @@
1
- import { _ as __rest, a as __assign } from '../tslib.es6-46fd1a84.js';
1
+ import { _ as __rest, a as __assign } from '../tslib.es6-b7613d2d.js';
2
2
  import React from 'react';
3
3
  import { Option as Option$1 } from '@alfalab/core-components-select/esm';
4
4
 
5
- var styles = {"container":"picker-button__container_1cb5l","icon":"picker-button__icon_1cb5l","content":"picker-button__content_1cb5l"};
5
+ var styles = {"container":"picker-button__container_1g1ys","icon":"picker-button__icon_1g1ys","content":"picker-button__content_1g1ys"};
6
6
  require('./index.css')
7
7
 
8
8
  var Option = function (_a) {
@@ -1,4 +1,4 @@
1
- /* hash: 1uq5f */
1
+ /* hash: 1phwa */
2
2
  :root {
3
3
 
4
4
  /* Hard */
@@ -10,15 +10,15 @@
10
10
  :root {
11
11
  --gap-s: 12px;
12
12
  }
13
- .picker-button__container_1cb5l {
13
+ .picker-button__container_1g1ys {
14
14
  display: flex;
15
15
  align-items: center;
16
16
  }
17
- .picker-button__icon_1cb5l {
17
+ .picker-button__icon_1g1ys {
18
18
  display: flex;
19
19
  margin-right: var(--gap-s);
20
20
  }
21
- .picker-button__content_1cb5l {
21
+ .picker-button__content_1g1ys {
22
22
  overflow: hidden;
23
23
  flex: 1;
24
24
  text-overflow: ellipsis;
@@ -1,4 +1,4 @@
1
1
  export { Option } from './Component.js';
2
- import '../tslib.es6-46fd1a84.js';
2
+ import '../tslib.es6-b7613d2d.js';
3
3
  import 'react';
4
4
  import '@alfalab/core-components-select/esm';
package/esm/responsive.js CHANGED
@@ -1,5 +1,5 @@
1
1
  export { PickerButtonResponsive } from './Component.responsive.js';
2
- import './tslib.es6-46fd1a84.js';
2
+ import './tslib.es6-b7613d2d.js';
3
3
  import 'react';
4
4
  import '@alfalab/hooks';
5
5
  import './Component.js';
@@ -358,6 +358,46 @@ declare const FormControl: React.ForwardRefExoticComponent<React.HTMLAttributes<
358
358
  dataTestId?: string | undefined;
359
359
  children?: ReactNode;
360
360
  } & React.RefAttributes<HTMLDivElement>>;
361
+ type BadgeProps = {
362
+ /**
363
+ * Дополнительный класс
364
+ */
365
+ className?: string;
366
+ /**
367
+ * Вид компонента
368
+ */
369
+ view: "icon" | "count";
370
+ /**
371
+ * Размер компонента (только для view=icon)
372
+ * //deprecated(используйте height для view=count )
373
+ */
374
+ size?: "s" | "m" | "l" | "xl";
375
+ /**
376
+ * Видимость белой обводки вокруг иконки
377
+ */
378
+ visibleIconOutline?: boolean;
379
+ /**
380
+ * Видимость цветной обводки вокруг иконки (только для view=icon)
381
+ */
382
+ visibleColorOutline?: boolean;
383
+ /**
384
+ * Контент компонента
385
+ */
386
+ content?: React.ReactElement | number;
387
+ /**
388
+ * Высота компонента, min = 16; max = 48 (только для view=count)
389
+ */
390
+ height?: number;
391
+ /**
392
+ * Цветовое оформление иконки
393
+ */
394
+ iconColor?: "positive" | "attention" | "link" | "negative" | "tertiary" | "secondary" | "primary";
395
+ /**
396
+ * Идентификатор для систем автоматизированного тестирования
397
+ */
398
+ dataTestId?: string;
399
+ };
400
+ declare const Badge: ({ className, size, view, visibleIconOutline, visibleColorOutline, content, height, iconColor, dataTestId }: BadgeProps) => JSX.Element;
361
401
  type PortalProps = {
362
402
  /** Контент */
363
403
  children?: ReactNode;
@@ -948,4 +988,4 @@ type CheckmarkProps = {
948
988
  */
949
989
  icon?: React.FC<React.SVGProps<SVGSVGElement>>;
950
990
  };
951
- export { InputProps, Input, Position, PopoverProps, Popover, FormControlProps, FormControl, PortalProps, Portal, stackingOrder, StackingContext, StackProps, Stack, PORTAL_CONTAINER_ATTRIBUTE, getDefaultPortalContainer, setRef, OptionShape, GroupShape, BaseSelectChangePayload, BaseSelectProps, FieldProps, ArrowProps, OptionsListProps, OptgroupProps, OptionProps, CheckmarkProps };
991
+ export { InputProps, Input, Position, PopoverProps, Popover, FormControlProps, FormControl, BadgeProps, Badge, PortalProps, Portal, stackingOrder, StackingContext, StackProps, Stack, PORTAL_CONTAINER_ATTRIBUTE, getDefaultPortalContainer, setRef, OptionShape, GroupShape, BaseSelectChangePayload, BaseSelectProps, FieldProps, ArrowProps, OptionsListProps, OptgroupProps, OptionProps, CheckmarkProps };
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var tslib_es6 = require('../tslib.es6-287864ca.js');
3
+ var tslib_es6 = require('../tslib.es6-5a652c21.js');
4
4
  var React = require('react');
5
5
  var cn = require('classnames');
6
6
  var coreComponentsButton = require('@alfalab/core-components-button');
@@ -15,7 +15,7 @@ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'defau
15
15
  var React__default = /*#__PURE__*/_interopDefaultCompat(React);
16
16
  var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
17
17
 
18
- var styles = {"iconContainer":"picker-button__iconContainer_1l79r","addonsContainer":"picker-button__addonsContainer_1l79r","open":"picker-button__open_1l79r"};
18
+ var styles = {"iconContainer":"picker-button__iconContainer_dvipe","addonsContainer":"picker-button__addonsContainer_dvipe","open":"picker-button__open_dvipe"};
19
19
  require('./index.css')
20
20
 
21
21
  var Field = function (_a) {
package/field/index.css CHANGED
@@ -1,4 +1,4 @@
1
- /* hash: lq5s9 */
1
+ /* hash: 20dyo */
2
2
  :root {
3
3
 
4
4
  /* Hard */
@@ -13,14 +13,14 @@
13
13
  :root {
14
14
  --arrow-transform: rotate(180deg);
15
15
  }
16
- .picker-button__iconContainer_1l79r {
16
+ .picker-button__iconContainer_dvipe {
17
17
  display: flex;
18
18
  transition: transform 0.15s ease-in-out;
19
19
  }
20
- .picker-button__addonsContainer_1l79r {
20
+ .picker-button__addonsContainer_dvipe {
21
21
  display: flex;
22
22
  margin-right: var(--gap-2xs);
23
23
  }
24
- .picker-button__open_1l79r {
24
+ .picker-button__open_dvipe {
25
25
  transform: var(--arrow-transform);
26
26
  }
package/field/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var field_Component = require('./Component.js');
4
- require('../tslib.es6-287864ca.js');
4
+ require('../tslib.es6-5a652c21.js');
5
5
  require('react');
6
6
  require('classnames');
7
7
  require('@alfalab/core-components-button');
package/index.css CHANGED
@@ -1,4 +1,4 @@
1
- /* hash: hja1p */
1
+ /* hash: cb0x3 */
2
2
  :root {
3
3
 
4
4
  /* Hard */
@@ -15,22 +15,22 @@
15
15
  :root {
16
16
  --border-radius-m: 8px;
17
17
  }
18
- .picker-button__container_ygp5q {
18
+ .picker-button__container_4p9wi {
19
19
  min-width: auto;
20
20
  }
21
- .cc-picker-button.picker-button__optionsPopover_ygp5q {
21
+ .cc-picker-button.picker-button__optionsPopover_4p9wi {
22
22
  padding: var(--gap-2xs) 0
23
23
  }
24
- .cc-picker-button.picker-button__optionsPopover_ygp5q.picker-button__sideGap_ygp5q {
24
+ .cc-picker-button.picker-button__optionsPopover_4p9wi.picker-button__sideGap_4p9wi {
25
25
  padding: 0 var(--gap-xs);
26
26
  }
27
- .cc-picker-button .picker-button__optionsListContainer_ygp5q {
27
+ .cc-picker-button .picker-button__optionsListContainer_4p9wi {
28
28
  border-radius: var(--border-radius-m);
29
29
  }
30
- .cc-picker-button .picker-button__option_ygp5q {
30
+ .cc-picker-button .picker-button__option_4p9wi {
31
31
  padding: 0 var(--gap-m)
32
32
  }
33
- .cc-picker-button .picker-button__option_ygp5q:before {
33
+ .cc-picker-button .picker-button__option_4p9wi:before {
34
34
  /* Удаляем разделители у опций выпадающего списка. */
35
35
  display: none;
36
36
  }
package/index.d.ts CHANGED
@@ -1,2 +1,3 @@
1
- export { PickerButtonResponsive as PickerButton, PickerButtonResponsiveProps as PickerButtonProps } from "./responsive";
2
- export { PickerButtonDesktopProps, PickerButtonSize, PickerButtonVariant } from "./Component";
1
+ export { PickerButtonResponsive as PickerButton } from "./responsive";
2
+ export type { PickerButtonResponsiveProps as PickerButtonProps } from "./responsive";
3
+ export type { PickerButtonDesktopProps, PickerButtonSize, PickerButtonVariant } from "./Component";
package/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var Component_responsive = require('./Component.responsive.js');
4
- require('./tslib.es6-287864ca.js');
4
+ require('./tslib.es6-5a652c21.js');
5
5
  require('react');
6
6
  require('@alfalab/hooks');
7
7
  require('./Component.js');
package/mobile.js CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var Component_mobile = require('./Component.mobile.js');
4
- require('./tslib.es6-287864ca.js');
4
+ require('./tslib.es6-5a652c21.js');
5
5
  require('react');
6
6
  require('@alfalab/core-components-select');
7
7
  require('./field/Component.js');
@@ -10,7 +10,7 @@ import '@alfalab/icons-glyph/ChevronDownMIcon';
10
10
  import '@alfalab/icons-glyph/MoreMIcon';
11
11
  import '@alfalab/icons-glyph/MoreSIcon';
12
12
 
13
- const styles = {"container":"picker-button__container_ygp5q","optionsPopover":"picker-button__optionsPopover_ygp5q","sideGap":"picker-button__sideGap_ygp5q","optionsListContainer":"picker-button__optionsListContainer_ygp5q","option":"picker-button__option_ygp5q"};
13
+ const styles = {"container":"picker-button__container_4p9wi","optionsPopover":"picker-button__optionsPopover_4p9wi","sideGap":"picker-button__sideGap_4p9wi","optionsListContainer":"picker-button__optionsListContainer_4p9wi","option":"picker-button__option_4p9wi"};
14
14
  require('./index.css')
15
15
 
16
16
  const SIDE_POSITIONS = ['right', 'right-start', 'right-end', 'left', 'left-start', 'left-end'];
@@ -7,7 +7,7 @@ import '@alfalab/icons-glyph/ChevronDownMIcon';
7
7
  import '@alfalab/icons-glyph/MoreMIcon';
8
8
  import '@alfalab/icons-glyph/MoreSIcon';
9
9
 
10
- const styles = {"iconContainer":"picker-button__iconContainer_1l79r","addonsContainer":"picker-button__addonsContainer_1l79r","open":"picker-button__open_1l79r"};
10
+ const styles = {"iconContainer":"picker-button__iconContainer_dvipe","addonsContainer":"picker-button__addonsContainer_dvipe","open":"picker-button__open_dvipe"};
11
11
  require('./index.css')
12
12
 
13
13
  const Field = ({ buttonSize = 'm', buttonVariant = 'default', view, label, open, multiple, rightAddons, Arrow, innerProps, className, selected, selectedMultiple, setSelectedItems, toggleMenu, valueRenderer, ...restProps }) => {
@@ -1,4 +1,4 @@
1
- /* hash: lq5s9 */
1
+ /* hash: 20dyo */
2
2
  :root {
3
3
 
4
4
  /* Hard */
@@ -13,14 +13,14 @@
13
13
  :root {
14
14
  --arrow-transform: rotate(180deg);
15
15
  }
16
- .picker-button__iconContainer_1l79r {
16
+ .picker-button__iconContainer_dvipe {
17
17
  display: flex;
18
18
  transition: transform 0.15s ease-in-out;
19
19
  }
20
- .picker-button__addonsContainer_1l79r {
20
+ .picker-button__addonsContainer_dvipe {
21
21
  display: flex;
22
22
  margin-right: var(--gap-2xs);
23
23
  }
24
- .picker-button__open_1l79r {
24
+ .picker-button__open_dvipe {
25
25
  transform: var(--arrow-transform);
26
26
  }
package/modern/index.css CHANGED
@@ -1,4 +1,4 @@
1
- /* hash: hja1p */
1
+ /* hash: cb0x3 */
2
2
  :root {
3
3
 
4
4
  /* Hard */
@@ -15,22 +15,22 @@
15
15
  :root {
16
16
  --border-radius-m: 8px;
17
17
  }
18
- .picker-button__container_ygp5q {
18
+ .picker-button__container_4p9wi {
19
19
  min-width: auto;
20
20
  }
21
- .cc-picker-button.picker-button__optionsPopover_ygp5q {
21
+ .cc-picker-button.picker-button__optionsPopover_4p9wi {
22
22
  padding: var(--gap-2xs) 0
23
23
  }
24
- .cc-picker-button.picker-button__optionsPopover_ygp5q.picker-button__sideGap_ygp5q {
24
+ .cc-picker-button.picker-button__optionsPopover_4p9wi.picker-button__sideGap_4p9wi {
25
25
  padding: 0 var(--gap-xs);
26
26
  }
27
- .cc-picker-button .picker-button__optionsListContainer_ygp5q {
27
+ .cc-picker-button .picker-button__optionsListContainer_4p9wi {
28
28
  border-radius: var(--border-radius-m);
29
29
  }
30
- .cc-picker-button .picker-button__option_ygp5q {
30
+ .cc-picker-button .picker-button__option_4p9wi {
31
31
  padding: 0 var(--gap-m)
32
32
  }
33
- .cc-picker-button .picker-button__option_ygp5q:before {
33
+ .cc-picker-button .picker-button__option_4p9wi:before {
34
34
  /* Удаляем разделители у опций выпадающего списка. */
35
35
  display: none;
36
36
  }
package/modern/index.d.ts CHANGED
@@ -1,2 +1,3 @@
1
- export { PickerButtonResponsive as PickerButton, PickerButtonResponsiveProps as PickerButtonProps } from "./responsive";
2
- export { PickerButtonDesktopProps, PickerButtonSize, PickerButtonVariant } from "./Component";
1
+ export { PickerButtonResponsive as PickerButton } from "./responsive";
2
+ export type { PickerButtonResponsiveProps as PickerButtonProps } from "./responsive";
3
+ export type { PickerButtonDesktopProps, PickerButtonSize, PickerButtonVariant } from "./Component";
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import { Option as Option$1 } from '@alfalab/core-components-select/modern';
3
3
 
4
- const styles = {"container":"picker-button__container_1cb5l","icon":"picker-button__icon_1cb5l","content":"picker-button__content_1cb5l"};
4
+ const styles = {"container":"picker-button__container_1g1ys","icon":"picker-button__icon_1g1ys","content":"picker-button__content_1g1ys"};
5
5
  require('./index.css')
6
6
 
7
7
  const Option = ({ option, children, ...restProps }) => {
@@ -1,4 +1,4 @@
1
- /* hash: 1uq5f */
1
+ /* hash: 1phwa */
2
2
  :root {
3
3
 
4
4
  /* Hard */
@@ -10,15 +10,15 @@
10
10
  :root {
11
11
  --gap-s: 12px;
12
12
  }
13
- .picker-button__container_1cb5l {
13
+ .picker-button__container_1g1ys {
14
14
  display: flex;
15
15
  align-items: center;
16
16
  }
17
- .picker-button__icon_1cb5l {
17
+ .picker-button__icon_1g1ys {
18
18
  display: flex;
19
19
  margin-right: var(--gap-s);
20
20
  }
21
- .picker-button__content_1cb5l {
21
+ .picker-button__content_1g1ys {
22
22
  overflow: hidden;
23
23
  flex: 1;
24
24
  text-overflow: ellipsis;
@@ -358,6 +358,46 @@ declare const FormControl: React.ForwardRefExoticComponent<React.HTMLAttributes<
358
358
  dataTestId?: string | undefined;
359
359
  children?: ReactNode;
360
360
  } & React.RefAttributes<HTMLDivElement>>;
361
+ type BadgeProps = {
362
+ /**
363
+ * Дополнительный класс
364
+ */
365
+ className?: string;
366
+ /**
367
+ * Вид компонента
368
+ */
369
+ view: "icon" | "count";
370
+ /**
371
+ * Размер компонента (только для view=icon)
372
+ * //deprecated(используйте height для view=count )
373
+ */
374
+ size?: "s" | "m" | "l" | "xl";
375
+ /**
376
+ * Видимость белой обводки вокруг иконки
377
+ */
378
+ visibleIconOutline?: boolean;
379
+ /**
380
+ * Видимость цветной обводки вокруг иконки (только для view=icon)
381
+ */
382
+ visibleColorOutline?: boolean;
383
+ /**
384
+ * Контент компонента
385
+ */
386
+ content?: React.ReactElement | number;
387
+ /**
388
+ * Высота компонента, min = 16; max = 48 (только для view=count)
389
+ */
390
+ height?: number;
391
+ /**
392
+ * Цветовое оформление иконки
393
+ */
394
+ iconColor?: "positive" | "attention" | "link" | "negative" | "tertiary" | "secondary" | "primary";
395
+ /**
396
+ * Идентификатор для систем автоматизированного тестирования
397
+ */
398
+ dataTestId?: string;
399
+ };
400
+ declare const Badge: ({ className, size, view, visibleIconOutline, visibleColorOutline, content, height, iconColor, dataTestId }: BadgeProps) => JSX.Element;
361
401
  type PortalProps = {
362
402
  /** Контент */
363
403
  children?: ReactNode;
@@ -948,4 +988,4 @@ type CheckmarkProps = {
948
988
  */
949
989
  icon?: React.FC<React.SVGProps<SVGSVGElement>>;
950
990
  };
951
- export { InputProps, Input, Position, PopoverProps, Popover, FormControlProps, FormControl, PortalProps, Portal, stackingOrder, StackingContext, StackProps, Stack, PORTAL_CONTAINER_ATTRIBUTE, getDefaultPortalContainer, setRef, OptionShape, GroupShape, BaseSelectChangePayload, BaseSelectProps, FieldProps, ArrowProps, OptionsListProps, OptgroupProps, OptionProps, CheckmarkProps };
991
+ export { InputProps, Input, Position, PopoverProps, Popover, FormControlProps, FormControl, BadgeProps, Badge, PortalProps, Portal, stackingOrder, StackingContext, StackProps, Stack, PORTAL_CONTAINER_ATTRIBUTE, getDefaultPortalContainer, setRef, OptionShape, GroupShape, BaseSelectChangePayload, BaseSelectProps, FieldProps, ArrowProps, OptionsListProps, OptgroupProps, OptionProps, CheckmarkProps };
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var tslib_es6 = require('../tslib.es6-287864ca.js');
3
+ var tslib_es6 = require('../tslib.es6-5a652c21.js');
4
4
  var React = require('react');
5
5
  var coreComponentsSelect = require('@alfalab/core-components-select');
6
6
 
@@ -8,7 +8,7 @@ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'defau
8
8
 
9
9
  var React__default = /*#__PURE__*/_interopDefaultCompat(React);
10
10
 
11
- var styles = {"container":"picker-button__container_1cb5l","icon":"picker-button__icon_1cb5l","content":"picker-button__content_1cb5l"};
11
+ var styles = {"container":"picker-button__container_1g1ys","icon":"picker-button__icon_1g1ys","content":"picker-button__content_1g1ys"};
12
12
  require('./index.css')
13
13
 
14
14
  var Option = function (_a) {
package/option/index.css CHANGED
@@ -1,4 +1,4 @@
1
- /* hash: 1uq5f */
1
+ /* hash: 1phwa */
2
2
  :root {
3
3
 
4
4
  /* Hard */
@@ -10,15 +10,15 @@
10
10
  :root {
11
11
  --gap-s: 12px;
12
12
  }
13
- .picker-button__container_1cb5l {
13
+ .picker-button__container_1g1ys {
14
14
  display: flex;
15
15
  align-items: center;
16
16
  }
17
- .picker-button__icon_1cb5l {
17
+ .picker-button__icon_1g1ys {
18
18
  display: flex;
19
19
  margin-right: var(--gap-s);
20
20
  }
21
- .picker-button__content_1cb5l {
21
+ .picker-button__content_1g1ys {
22
22
  overflow: hidden;
23
23
  flex: 1;
24
24
  text-overflow: ellipsis;
package/option/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var option_Component = require('./Component.js');
4
- require('../tslib.es6-287864ca.js');
4
+ require('../tslib.es6-5a652c21.js');
5
5
  require('react');
6
6
  require('@alfalab/core-components-select');
7
7
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfalab/core-components-picker-button",
3
- "version": "10.2.0",
3
+ "version": "10.2.1",
4
4
  "description": "Picker button component",
5
5
  "keywords": [],
6
6
  "license": "MIT",
@@ -19,7 +19,7 @@
19
19
  },
20
20
  "dependencies": {
21
21
  "@alfalab/core-components-button": "^7.0.2",
22
- "@alfalab/core-components-select": "^13.2.3",
22
+ "@alfalab/core-components-select": "^13.2.4",
23
23
  "@alfalab/icons-classic": "^2.3.0",
24
24
  "@alfalab/icons-glyph": "^2.71.0",
25
25
  "classnames": "^2.3.1"
package/responsive.js CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var Component_responsive = require('./Component.responsive.js');
4
- require('./tslib.es6-287864ca.js');
4
+ require('./tslib.es6-5a652c21.js');
5
5
  require('react');
6
6
  require('@alfalab/hooks');
7
7
  require('./Component.js');
File without changes
@@ -124,7 +124,7 @@ type InputProps = Omit<InputHTMLAttributes<HTMLInputElement>, "size" | "type" |
124
124
  */
125
125
  dataTestId?: string;
126
126
  };
127
- declare const Input: React.ForwardRefExoticComponent<Omit<React.InputHTMLAttributes<HTMLInputElement>, "size" | "type" | "defaultValue" | "onChange" | "onClick" | "onMouseDown" | "value" | "enterKeyHint"> & {
127
+ declare const Input: React.ForwardRefExoticComponent<Omit<React.InputHTMLAttributes<HTMLInputElement>, "size" | "defaultValue" | "onChange" | "onClick" | "onMouseDown" | "type" | "value" | "enterKeyHint"> & {
128
128
  value?: string | undefined;
129
129
  defaultValue?: string | undefined;
130
130
  block?: boolean | undefined;
@@ -358,6 +358,46 @@ declare const FormControl: React.ForwardRefExoticComponent<React.HTMLAttributes<
358
358
  dataTestId?: string | undefined;
359
359
  children?: ReactNode;
360
360
  } & React.RefAttributes<HTMLDivElement>>;
361
+ type BadgeProps = {
362
+ /**
363
+ * Дополнительный класс
364
+ */
365
+ className?: string;
366
+ /**
367
+ * Вид компонента
368
+ */
369
+ view: "icon" | "count";
370
+ /**
371
+ * Размер компонента (только для view=icon)
372
+ * //deprecated(используйте height для view=count )
373
+ */
374
+ size?: "s" | "m" | "l" | "xl";
375
+ /**
376
+ * Видимость белой обводки вокруг иконки
377
+ */
378
+ visibleIconOutline?: boolean;
379
+ /**
380
+ * Видимость цветной обводки вокруг иконки (только для view=icon)
381
+ */
382
+ visibleColorOutline?: boolean;
383
+ /**
384
+ * Контент компонента
385
+ */
386
+ content?: React.ReactElement | number;
387
+ /**
388
+ * Высота компонента, min = 16; max = 48 (только для view=count)
389
+ */
390
+ height?: number;
391
+ /**
392
+ * Цветовое оформление иконки
393
+ */
394
+ iconColor?: "positive" | "attention" | "link" | "negative" | "tertiary" | "secondary" | "primary";
395
+ /**
396
+ * Идентификатор для систем автоматизированного тестирования
397
+ */
398
+ dataTestId?: string;
399
+ };
400
+ declare const Badge: ({ className, size, view, visibleIconOutline, visibleColorOutline, content, height, iconColor, dataTestId }: BadgeProps) => JSX.Element;
361
401
  type PortalProps = {
362
402
  /** Контент */
363
403
  children?: ReactNode;
@@ -948,4 +988,4 @@ type CheckmarkProps = {
948
988
  */
949
989
  icon?: React.FC<React.SVGProps<SVGSVGElement>>;
950
990
  };
951
- export { InputProps, Input, Position, PopoverProps, Popover, FormControlProps, FormControl, PortalProps, Portal, stackingOrder, StackingContext, StackProps, Stack, PORTAL_CONTAINER_ATTRIBUTE, getDefaultPortalContainer, setRef, OptionShape, GroupShape, BaseSelectChangePayload, BaseSelectProps, FieldProps, ArrowProps, OptionsListProps, OptgroupProps, OptionProps, CheckmarkProps };
991
+ export { InputProps, Input, Position, PopoverProps, Popover, FormControlProps, FormControl, BadgeProps, Badge, PortalProps, Portal, stackingOrder, StackingContext, StackProps, Stack, PORTAL_CONTAINER_ATTRIBUTE, getDefaultPortalContainer, setRef, OptionShape, GroupShape, BaseSelectChangePayload, BaseSelectProps, FieldProps, ArrowProps, OptionsListProps, OptgroupProps, OptionProps, CheckmarkProps };