Skip to content

Commit e4ca321

Browse files
committed
fix skills errors & ui fixes + chat main platform
1 parent e98cf89 commit e4ca321

25 files changed

Lines changed: 103 additions & 41 deletions

package-lock.json

Lines changed: 0 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@
4545
"class-transformer": "^0.5.1",
4646
"core-js": "^3.23.4",
4747
"dayjs": "^1.11.3",
48-
"file-saver": "^2.0.5",
4948
"fuse.js": "^6.6.2",
5049
"js-base64": "^3.7.7",
5150
"js-cookie": "^3.0.5",

projects/skills/src/app/skills/list/list.component.html

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,19 +17,25 @@
1717
@if (skills()) {
1818
<div class="list__items">
1919
@for (s of skills(); track $index) {
20-
<app-skill-card [skill]="s" (click)="onSkillClick(s.id)"></app-skill-card>
20+
<app-skill-card [skill]="s" (click)="onSkillClick(s.id, s.isFromTrajectory)"></app-skill-card>
2121
}
2222
</div>
2323
}
2424
</div>
2525

2626
<app-modal [open]="nonConfirmerModalOpen()">
2727
<div class="confirm">
28-
<h4 class="confirm__title text-heading-4">У вас нет активной подписки</h4>
28+
<h4 class="confirm__title text-heading-4">
29+
{{ isFromTrajectoryModal() ? "Этот навык из траектории" : "У вас нет активной подписки" }}
30+
</h4>
2931
<div class="cancel__confirm">
3032
<img alt="more image" src="assets\images\trajectories\more.svg" class="confirm__image" />
3133
<p class="text-body-12 cancel__subtext">
32-
Чтобы получить доступ ко всем возможностям платформы, оформите подписку прямо сейчас!
34+
{{
35+
isFromTrajectoryModal()
36+
? "Чтобы получить доступ к этому навыку выберите нужную траекторию или завершите выбранную ранее траекторию!"
37+
: "Чтобы получить доступ ко всем возможностям платформы, оформите подписку прямо сейчас!"
38+
}}
3339
</p>
3440

3541
<div class="cancel__buttons-group">
@@ -42,11 +48,11 @@ <h4 class="confirm__title text-heading-4">У вас нет активной по
4248
>
4349

4450
<app-button
45-
routerLink="/subscription"
51+
[routerLink]="isFromTrajectoryModal() ? '/trackCar' : '/subscription'"
4652
style="width: 100%"
4753
customTypographyClass="text-body-12"
4854
[color]="'primary'"
49-
>Купить</app-button
55+
>{{ isFromTrajectoryModal() ? "К траекториям" : "Купить" }}</app-button
5056
>
5157
</div>
5258
</div>

projects/skills/src/app/skills/list/list.component.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ export class SkillsListComponent implements OnInit, OnDestroy {
6060
subscriptionType = signal<SubscriptionData["lastSubscriptionType"]>(null);
6161

6262
nonConfirmerModalOpen = signal(false);
63+
isFromTrajectoryModal = signal(false);
6364

6465
ngOnInit(): void {
6566
const profileSub = this.profileService.getSubscriptionData().subscribe(r => {
@@ -94,10 +95,11 @@ export class SkillsListComponent implements OnInit, OnDestroy {
9495
this.skills.set(filteredSkills);
9596
}
9697

97-
onSkillClick(skillId: number) {
98+
onSkillClick(skillId: number, isFromTrajectory: boolean) {
9899
this.skillService.setSkillId(skillId);
99100
this.router.navigate(["skills", skillId]).catch(err => {
100101
if (err.status === 403) {
102+
this.isFromTrajectoryModal.set(isFromTrajectory);
101103
this.nonConfirmerModalOpen.set(true);
102104
}
103105
});

projects/skills/src/app/skills/shared/skill-card/skill-card.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@
2525
{{ skill.quantityOfLevels | pluralize: ["уровень", "уровня", "уровней"] }}
2626
</div>
2727

28-
@if (!skill.freeAccess) {
29-
<div class="skill-card__price text-body-12">Доступно в подписке PRO</div>
28+
@if (skill.requiresSubscription) {
29+
<div class="skill-card__price text-body-12">Доступно в подписке</div>
3030
} @if (skill.overdue) {
3131
<div class="skill-card__lost text-body-12">Просроченный навык</div>
3232
} @if(skill.isDone) {

projects/skills/src/models/skill.model.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ export interface Skill {
77
fileLink: string;
88
whoCreated: string;
99
description: string;
10+
isFromTrajectory: boolean;
11+
requiresSubscription: boolean;
1012
isDone: boolean;
1113
freeAccess: boolean;
1214
overdue?: boolean;

projects/social_platform/src/app/office/feed/filter/feed-filter.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ export class FeedFilterComponent implements OnInit, OnDestroy {
7373
filterOptions = [
7474
{ label: "Новости", value: "news" },
7575
{ label: "Вакансии", value: "vacancy" },
76-
{ label: "Новые проекты", value: "project" },
76+
{ label: "Новости проектов", value: "project" },
7777
];
7878

7979
includedFilters = signal<string[]>([]);

projects/social_platform/src/app/office/members/filters/members-filters.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
<app-autocomplete-input
1515
class="filter__autocomplete"
1616
[suggestions]="specsOptions()"
17-
[slimVersion]="true"
17+
[slimVersion]="false"
1818
fieldToDisplay="name"
1919
valueField="name"
2020
formControlName="speciality"
@@ -25,7 +25,7 @@
2525
<app-autocomplete-input
2626
class="filter__autocomplete"
2727
[suggestions]="skillsOptions()"
28-
[slimVersion]="true"
28+
[slimVersion]="false"
2929
fieldToDisplay="name"
3030
valueField="name"
3131
formControlName="keySkill"

projects/social_platform/src/app/office/members/filters/members-filters.component.scss

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
@use "styles/responsive";
2+
@use "styles/typography";
23

34
.filters {
45
display: flex;
@@ -67,8 +68,18 @@
6768
display: flex;
6869
gap: 10px;
6970
align-items: center;
70-
width: 168px;
71+
padding: 12px 20px;
72+
color: var(--black);
73+
background-color: var(--white);
74+
border: 1px solid var(--gray);
75+
border-radius: var(--rounded-lg);
76+
// width: 168px;
7177
font-size: 12px;
78+
79+
span {
80+
color: var(--dark-grey);
81+
@include typography.body-16;
82+
}
7283
}
7384

7485
&__autocomplete {

projects/social_platform/src/app/office/onboarding/stage-zero/stage-zero.component.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,11 @@ export class OnboardingStageZeroComponent implements OnInit, OnDestroy {
202202
{
203203
value: 2024,
204204
id: 24,
205+
label: "2024",
206+
},
207+
{
208+
value: 2025,
209+
id: 25,
205210
label: "н.в",
206211
},
207212
];

0 commit comments

Comments
 (0)