@snack-uikit/fields 0.36.1 → 0.36.2

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.36.2 (2024-12-26)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **FF-5734:** eslint fixes ([5ce6f1f](https://github.com/cloud-ru-tech/snack-uikit/commit/5ce6f1f22d3ac3dd367cbdd184e5873e67837c8b))
12
+
13
+
14
+
15
+
16
+
6
17
  ## 0.36.1 (2024-12-25)
7
18
 
8
19
  ### Only dependencies have been changed
@@ -120,7 +120,7 @@ exports.FieldSecure = (0, react_1.forwardRef)((_a, ref) => {
120
120
  success: true,
121
121
  value: asyncValue
122
122
  };
123
- } catch (e) {
123
+ } catch (_a) {
124
124
  return {
125
125
  success: false
126
126
  };
@@ -22,7 +22,7 @@ export declare function extractAllChildIds({ items }: {
22
22
  items: ItemProps[];
23
23
  }): Array<string | number>;
24
24
  /**
25
- *  Функция разворачивает массив айтемов в плоский список
25
+ * Функция разворачивает массив айтемов в плоский список
26
26
  * @function flattenItems
27
27
  */
28
28
  export declare function flattenItems(items: ItemProps[]): (BaseItemProps | AccordionItemProps | NextListItemProps)[];
@@ -115,7 +115,7 @@ function extractAllChildIds(_ref3) {
115
115
  }, []);
116
116
  }
117
117
  /**
118
- *  Функция разворачивает массив айтемов в плоский список
118
+ * Функция разворачивает массив айтемов в плоский список
119
119
  * @function flattenItems
120
120
  */
121
121
  function flattenItems(items) {
@@ -61,10 +61,7 @@ function parseDate(value) {
61
61
  month = DATE_STUB.getMonth();
62
62
  day = DATE_STUB.getDay();
63
63
  }
64
- const [hours = 0, minutes = 0, seconds = 0] = time.split(':').map(str => {
65
- var _a;
66
- return (_a = Number(str)) !== null && _a !== void 0 ? _a : 0;
67
- });
64
+ const [hours = 0, minutes = 0, seconds = 0] = time.split(':').map(str => Number(str !== null && str !== void 0 ? str : 0));
68
65
  return new Date(year, month, day, hours, minutes, seconds);
69
66
  }
70
67
  return new Date(year, month, day);
@@ -61,7 +61,7 @@ export const FieldSecure = forwardRef((_a, ref) => {
61
61
  value: asyncValue,
62
62
  };
63
63
  }
64
- catch (e) {
64
+ catch (_a) {
65
65
  return {
66
66
  success: false,
67
67
  };
@@ -22,7 +22,7 @@ export declare function extractAllChildIds({ items }: {
22
22
  items: ItemProps[];
23
23
  }): Array<string | number>;
24
24
  /**
25
- *  Функция разворачивает массив айтемов в плоский список
25
+ * Функция разворачивает массив айтемов в плоский список
26
26
  * @function flattenItems
27
27
  */
28
28
  export declare function flattenItems(items: ItemProps[]): (BaseItemProps | AccordionItemProps | NextListItemProps)[];
@@ -85,7 +85,7 @@ export function extractAllChildIds({ items }) {
85
85
  }, []);
86
86
  }
87
87
  /**
88
- *  Функция разворачивает массив айтемов в плоский список
88
+ * Функция разворачивает массив айтемов в плоский список
89
89
  * @function flattenItems
90
90
  */
91
91
  export function flattenItems(items) {
@@ -52,7 +52,7 @@ export function parseDate(value) {
52
52
  month = DATE_STUB.getMonth();
53
53
  day = DATE_STUB.getDay();
54
54
  }
55
- const [hours = 0, minutes = 0, seconds = 0] = time.split(':').map(str => { var _a; return (_a = Number(str)) !== null && _a !== void 0 ? _a : 0; });
55
+ const [hours = 0, minutes = 0, seconds = 0] = time.split(':').map(str => Number(str !== null && str !== void 0 ? str : 0));
56
56
  return new Date(year, month, day, hours, minutes, seconds);
57
57
  }
58
58
  return new Date(year, month, day);
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "access": "public"
5
5
  },
