l-min-components 1.0.377 → 1.0.379
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/package.json
CHANGED
|
@@ -58,12 +58,12 @@ const AppMainLayout = () => {
|
|
|
58
58
|
const cookie = cookies[i].trim();
|
|
59
59
|
if (cookie.startsWith(cookieName + "=")) {
|
|
60
60
|
cookieValue = cookie.substring(cookieName.length + 1);
|
|
61
|
-
setDefaultAcct(cookieValue)
|
|
61
|
+
setDefaultAcct(cookieValue);
|
|
62
62
|
break;
|
|
63
63
|
}
|
|
64
64
|
}
|
|
65
65
|
}, [defaultAcct]);
|
|
66
|
-
|
|
66
|
+
|
|
67
67
|
return (
|
|
68
68
|
<OutletContext.Provider
|
|
69
69
|
value={{
|
|
@@ -85,7 +85,8 @@ const AppMainLayout = () => {
|
|
|
85
85
|
setSelectedCourseId,
|
|
86
86
|
centerLayoutStyle,
|
|
87
87
|
setCenterLayoutStyle,
|
|
88
|
-
|
|
88
|
+
// return true if instructor affiliates is Active
|
|
89
|
+
affiliatesActive,
|
|
89
90
|
}}
|
|
90
91
|
>
|
|
91
92
|
<Layout
|
|
@@ -123,8 +124,8 @@ const AppMainLayout = () => {
|
|
|
123
124
|
</LeftLayout>
|
|
124
125
|
<CenterLayout isOpen={isOpen} style={centerLayoutStyle}>
|
|
125
126
|
{window.location.pathname.includes("instructor") && (
|
|
126
|
-
<InstructorAccountSwitcher />
|
|
127
|
-
)}
|
|
127
|
+
<InstructorAccountSwitcher setAccountType={setAffiliatesActive} />
|
|
128
|
+
)}
|
|
128
129
|
<Outlet />
|
|
129
130
|
</CenterLayout>
|
|
130
131
|
|
|
@@ -23,25 +23,26 @@ const InstructorAccountSwitcher = ({ setAccountType }) => {
|
|
|
23
23
|
];
|
|
24
24
|
|
|
25
25
|
const handleSwitch = (value) => {
|
|
26
|
+
window.location.href = "/instructor/dashboard";
|
|
26
27
|
if (value === 2) {
|
|
27
28
|
setSwitchValue("affiliates");
|
|
28
29
|
localStorage.setItem("affiliates", true);
|
|
29
30
|
} else {
|
|
30
|
-
setSwitchValue(
|
|
31
|
+
setSwitchValue(false);
|
|
31
32
|
localStorage.removeItem("affiliates");
|
|
32
33
|
}
|
|
33
34
|
};
|
|
34
35
|
useEffect(() => {
|
|
35
|
-
const value = JSON.
|
|
36
|
+
const value = JSON.parse(localStorage.getItem("affiliates"));
|
|
36
37
|
if (value) {
|
|
37
38
|
setSwitchValue("affiliates");
|
|
38
39
|
} else {
|
|
39
|
-
setSwitchValue(
|
|
40
|
+
setSwitchValue(null);
|
|
40
41
|
}
|
|
41
42
|
}, []);
|
|
42
43
|
|
|
43
44
|
useEffect(() => {
|
|
44
|
-
const value = JSON.
|
|
45
|
+
const value = JSON.parse(localStorage.getItem("affiliates"));
|
|
45
46
|
if (value) {
|
|
46
47
|
setAccountType && setAccountType(switchValue);
|
|
47
48
|
} else {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import styled from "styled-components";
|
|
2
2
|
|
|
3
3
|
export const MessagesWrapper = styled.div`
|
|
4
|
-
position:
|
|
4
|
+
position: fixed;
|
|
5
5
|
width: 570px;
|
|
6
6
|
/* height: 300px; */
|
|
7
7
|
/* height: 40vh; */
|
|
@@ -18,11 +18,11 @@ export const MessagesWrapper = styled.div`
|
|
|
18
18
|
align-items: center;
|
|
19
19
|
background-color: rgba(0, 194, 194, 1);
|
|
20
20
|
justify-content: space-between;
|
|
21
|
-
padding: 16px 20px;
|
|
21
|
+
padding: 16px 20px;
|
|
22
22
|
color: #ffffff;
|
|
23
23
|
|
|
24
24
|
p {
|
|
25
|
-
color: var(--white, #
|
|
25
|
+
color: var(--white, #fff);
|
|
26
26
|
font-family: Nunito;
|
|
27
27
|
font-size: 20px;
|
|
28
28
|
font-style: normal;
|
|
@@ -59,7 +59,6 @@ export const MessagesContainer = styled.div`
|
|
|
59
59
|
background-color: #ffffff;
|
|
60
60
|
border-radius: 30px;
|
|
61
61
|
height: ${({ isFullHeight }) => (isFullHeight ? "" : "0px")};
|
|
62
|
-
|
|
63
62
|
|
|
64
63
|
h1 {
|
|
65
64
|
margin-top: 0px;
|
|
@@ -446,12 +445,12 @@ export const CardContainer = styled.div`
|
|
|
446
445
|
flex-direction: column;
|
|
447
446
|
height: 65vh;
|
|
448
447
|
|
|
449
|
-
.input{
|
|
450
|
-
border-top: 1px solid var(--Neutral-20, #
|
|
448
|
+
.input {
|
|
449
|
+
border-top: 1px solid var(--Neutral-20, #dfe5e5);
|
|
451
450
|
}
|
|
452
451
|
|
|
453
452
|
.friend-header-section {
|
|
454
|
-
background: #
|
|
453
|
+
background: #e5f9f9;
|
|
455
454
|
border-radius: 20px;
|
|
456
455
|
padding: 10px;
|
|
457
456
|
display: flex;
|
|
@@ -535,38 +534,38 @@ export const CardContainer = styled.div`
|
|
|
535
534
|
margin-bottom: 4px;
|
|
536
535
|
width: 100%;
|
|
537
536
|
}
|
|
538
|
-
.friend_cont{
|
|
537
|
+
.friend_cont {
|
|
539
538
|
display: flex;
|
|
540
539
|
/* justify-content: space-between; */
|
|
541
540
|
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
541
|
+
.friend-tag {
|
|
542
|
+
border-radius: 6px;
|
|
543
|
+
background: rgba(212, 48, 206, 0.12);
|
|
544
|
+
color: #636666;
|
|
545
|
+
font-size: 12px;
|
|
546
|
+
align-items: center;
|
|
547
|
+
padding: 0px 5px;
|
|
548
|
+
display: flex;
|
|
549
|
+
justify-content: center;
|
|
550
|
+
margin-top: auto;
|
|
551
|
+
font-weight: 400;
|
|
552
|
+
|
|
553
|
+
svg {
|
|
554
|
+
margin-right: 3px;
|
|
555
|
+
}
|
|
556
556
|
}
|
|
557
|
-
}
|
|
558
557
|
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
558
|
+
p {
|
|
559
|
+
color: var(--Neutral-70, #636666);
|
|
560
|
+
font-family: Nunito;
|
|
561
|
+
font-size: 14px;
|
|
562
|
+
font-style: normal;
|
|
563
|
+
font-weight: 500;
|
|
564
|
+
line-height: normal;
|
|
565
|
+
letter-spacing: 0.28px;
|
|
566
|
+
margin-left: 10px;
|
|
567
|
+
}
|
|
568
568
|
}
|
|
569
|
-
}
|
|
570
569
|
|
|
571
570
|
.instructor-tag {
|
|
572
571
|
background: rgba(212, 48, 206, 0.12);
|