-
Notifications
You must be signed in to change notification settings - Fork 15
/
.exit
198 lines (196 loc) · 8 KB
/
.exit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
[33mcommit 435bb59c6cbaba1f0bda1a472a312f17d5c1c2ea[m[33m ([m[1;36mHEAD -> [m[1;32mAtharva[m[33m)[m
Author: AtharvaKhule-12 <[email protected]>
Date: Tue Jan 17 00:54:05 2023 +0530
webexplore and codehive pages
[1mdiff --git a/Components/EventPage/Contest_desc/Contest_desc.tsx b/Components/EventPage/Contest_desc/Contest_desc.tsx[m
[1mindex a0f31a2..74de5df 100644[m
[1m--- a/Components/EventPage/Contest_desc/Contest_desc.tsx[m
[1m+++ b/Components/EventPage/Contest_desc/Contest_desc.tsx[m
[36m@@ -1,34 +1,22 @@[m
import React from "react";[m
import styles from "./Contest_desc.module.css";[m
[m
[31m-const Contest_desc = () => {[m
[32m+[m[32minterface descProps {[m
[32m+[m[32m propWhichIsArray: {[m
[32m+[m[32m id: number,[m
[32m+[m[32m text: string;[m
[32m+[m[32m }[][m
[32m+[m[32m}[m
[32m+[m
[32m+[m[32mconst Contest_desc = (props: descProps) => {[m
[32m+[m
[32m+[m[32m const array = props.propWhichIsArray[m
return ([m
<div className={styles.main}>[m
<h1>Description</h1>[m
[m
<div className={styles.content}>[m
[31m- <p>[m
[31m- Join us in celebrating Republic Day with our coding contest! The[m
[31m- contest will consist of 8 problems, with 4 easy problems targeting[m
[31m- first year students, 2 medium problems targeting second year students,[m
[31m- and 2 hard problems targeting third and fourth year students. Each[m
[31m- problem will have partial marking, and the winner will be the[m
[31m- participant who scores the most points the earliest.[m
[31m- </p>[m
[31m-[m
[31m- <p>[m
[31m- The problems have been created by top competitive programmers at our[m
[31m- institute and cover a range of topics in both basic and advanced data[m
[31m- structures and algorithms. This contest is a great opportunity to[m
[31m- prepare for the Newton School Grand Coding Contest and the upcoming[m
[31m- off-campus placement season.[m
[31m- </p>[m
[31m-[m
[31m- <p>[m
[31m- After the contest ends, video and text editorials for the problems[m
[31m- will be provided. Dont miss this chance to challenge yourself and[m
[31m- improve your coding skills. We cant wait to see your solutions![m
[31m- </p>[m
[32m+[m[32m {array.map((item) => (<p>{item.text}</p>))}[m
</div>[m
</div>[m
);[m
[1mdiff --git a/Components/EventPage/Contest_rules/Contest_rules.tsx b/Components/EventPage/Contest_rules/Contest_rules.tsx[m
[1mindex 892ae9a..8f1c2f6 100644[m
[1m--- a/Components/EventPage/Contest_rules/Contest_rules.tsx[m
[1m+++ b/Components/EventPage/Contest_rules/Contest_rules.tsx[m
[36m@@ -1,26 +1,22 @@[m
import styles from "./Contest_rules.module.css";[m
[m
[31m-function Contest_rules() {[m
[32m+[m[32minterface rulesProps {[m
[32m+[m[32m propWhichIsArray: {[m
[32m+[m[32m id: number,[m
[32m+[m[32m text: string;[m
[32m+[m[32m }[][m
[32m+[m[32m}[m
[32m+[m
[32m+[m[32mfunction Contest_rules(props: rulesProps) {[m
[32m+[m[32m const array = props.propWhichIsArray[m
return ([m
<div className={styles.main}>[m
<h1>Rules of participation</h1>[m
[m
<ul className={styles.content}>[m
[31m- <li>[m
[31m- Lorem ipsum dolor sit amet consectetur adipisicing elit. Blanditiis in[m
[31m- beatae quia voluptatem molestiae itaque assumenda reiciendis id[m
[31m- cupiditate quis.[m
[31m- </li>[m
[31m- <li>[m
[31m- Lorem ipsum dolor sit amet consectetur adipisicing elit. Blanditiis in[m
[31m- beatae quia voluptatem molestiae itaque assumenda reiciendis id[m
[31m- cupiditate quis.[m
[31m- </li>[m
[31m- <li>[m
[31m- Lorem ipsum dolor sit amet consectetur adipisicing elit. Blanditiis in[m
[31m- beatae quia voluptatem molestiae itaque assumenda reiciendis id[m
[31m- cupiditate quis.[m
[31m- </li>[m
[32m+[m[32m {array.map((item) => ([m
[32m+[m[32m <li key={item.id}>{item.text}</li>[m
[32m+[m[32m ))}[m
</ul>[m
</div>[m
);[m
[1mdiff --git a/Components/EventPage/EventBox.tsx b/Components/EventPage/EventBox.tsx[m
[1mindex ff5adaf..e3b9875 100644[m
[1m--- a/Components/EventPage/EventBox.tsx[m
[1m+++ b/Components/EventPage/EventBox.tsx[m
[36m@@ -3,11 +3,18 @@[m [mimport eventImage from "../../public/event.png";[m
import Image from "next/image";[m
import LandingContent from "./LandingContent";[m
[m
[31m-function EventBox() {[m
[32m+[m[32minterface contestProps {[m
[32m+[m[32m name: string,[m
[32m+[m[32m type: string,[m
[32m+[m[32m date: string,[m
[32m+[m[32m content: string[m
[32m+[m[32m}[m
[32m+[m
[32m+[m[32mfunction EventBox(props: contestProps) {[m
return ([m
<div className={classes.container}>[m
<div className={classes.content}>[m
[31m- <LandingContent />[m
[32m+[m[32m <LandingContent name={props.name} type={props.type} date={props.date} content={props.content} />[m
</div>[m
<div className={classes.content}>[m
<div className={classes.img}>[m
[1mdiff --git a/Components/EventPage/Eventdescription.tsx b/Components/EventPage/Eventdescription.tsx[m
[1mindex a674984..32711fa 100644[m
[1m--- a/Components/EventPage/Eventdescription.tsx[m
[1m+++ b/Components/EventPage/Eventdescription.tsx[m
[36m@@ -4,11 +4,29 @@[m [mimport Contest_prizes from "../EventPage/Contest_prizes/Contest_prizes";[m
import ContactDetails from "./ContactDetails";[m
import Contest_rules from "./Contest_rules/Contest_rules";[m
[m
[31m-const test = () => {[m
[32m+[m[32minterface mainProps {[m
[32m+[m[32m propWhichIsArray: {[m
[32m+[m[32m id: number,[m
[32m+[m[32m text: string;[m
[32m+[m[32m }[],[m
[32m+[m[32m propWhichIsArray2: {[m
[32m+[m[32m id: number,[m
[32m+[m[32m text: string;[m
[32m+[m[32m }[][m
[32m+[m[32m}[m
[32m+[m
[32m+[m[32m// interface rulesProps {[m
[32m+[m[32m// propWhichIsArray: {[m
[32m+[m[32m// id: number,[m
[32m+[m[32m// text: string;[m
[32m+[m[32m// }[][m
[32m+[m[32m// }[m
[32m+[m
[32m+[m[32mconst test = (props: mainProps) => {[m
return ([m
<div>[m
[31m- <Contest_desc />[m
[31m- <Contest_rules />[m
[32m+[m[32m <Contest_desc propWhichIsArray={props.propWhichIsArray}/>[m
[32m+[m[32m <Contest_rules propWhichIsArray={props.propWhichIsArray2}/>[m
<Contest_prizes />[m
<ContactDetails />[m
</div>[m
[1mdiff --git a/Components/EventPage/Landing.tsx b/Components/EventPage/Landing.tsx[m
[1mindex 11a9332..6267747 100644[m
[1m--- a/Components/EventPage/Landing.tsx[m
[1m+++ b/Components/EventPage/Landing.tsx[m
[36m@@ -2,12 +2,19 @@[m [mimport Navbar from "../Header/Header";[m
import EventBox from "./EventBox";[m
import classes from "./Landing.module.css";[m
[m
[31m-function Landing() {[m
[32m+[m[32minterface contestProps {[m
[32m+[m[32m name: string,[m
[32m+[m[32m type: string,[m
[32m+[m[32m date: string,[m
[32m+[m[32m content: string[m
[32m+[m[32m}[m
[32m+[m
[32m+[m[32mfunction Landing(props: contestProps) {[m
return ([m
<div className={classes.container}>[m
[31m- <EventBox />[m
[32m+[m[32m <EventBox name={props.name} type={props.type} date={props.date} content={props.content} />[m
</div>[m
[31m- [m
[32m+[m
);[m
}[m
[m
[1mdiff --git a/Components/EventPage/LandingContent.tsx b/Components/EventPage/LandingContent.tsx[m
[1mindex 0f6e4c2..edc955c 100644[m
[1m--- a/Components/EventPage/LandingContent.tsx[m
[1m+++ b/Components/EventPage/LandingContent.tsx[m
[36m@@ -1,23 +1,28 @@[m
import classes from "./LandingContent.module.css";[m
[m
[31m-function LandingContent() {[m
[32m+[m[32minterface contestProps {[m