WIP Адаптировала карточки под календарь

This commit is contained in:
Daria Golova
2023-06-26 18:03:05 +03:00
parent acf91a938f
commit 8f6ca8e437
6 changed files with 212 additions and 24 deletions

View File

@@ -1,3 +1,9 @@
export function convertTime(str, startIndex, endIndex) {
return parseInt(str?.slice(startIndex, endIndex), 10);
}
export function trimName(lastName, firstName, patronymic) {
let checkedFirstName = firstName !== null ? firstName[0] + ". " : "";
let checkedPatronymic = patronymic !== null ? patronymic[0] + "." : "";
return `${lastName} ${checkedFirstName}${checkedPatronymic}`;
}