Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(steps): make checkIsStepCustom's return value nullable #738

Merged
merged 4 commits into from
Jul 18, 2023
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/clean-carrots-judge.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@alfalab/core-components-steps": patch
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Это минорка

---

fix(steps): make checkIsStepCustom's return value nullable
4 changes: 2 additions & 2 deletions packages/steps/src/Component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,9 @@ export type StepsProps = {
/**
* Кастомный метод для установки кастомного индикатора шага
* @param stepNumber - номер шага
* @return Объект StepIndicatorProps { className, content, iconColor }
* @return Объект StepIndicatorProps { className, content, iconColor } или null
*/
checkIsStepCustom?: (stepNumber: number) => StepIndicatorProps;
checkIsStepCustom?: (stepNumber: number) => StepIndicatorProps | null;

/**
* Обработчик клика на шаг
Expand Down
2 changes: 1 addition & 1 deletion packages/steps/src/components/step/Component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export type StepProps = {
/**
* Свойства кастомного индикатора текущего шага
*/
customStepIndicator?: StepIndicatorProps;
customStepIndicator?: StepIndicatorProps | null;

/**
* Управление ориентацией компонента
Expand Down
Loading