@snack-uikit/chips 0.20.2 → 0.21.0

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
@@ -3,6 +3,17 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # 0.21.0 (2024-11-14)
7
+
8
+
9
+ ### Features
10
+
11
+ * **FF-5827:** add scrollToSelectedItem prop ([bb57f81](https://github.com/cloud-ru-tech/snack-uikit/commit/bb57f81b3bd1c46f10c4de17a9284b47feb3e4b4))
12
+
13
+
14
+
15
+
16
+
6
17
  ## 0.20.2 (2024-11-14)
7
18
 
8
19
 
package/README.md CHANGED
@@ -154,6 +154,7 @@ import { PlaceholderSVG } from '@snack-uikit/icons';
154
154
  | searchable | `boolean` | - | |
155
155
  | footer | `ReactNode ;` | - | Кастомизируемый элемент в конце списка |
156
156
  | footerActiveElementsRefs | `RefObject<HTMLElement>[]` | - | Список ссылок на кастомные элементы, помещенные в специальную секцию внизу списка |
157
+ | scrollToSelectedItem | `boolean` | - | Флаг, отвещающий за прокручивание до выбранного элемента |
157
158
  | selection | `SelectionSingleState \| SelectionMultipleState` | - | |
158
159
  | scrollRef | `RefObject<HTMLElement>` | - | Ссылка на элемент, обозначающий самый конец прокручиваемого списка |
159
160
  | scrollContainerRef | `RefObject<HTMLElement>` | - | Ссылка на контейнер, который скроллится |
@@ -188,6 +189,7 @@ import { PlaceholderSVG } from '@snack-uikit/icons';
188
189
  | searchable | `boolean` | - | |
189
190
  | footer | `ReactNode ;` | - | Кастомизируемый элемент в конце списка |
190
191
  | footerActiveElementsRefs | `RefObject<HTMLElement>[]` | - | Список ссылок на кастомные элементы, помещенные в специальную секцию внизу списка |
192
+ | scrollToSelectedItem | `boolean` | - | Флаг, отвещающий за прокручивание до выбранного элемента |
191
193
  | selection | `SelectionSingleState \| SelectionMultipleState` | - | |
192
194
  | scrollRef | `RefObject<HTMLElement>` | - | Ссылка на элемент, обозначающий самый конец прокручиваемого списка |
193
195
  | scrollContainerRef | `RefObject<HTMLElement>` | - | Ссылка на контейнер, который скроллится |
@@ -59,7 +59,7 @@ export type ChipChoiceSelectCommonProps<T extends ContentRenderProps = ContentRe
59
59
  contentRenderProps?: T;
60
60
  }): boolean;
61
61
  searchable?: boolean;
62
- } & Pick<DroplistProps, 'selection' | 'scrollRef' | 'scrollContainerRef' | 'noDataState' | 'footer' | 'footerActiveElementsRefs' | 'dataError' | 'errorDataState' | 'dataFiltered' | 'noResultsState' | 'loading'>;
62
+ } & Pick<DroplistProps, 'selection' | 'scrollRef' | 'scrollContainerRef' | 'noDataState' | 'footer' | 'footerActiveElementsRefs' | 'dataError' | 'errorDataState' | 'dataFiltered' | 'noResultsState' | 'loading' | 'scrollToSelectedItem'>;
63
63
  export type ChipChoiceSingleProps<T extends ContentRenderProps = ContentRenderProps> = ChipChoiceSelectCommonProps<T> & Omit<SelectionSingleState, 'mode'> & {
64
64
  /** Массив опций */
65
65
  options: FilterOption<T>[];
@@ -59,7 +59,7 @@ export type ChipChoiceSelectCommonProps<T extends ContentRenderProps = ContentRe
59
59
  contentRenderProps?: T;
60
60
  }): boolean;
61
61
  searchable?: boolean;
62
- } & Pick<DroplistProps, 'selection' | 'scrollRef' | 'scrollContainerRef' | 'noDataState' | 'footer' | 'footerActiveElementsRefs' | 'dataError' | 'errorDataState' | 'dataFiltered' | 'noResultsState' | 'loading'>;
62
+ } & Pick<DroplistProps, 'selection' | 'scrollRef' | 'scrollContainerRef' | 'noDataState' | 'footer' | 'footerActiveElementsRefs' | 'dataError' | 'errorDataState' | 'dataFiltered' | 'noResultsState' | 'loading' | 'scrollToSelectedItem'>;
63
63
  export type ChipChoiceSingleProps<T extends ContentRenderProps = ContentRenderProps> = ChipChoiceSelectCommonProps<T> & Omit<SelectionSingleState, 'mode'> & {
64
64
  /** Массив опций */
65
65
  options: FilterOption<T>[];
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "access": "public"
5
5
  },
6
6
  "title": "Chips",
7
- "version": "0.20.2",
7
+ "version": "0.21.0",
8
8
  "sideEffects": [
9
9
  "*.css",
10
10
  "*.woff",
@@ -37,10 +37,10 @@
37
37
  "scripts": {},
38
38
  "dependencies": {
39
39
  "@snack-uikit/button": "0.19.3",
40
- "@snack-uikit/calendar": "0.11.5",
40
+ "@snack-uikit/calendar": "0.11.6",
41
41
  "@snack-uikit/dropdown": "0.4.1",
42
42
  "@snack-uikit/icons": "0.24.0",
43
- "@snack-uikit/list": "0.21.5",
43
+ "@snack-uikit/list": "0.21.6",
44
44
  "@snack-uikit/loaders": "0.8.1",
45
45
  "@snack-uikit/utils": "3.5.0",
46
46
  "classnames": "2.5.1",
@@ -54,5 +54,5 @@
54
54
  "peerDependencies": {
55
55
  "@snack-uikit/locale": "*"
56
56
  },
57
- "gitHead": "b9670e68c6af5fdd5dfceeae29ef3af8c89e5e6b"
57
+ "gitHead": "b126dc1e89fc5fc99b0e1c5f16d8dbefc370161c"
58
58
  }
@@ -110,6 +110,7 @@ export type ChipChoiceSelectCommonProps<T extends ContentRenderProps = ContentRe
110
110
  | 'dataFiltered'
111
111
  | 'noResultsState'
112
112
  | 'loading'
113
+ | 'scrollToSelectedItem'
113
114
  >;
114
115
 
115
116
  export type ChipChoiceSingleProps<T extends ContentRenderProps = ContentRenderProps> = ChipChoiceSelectCommonProps<T> &