6
6
  "title": "Fields",
7
- "version": "0.36.1",
7
+ "version": "0.36.2",
8
8
  "sideEffects": [
9
9
  "*.css",
10
10
  "*.woff",
@@ -37,19 +37,19 @@
37
37
  "scripts": {},
38
38
  "dependencies": {
39
39
  "@snack-uikit/button": "0.19.5",
40
- "@snack-uikit/calendar": "0.11.13",
41
- "@snack-uikit/color-picker": "0.3.9",
40
+ "@snack-uikit/calendar": "0.11.14",
41
+ "@snack-uikit/color-picker": "0.3.10",
42
42
  "@snack-uikit/divider": "3.2.2",
43
43
  "@snack-uikit/dropdown": "0.4.2",
44
44
  "@snack-uikit/icons": "0.24.1",
45
45
  "@snack-uikit/input-private": "4.5.0",
46
- "@snack-uikit/list": "0.22.1",
46
+ "@snack-uikit/list": "0.22.2",
47
47
  "@snack-uikit/scroll": "0.9.2",
48
48
  "@snack-uikit/skeleton": "0.6.1",
49
- "@snack-uikit/slider": "0.3.3",
49
+ "@snack-uikit/slider": "0.3.4",
50
50
  "@snack-uikit/tag": "0.12.1",
51
- "@snack-uikit/tooltip": "0.15.2",
52
- "@snack-uikit/truncate-string": "0.6.3",
51
+ "@snack-uikit/tooltip": "0.15.3",
52
+ "@snack-uikit/truncate-string": "0.6.4",
53
53
  "@snack-uikit/utils": "3.6.0",
54
54
  "classnames": "2.5.1",
55
55
  "copy-to-clipboard": "3.3.3",
@@ -65,5 +65,5 @@
65
65
  "peerDependencies": {
66
66
  "@snack-uikit/locale": "*"
67
67
  },
68
- "gitHead": "5f981cd3d7c5169db2bff1d58db36b6c83da6861"
68
+ "gitHead": "33621b09b3ca6d177fd8f41e5516566dee9f416a"
69
69
  }
@@ -40,7 +40,6 @@ export function Header({
40
40
  <span className={styles.header} data-size={size}>
41
41
  {label && (
42
42
  <span className={styles.labelLayout}>
43
- {/* eslint-disable-next-line jsx-a11y/label-has-associated-control */}
44
43
  <label className={styles.label} htmlFor={labelFor} data-test-id='field-decorator__label'>
45
44
  <TruncateString text={label} />
46
45
  </label>
@@ -133,7 +133,7 @@ export const FieldSecure = forwardRef<HTMLInputElement, FieldSecureProps>(
133
133
  success: true,
134
134
  value: asyncValue,
135
135
  };
136
- } catch (e) {
136
+ } catch {
137
137
  return {
138
138
  success: false,
139
139
  };
@@ -139,7 +139,7 @@ export function extractAllChildIds({ items }: { items: ItemProps[] }): Array<str
139
139
  }
140
140
 
141
141
  /**
142
- *  Функция разворачивает массив айтемов в плоский список
142
+ * Функция разворачивает массив айтемов в плоский список
143
143
  * @function flattenItems
144
144
  */
145
145
 
@@ -66,7 +66,7 @@ export function parseDate(value: string) {
66
66
  day = DATE_STUB.getDay();
67
67
  }
68
68
 
69
- const [hours = 0, minutes = 0, seconds = 0] = time.split(':').map(str => Number(str) ?? 0);
69
+ const [hours = 0, minutes = 0, seconds = 0] = time.split(':').map(str => Number(str ?? 0));
70
70
 
71
71
  return new Date(year, month, day, hours, minutes, seconds);
72
72
  }