@astral/ui 1.28.5 → 1.28.8
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/DatePicker/MonthPicker/hooks/useMonthsGrid/useMonthsGrid.js +1 -1
- package/Fab/Fab.js +2 -2
- package/FormHelperText/FormHelperTextContent/styles.js +3 -0
- package/esm/DatePicker/MonthPicker/hooks/useMonthsGrid/useMonthsGrid.js +1 -1
- package/esm/Fab/Fab.js +2 -2
- package/esm/FormHelperText/FormHelperTextContent/styles.js +3 -0
- package/package.json +2 -2
|
@@ -20,7 +20,7 @@ const useMonthsGrid = ({ baseDate, selectedDate, }) => {
|
|
|
20
20
|
for (let i = 0; i < counts_1.MONTHS_IN_YEAR; i++) {
|
|
21
21
|
const date = (0, date_1.buildIsoDate)({ year, month: i + 1 });
|
|
22
22
|
grid.push({
|
|
23
|
-
date
|
|
23
|
+
date,
|
|
24
24
|
selected: selectedMonth === i && selectedYear === year,
|
|
25
25
|
month: i + 1,
|
|
26
26
|
isCurrent: i === currentMonth && year === currentYear,
|
package/Fab/Fab.js
CHANGED
|
@@ -16,7 +16,7 @@ const jsx_runtime_1 = require("react/jsx-runtime");
|
|
|
16
16
|
const react_1 = require("react");
|
|
17
17
|
const styles_1 = require("./styles");
|
|
18
18
|
const enums_1 = require("./enums");
|
|
19
|
-
exports.Fab = (0, react_1.forwardRef)((_a) => {
|
|
20
|
-
var {
|
|
19
|
+
exports.Fab = (0, react_1.forwardRef)((_a, ref) => {
|
|
20
|
+
var { variant = 'square', size = enums_1.FabSizes.Large, color = 'primary' } = _a, props = __rest(_a, ["variant", "size", "color"]);
|
|
21
21
|
return ((0, jsx_runtime_1.jsx)(styles_1.StyledFab, Object.assign({}, props, { variant: variant === 'square' ? 'circular' : variant, isSquare: variant === 'square', size: size, color: color, ref: ref })));
|
|
22
22
|
});
|
|
@@ -9,7 +9,10 @@ const getStyles = (theme) => {
|
|
|
9
9
|
font-size: ${theme.typography.h5.fontSize};
|
|
10
10
|
vertical-align: middle;`;
|
|
11
11
|
};
|
|
12
|
+
// flex необходим, для того, чтобы span не менял высоту полей и имел фиксированную высоту в 16px
|
|
12
13
|
exports.FormHelperTextWrapper = styles_1.styled.span `
|
|
14
|
+
display: flex;
|
|
15
|
+
|
|
13
16
|
color: ${({ success, error, theme }) => {
|
|
14
17
|
if (success) {
|
|
15
18
|
return theme.palette.success.dark;
|
|
@@ -17,7 +17,7 @@ export const useMonthsGrid = ({ baseDate, selectedDate, }) => {
|
|
|
17
17
|
for (let i = 0; i < MONTHS_IN_YEAR; i++) {
|
|
18
18
|
const date = buildIsoDate({ year, month: i + 1 });
|
|
19
19
|
grid.push({
|
|
20
|
-
date
|
|
20
|
+
date,
|
|
21
21
|
selected: selectedMonth === i && selectedYear === year,
|
|
22
22
|
month: i + 1,
|
|
23
23
|
isCurrent: i === currentMonth && year === currentYear,
|
package/esm/Fab/Fab.js
CHANGED
|
@@ -13,7 +13,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
13
13
|
import { forwardRef } from 'react';
|
|
14
14
|
import { StyledFab } from './styles';
|
|
15
15
|
import { FabSizes } from './enums';
|
|
16
|
-
export const Fab = forwardRef((_a) => {
|
|
17
|
-
var {
|
|
16
|
+
export const Fab = forwardRef((_a, ref) => {
|
|
17
|
+
var { variant = 'square', size = FabSizes.Large, color = 'primary' } = _a, props = __rest(_a, ["variant", "size", "color"]);
|
|
18
18
|
return (_jsx(StyledFab, Object.assign({}, props, { variant: variant === 'square' ? 'circular' : variant, isSquare: variant === 'square', size: size, color: color, ref: ref })));
|
|
19
19
|
});
|
|
@@ -6,7 +6,10 @@ const getStyles = (theme) => {
|
|
|
6
6
|
font-size: ${theme.typography.h5.fontSize};
|
|
7
7
|
vertical-align: middle;`;
|
|
8
8
|
};
|
|
9
|
+
// flex необходим, для того, чтобы span не менял высоту полей и имел фиксированную высоту в 16px
|
|
9
10
|
export const FormHelperTextWrapper = styled.span `
|
|
11
|
+
display: flex;
|
|
12
|
+
|
|
10
13
|
color: ${({ success, error, theme }) => {
|
|
11
14
|
if (success) {
|
|
12
15
|
return theme.palette.success.dark;
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@astral/ui",
|
|
3
|
-
"version": "1.28.
|
|
3
|
+
"version": "1.28.8",
|
|
4
4
|
"browser": "./esm/index.js",
|
|
5
5
|
"main": "./index.js",
|
|
6
6
|
"dependencies": {
|
|
7
|
-
"@astral/icons": "^1.28.
|
|
7
|
+
"@astral/icons": "^1.28.8",
|
|
8
8
|
"@emotion/cache": "11.7.1",
|
|
9
9
|
"@emotion/react": "11.9.0",
|
|
10
10
|
"@emotion/server": "11.4.0",
|