From 64ace5face13c6749ac68f9e9922b384f0342574 Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Sat, 10 Jul 2021 06:02:58 -0700 Subject: [PATCH 01/11] WIP:example agreement --- src/App.js | 52 ++++++- src/pages/agreement/Agreement.js | 117 +++++++++++++++ src/pages/agreement/exampleData.js | 226 +++++++++++++++++++++++++++++ 3 files changed, 387 insertions(+), 8 deletions(-) create mode 100644 src/pages/agreement/Agreement.js create mode 100644 src/pages/agreement/exampleData.js diff --git a/src/App.js b/src/App.js index 1826bde..0044815 100644 --- a/src/App.js +++ b/src/App.js @@ -3,6 +3,7 @@ import Home from "./pages/home/Home"; import Catalog from "./pages/catalog/Catalog"; import Story from "./pages/story/Story"; import About from "./pages/about/About"; +import Agreement from "./pages/agreement/Agreement"; import { Route, Link } from "react-router-dom"; import "./assets/css/App.css"; import { Nav, Navbar } from "react-bootstrap"; @@ -16,17 +17,52 @@ export default function App() { FHDATime - < Home routerProps={routerProps} />} /> - < Catalog routerProps={routerProps} />} /> - < Story routerProps={routerProps} />} /> - < About routerProps={routerProps} />} /> + } + /> + } + /> + } + /> + } + /> + } + /> ); } diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js new file mode 100644 index 0000000..3d3fd00 --- /dev/null +++ b/src/pages/agreement/Agreement.js @@ -0,0 +1,117 @@ +import React from "react"; + +const { data } = require("./exampleData"); + +export default function Agreement() { + console.log(data["UCLA"]["DeAnza College"]["Physics/B.A."]); + + const agreement = data["UCLA"]["DeAnza College"]["Physics/B.A."]; + + const renderRect = (obj) => { + if ( + typeof obj["content"] === "string" || + obj["content"] instanceof String + ) { + let relationshipKeyword = null; + { + if ("relationship" in obj && obj["relationships"] !== "") { + relationshipKeyword = ( +
{obj["relationship"]}
+ ); + } + } + return ( +
+ {relationshipKeyword} + {`${obj["content"]} - ${obj["message"]}`} +
+ ); + } else { + console.log(typeof obj["content"]); + const rect = []; + for (const component of obj["content"]) { + const courseRect = renderRect(component); + rect.push(courseRect); + } + + let equalRect = []; + if ("equivalences" in obj && obj["equivalences"] !== "") { + equalRect = renderRect(obj["equivalences"]); + } + return ( + +
{rect}
+ {equalRect} +
+ ); + } + }; + + const testObj = { + message: "", + content: [ + { + message: "Physics for Scientists and Engineers: Mechanics (5.00)", + content: "PHYSICS 1A", + relationship: "", + }, + { + message: + "Physics for Scientists and Engineers: Oscillations, Waves, Electricand Magnetic Fields (5.00)", + content: "PHYSICS 1B", + relationship: "and", + }, + { + message: + "Physics for Scientists and Engineers: Electrodynamics, Optics, and Special Relativity (5.00)", + content: "PHYSICS 1C", + relationship: "and", + }, + { + message: + "Physics Laboratory for Scientists and Engineers: Mechanics (2.00)", + content: "PHYSICS 4AL", + relationship: "and", + }, + { + message: + "Physics Laboratory for Scientists and Engineers: Electricity and Magnetism (2.00)", + content: "PHYSICS 4BL", + relationship: "and", + }, + ], + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Physics for Scientists and Engineers: Mechanics (6.00)", + content: "PHYS 4A", + relationship: "", + }, + { + message: + "Physics for Scientists and Engineers: Electricity and Magnetism (6.00)", + content: "PHYS 4B", + relationship: "and", + }, + { + message: + "Physics for Scientists and Engineers: Fluids, Waves, Optics and Thermodynamics (6.00)", + content: "PHYS 4C", + relationship: "and", + }, + ], + relationship: "", + }, + }; + + return ( + +

Agreement Example

+
+ {renderRect(data["UCLA"]["DeAnza College"]["Physics/B.A."][1])} +
+
+ ); +} diff --git a/src/pages/agreement/exampleData.js b/src/pages/agreement/exampleData.js new file mode 100644 index 0000000..25dfa80 --- /dev/null +++ b/src/pages/agreement/exampleData.js @@ -0,0 +1,226 @@ +exports.data = { + _id: "60e50d697f855c111c9b9a55", + version: "v3", + UCLA: { + "DeAnza College": { + "Physics/B.A.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: "This is the major info of physics major of UCLA!", + relationship: "", + equivalences: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "", + content: [ + { + message: + "Physics for Scientists and Engineers: Mechanics (5.00)", + content: "PHYSICS 1A", + relationship: "", + }, + { + message: + "Physics for Scientists and Engineers: Oscillations, Waves, Electricand Magnetic Fields (5.00)", + content: "PHYSICS 1B", + relationship: "and", + }, + { + message: + "Physics for Scientists and Engineers: Electrodynamics, Optics, and Special Relativity (5.00)", + content: "PHYSICS 1C", + relationship: "and", + }, + { + message: + "Physics Laboratory for Scientists and Engineers: Mechanics (2.00)", + content: "PHYSICS 4AL", + relationship: "and", + }, + { + message: + "Physics Laboratory for Scientists and Engineers: Electricity and Magnetism (2.00)", + content: "PHYSICS 4BL", + relationship: "and", + }, + ], + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Physics for Scientists and Engineers: Mechanics (6.00)", + content: "PHYS 4A", + relationship: "", + }, + { + message: + "Physics for Scientists and Engineers: Electricity and Magnetism (6.00)", + content: "PHYS 4B", + relationship: "and", + }, + { + message: + "Physics for Scientists and Engineers: Fluids, Waves, Optics and Thermodynamics (6.00)", + content: "PHYS 4C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: + "Elements of Quantum Mechanics and Statistical Mechanics (4.00)", + content: "PHYSICS 17", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Modern Physics Laboratory (4.00)", + content: "PHYSICS 18L", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "CHEMICAL STRUCTURE (4.00)", + content: "CHEM 20A", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "General Chemistry (5.00)", + content: "CHEM 1A", + relationship: "", + }, + { + message: "General Chemistry (5.00)", + content: "CHEM 1B", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1A", + relationship: "", + }, + }, + { + message: + "Differentialand Integral Calculus Laboratory (5.00)", + content: "MATH 31AL", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "or", + }, + }, + { + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", + relationship: "and", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1B", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + ], + relationship: "", + equivalences: "", + }, + { + message: "", + content: [ + { + message: "Calculus of Several Variables (4.00)", + content: "MATH 32A", + relationship: "", + }, + { + message: "Calculus of Several Variables (4.00)", + content: "MATH 32B", + relationship: "and", + }, + ], + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1D", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "Linear Algebra and Applications (4.00)", + content: "MATH 33A", + relationship: "", + equivalences: { + message: "Linear Algebra (5.00)", + content: "MATH 2B", + relationship: "", + }, + }, + { + message: "DifferentialEquations (4.00)", + content: "MATH 33B", + relationship: "", + equivalences: { + message: "DifferentialEquations (5.00)", + content: "MATH 2A", + relationship: "", + }, + }, + ], + relationship: "", + equivalences: "", + }, + ], + }, + }, +}; From 31321ac98442a4f1d1ce12fae2107055f075e32d Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Sat, 10 Jul 2021 22:23:58 -0700 Subject: [PATCH 02/11] WIP: work in progress --- src/pages/agreement/Agreement.js | 158 +++++++++++++++++-------------- 1 file changed, 87 insertions(+), 71 deletions(-) diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js index 3d3fd00..a906661 100644 --- a/src/pages/agreement/Agreement.js +++ b/src/pages/agreement/Agreement.js @@ -3,10 +3,6 @@ import React from "react"; const { data } = require("./exampleData"); export default function Agreement() { - console.log(data["UCLA"]["DeAnza College"]["Physics/B.A."]); - - const agreement = data["UCLA"]["DeAnza College"]["Physics/B.A."]; - const renderRect = (obj) => { if ( typeof obj["content"] === "string" || @@ -20,26 +16,67 @@ export default function Agreement() { ); } } - return ( -
- {relationshipKeyword} - {`${obj["content"]} - ${obj["message"]}`} -
- ); + let needBorder = false; + let equalRect = []; + if ("equivalences" in obj && obj["equivalences"] !== "") { + //console.log(obj["equivalences"]); + equalRect = renderEq(obj["equivalences"]); + } + + let result = null; + if ("equivalences" in obj) { + needBorder = true; + } + + if (needBorder) { + result = ( + +
+
+ {relationshipKeyword} + {`${obj["content"]} - ${obj["message"]}`} +
+
+ {equalRect} +
+ ); + } else { + result = ( + +
+
+ {relationshipKeyword} + {`${obj["content"]} - ${obj["message"]}`} +
+
+ {equalRect} +
+ ); + } + + return result; } else { - console.log(typeof obj["content"]); + //console.log(typeof obj["content"]); const rect = []; + for (const component of obj["content"]) { - const courseRect = renderRect(component); + const courseRect = renderRect(component, true); rect.push(courseRect); } let equalRect = []; if ("equivalences" in obj && obj["equivalences"] !== "") { - equalRect = renderRect(obj["equivalences"]); + //console.log(obj["equivalences"]); + equalRect = renderEq(obj["equivalences"]); + } + + let needTitle = false; + if (obj["message"] !== "") { + needTitle = true; } return ( + {needTitle &&

{obj["message"]}

}
{rect}
{equalRect}
@@ -47,70 +84,49 @@ export default function Agreement() { } }; - const testObj = { - message: "", - content: [ - { - message: "Physics for Scientists and Engineers: Mechanics (5.00)", - content: "PHYSICS 1A", - relationship: "", - }, - { - message: - "Physics for Scientists and Engineers: Oscillations, Waves, Electricand Magnetic Fields (5.00)", - content: "PHYSICS 1B", - relationship: "and", - }, - { - message: - "Physics for Scientists and Engineers: Electrodynamics, Optics, and Special Relativity (5.00)", - content: "PHYSICS 1C", - relationship: "and", - }, - { - message: - "Physics Laboratory for Scientists and Engineers: Mechanics (2.00)", - content: "PHYSICS 4AL", - relationship: "and", - }, + const renderEq = (obj) => { + if ( + typeof obj["content"] === "string" || + obj["content"] instanceof String + ) { + let relationshipKeyword = null; { - message: - "Physics Laboratory for Scientists and Engineers: Electricity and Magnetism (2.00)", - content: "PHYSICS 4BL", - relationship: "and", - }, - ], - relationship: "", - equivalences: { - message: "", - content: [ - { - message: "Physics for Scientists and Engineers: Mechanics (6.00)", - content: "PHYS 4A", - relationship: "", - }, - { - message: - "Physics for Scientists and Engineers: Electricity and Magnetism (6.00)", - content: "PHYS 4B", - relationship: "and", - }, - { - message: - "Physics for Scientists and Engineers: Fluids, Waves, Optics and Thermodynamics (6.00)", - content: "PHYS 4C", - relationship: "and", - }, - ], - relationship: "", - }, + if ("relationship" in obj && obj["relationships"] !== "") { + relationshipKeyword = ( +
{obj["relationship"]}
+ ); + } + } + + return ( + +
+
+ {relationshipKeyword} + {`${obj["content"]} - ${obj["message"]}`} +
+
+
+ ); + } else { + const rect = []; + for (const component of obj["content"]) { + const courseRect = renderEq(component); + rect.push(courseRect); + } + return ( + +
{rect}
+
+ ); + } }; return (

Agreement Example

-
- {renderRect(data["UCLA"]["DeAnza College"]["Physics/B.A."][1])} +
+ {renderRect(data["UCLA"]["DeAnza College"]["Physics/B.A."][1], false)}
); From 9e219ba4c470caa307ace081e061c4aa4437a47f Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Sun, 11 Jul 2021 01:37:02 -0700 Subject: [PATCH 03/11] WIP: can display agreement but need styling --- src/pages/agreement/Agreement.js | 33 ++++++++++++++++++------------ src/pages/agreement/exampleData.js | 2 +- 2 files changed, 21 insertions(+), 14 deletions(-) diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js index a906661..2d10c7f 100644 --- a/src/pages/agreement/Agreement.js +++ b/src/pages/agreement/Agreement.js @@ -31,23 +31,20 @@ export default function Agreement() { if (needBorder) { result = ( -
-
- {relationshipKeyword} - {`${obj["content"]} - ${obj["message"]}`} -
+ {relationshipKeyword} +
+
{`${obj["content"]} - ${obj["message"]}`}
+ {relationshipKeyword} {equalRect} ); } else { result = ( + {relationshipKeyword}
-
- {relationshipKeyword} - {`${obj["content"]} - ${obj["message"]}`} -
+
{`${obj["content"]} - ${obj["message"]}`}
{equalRect}
@@ -78,6 +75,7 @@ export default function Agreement() { {needTitle &&

{obj["message"]}

}
{rect}
+ {obj["relationship"]} {equalRect}
); @@ -100,11 +98,9 @@ export default function Agreement() { return ( + {relationshipKeyword}
-
- {relationshipKeyword} - {`${obj["content"]} - ${obj["message"]}`} -
+
{`${obj["content"]} - ${obj["message"]}`}
); @@ -114,8 +110,19 @@ export default function Agreement() { const courseRect = renderEq(component); rect.push(courseRect); } + + let relationshipKeyword = null; + { + if ("relationship" in obj && obj["relationships"] !== "") { + relationshipKeyword = ( +
{obj["relationship"]}
+ ); + } + } + return ( + {relationshipKeyword}
{rect}
); diff --git a/src/pages/agreement/exampleData.js b/src/pages/agreement/exampleData.js index 25dfa80..d0f0075 100644 --- a/src/pages/agreement/exampleData.js +++ b/src/pages/agreement/exampleData.js @@ -136,7 +136,7 @@ exports.data = { equivalences: { message: "No Course Articulated", content: "", - relationship: "or", + relationship: "", }, }, { From d43912bda393165884984e9ae0d0d6faaf5247b6 Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Sun, 11 Jul 2021 03:35:24 -0700 Subject: [PATCH 04/11] fix: typo --- src/pages/agreement/Agreement.js | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js index 2d10c7f..2a1259d 100644 --- a/src/pages/agreement/Agreement.js +++ b/src/pages/agreement/Agreement.js @@ -10,7 +10,7 @@ export default function Agreement() { ) { let relationshipKeyword = null; { - if ("relationship" in obj && obj["relationships"] !== "") { + if ("relationship" in obj && obj["relationship"] !== "") { relationshipKeyword = (
{obj["relationship"]}
); @@ -31,18 +31,18 @@ export default function Agreement() { if (needBorder) { result = ( - {relationshipKeyword} + {relationshipKeyword ? relationshipKeyword : null}
{`${obj["content"]} - ${obj["message"]}`}
- {relationshipKeyword} + {relationshipKeyword ? relationshipKeyword : null} {equalRect}
); } else { result = ( - {relationshipKeyword} + {relationshipKeyword ? relationshipKeyword : null}
{`${obj["content"]} - ${obj["message"]}`}
@@ -89,7 +89,8 @@ export default function Agreement() { ) { let relationshipKeyword = null; { - if ("relationship" in obj && obj["relationships"] !== "") { + if ("relationship" in obj && obj["relationship"] !== "") { + console.log(obj["relationship"]); relationshipKeyword = (
{obj["relationship"]}
); @@ -98,7 +99,7 @@ export default function Agreement() { return ( - {relationshipKeyword} + {relationshipKeyword ? relationshipKeyword : null}
{`${obj["content"]} - ${obj["message"]}`}
@@ -113,7 +114,7 @@ export default function Agreement() { let relationshipKeyword = null; { - if ("relationship" in obj && obj["relationships"] !== "") { + if ("relationship" in obj && obj["relationship"] !== "") { relationshipKeyword = (
{obj["relationship"]}
); @@ -122,7 +123,7 @@ export default function Agreement() { return ( - {relationshipKeyword} + {relationshipKeyword ? relationshipKeyword : null}
{rect}
); From f079e7b312c0741b9a87fbeab5cb6e67edcb8d66 Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Sun, 11 Jul 2021 07:11:11 -0700 Subject: [PATCH 05/11] fix: display structure --- src/pages/agreement/Agreement.js | 42 ++++++++++++++++++++++++++++---- 1 file changed, 37 insertions(+), 5 deletions(-) diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js index 2a1259d..5491af2 100644 --- a/src/pages/agreement/Agreement.js +++ b/src/pages/agreement/Agreement.js @@ -16,10 +16,12 @@ export default function Agreement() { ); } } + let foundEq = false; let needBorder = false; let equalRect = []; if ("equivalences" in obj && obj["equivalences"] !== "") { //console.log(obj["equivalences"]); + foundEq = true; equalRect = renderEq(obj["equivalences"]); } @@ -31,12 +33,19 @@ export default function Agreement() { if (needBorder) { result = ( - {relationshipKeyword ? relationshipKeyword : null} -
-
{`${obj["content"]} - ${obj["message"]}`}
+
+
+
+ {relationshipKeyword ? relationshipKeyword : null} +
+
{`${obj["content"]} - ${obj["message"]}`}
+
+
+
+ {relationshipKeyword ? relationshipKeyword : null} + {equalRect} +
- {relationshipKeyword ? relationshipKeyword : null} - {equalRect} ); } else { @@ -62,8 +71,10 @@ export default function Agreement() { } let equalRect = []; + let foundEql = false; if ("equivalences" in obj && obj["equivalences"] !== "") { //console.log(obj["equivalences"]); + foundEql = true; equalRect = renderEq(obj["equivalences"]); } @@ -71,6 +82,27 @@ export default function Agreement() { if (obj["message"] !== "") { needTitle = true; } + + if (foundEql) { + return ( + + {needTitle &&

{obj["message"]}

} +
+
+
+
+ {rect} +
+
+
+ {obj["relationship"]} + {equalRect} +
+
+
+ ); + } + return ( {needTitle &&

{obj["message"]}

} From b72791527c4d393d9de08342ca03c6735d81d4e4 Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Sun, 11 Jul 2021 20:09:10 -0700 Subject: [PATCH 06/11] fix: reasonable styling --- src/pages/agreement/Agreement.js | 21 ++- src/pages/agreement/exampleData.js | 288 +++++++++++++++++++++++++++++ 2 files changed, 305 insertions(+), 4 deletions(-) diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js index 5491af2..8c82891 100644 --- a/src/pages/agreement/Agreement.js +++ b/src/pages/agreement/Agreement.js @@ -35,6 +35,7 @@ export default function Agreement() {
+
{relationshipKeyword ? relationshipKeyword : null}
@@ -45,6 +46,7 @@ export default function Agreement() { {relationshipKeyword ? relationshipKeyword : null} {equalRect}
+
); @@ -86,9 +88,10 @@ export default function Agreement() { if (foundEql) { return ( - {needTitle &&

{obj["message"]}

}
+ {needTitle &&

{obj["message"]}

}
+
{rect} @@ -98,16 +101,26 @@ export default function Agreement() { {obj["relationship"]} {equalRect}
+
); } + let flag = true; + if (equalRect.length === 0) { + flag = false; + } + return ( +
+
{obj["relationship"]}
{needTitle &&

{obj["message"]}

}
{rect}
- {obj["relationship"]} + {flag && ( +
{obj["relationship"]}
+ )} {equalRect}
); @@ -122,7 +135,7 @@ export default function Agreement() { let relationshipKeyword = null; { if ("relationship" in obj && obj["relationship"] !== "") { - console.log(obj["relationship"]); + //console.log(obj["relationship"]); relationshipKeyword = (
{obj["relationship"]}
); @@ -166,7 +179,7 @@ export default function Agreement() {

Agreement Example

- {renderRect(data["UCLA"]["DeAnza College"]["Physics/B.A."][1], false)} + {renderRect(data["UCLA"]["DeAnza College"]["Physics/B.A."][1])}
); diff --git a/src/pages/agreement/exampleData.js b/src/pages/agreement/exampleData.js index d0f0075..c45996f 100644 --- a/src/pages/agreement/exampleData.js +++ b/src/pages/agreement/exampleData.js @@ -3,6 +3,294 @@ exports.data = { version: "v3", UCLA: { "DeAnza College": { + "Computer Science/B.S.": [ + { + message: "IMPORTANT MAJOR DETAILS", + content: "This is the major info of cs major of UCLA!", + relationship: "", + }, + { + message: "PROGRAMMING REQUIREMENT", + content: + "This is the programming requirement info of cs major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL IMPORTANT GENERAL MAJOR INFORMATION", + content: "ADDITIONAL IMPORTANT GENERAL MAJOR INFORMATION CONTENT", + relationship: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1A", + relationship: "", + }, + }, + { + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1B", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32A", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "", + }, + }, + { + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32B", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1D", + relationship: "", + }, + }, + { + message: "Linear Algebra and Applications (4.00)", + content: "MATH 33A", + relationship: "", + equivalences: { + message: "Linear Algebra (5.00)", + content: "MATH 2B", + relationship: "", + }, + }, + { + message: "DifferentialEquations (4.00)", + content: "MATH 33B", + relationship: "", + equivalences: { + message: "DifferentialEquations (5.00)", + content: "MATH 2A", + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: + "Physics for Scientists and Engineers: Mechanics (5.00)", + content: "PHYSICS 1A", + relationship: "", + }, + { + message: + "Physics for Scientists and Engineers: Oscillations, Waves, Electricand Magnetic Fields (5.00)", + content: "PHYSICS 1B", + relationship: "and", + }, + { + message: + "Physics for Scientists and Engineers: Electrodynamics, Optics, and Special Relativity (5.00)", + content: "PHYSICS 1C", + relationship: "and", + }, + ], + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Physics for Scientists and Engineers: Mechanics (6.00)", + content: "PHYS 4A", + relationship: "", + }, + { + message: + "Physics for Scientists and Engineers: Electricity and Magnetism (6.00)", + content: "PHYS 4B", + relationship: "and", + }, + { + message: + "Physics for Scientists and Engineers: Fluids, Waves, Optics and Thermodynamics (6.00)", + content: "PHYS 4C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: + "Physics Laboratory for Scientists and Engineers: Mechanics (2.00) Please refer to additional important General Information section above", + content: "PHYSICS 4AL", + relationship: "", + }, + { + message: + "Physics Laboratory for Scientists and Engineers: Electricity and Magnetism (2.00) Please refer to additional important General Information section above", + content: "PHYSICS 4BL", + relationship: "or", + }, + ], + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Articulates as a Series Only", + content: "", + relationship: "", + }, + { + message: "Articulates as a Series Only", + content: "", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "English Composition, Rhetoric, and Language(5.00)", + content: "ENGCOMP 3", + relationship: "", + equivalences: { + message: "Composition and Reading (5.00)", + content: "EWRT 1A", + relationship: "", + }, + }, + { + message: "Select 1 Course(s) from the following", + content: [ + { + message: "One additional course in English composition", + content: "One additional course in English composition", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Argumentation: Analysis of Oraland Written Communication (5.00)", + content: "COMM 9", + relationship: "", + }, + { + message: "Reading, Writing and Research (5.00)", + content: "WRT 1B", + relationship: "or", + }, + { + message: "Reading, Writing and Research - HONORS(5.00)", + content: "EWRT 1BH", + relationship: "or", + }, + { + message: "Literatureand Composition (5.00)", + content: "EWRT 1C", + relationship: "or", + }, + { + message: + "Critical Reading, Writing and Thinking (5.00)", + content: "EWRT 2", + relationship: "or", + }, + { + message: "CriticalThinking and Writing (5.00)", + content: "PHIL 3", + relationship: "or", + }, + ], + relationship: "", + }, + }, + ], + relationship: "and", + }, + { + message: "Select 1 Course(s) from the following", + content: [ + { + message: "One course in computer programming: C++ preferred", + content: "One course in computer programming: C++ preferred", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Programming in C++ for C/Java Programmers (4.50)", + content: "CIS 27", + relationship: "", + }, + { + message: "Advanced C++ Programming (4.50)", + content: "CIS 29", + relationship: "or", + }, + { + message: "", + content: [ + { + message: + "Beginning Programming Methodologies in C++ (4.50)", + content: "CIS 22A", + relationship: "", + }, + { + message: + "Intermediate Programming Methodologies in C++ - HONORS(4.50)", + content: "CIS 22BH", + relationship: "and", + }, + ], + relationship: "or", + }, + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "or", + }, + ], + relationship: "", + }, + }, + ], + relationship: "and", + }, + ], + relationship: "", + }, + ], "Physics/B.A.": [ { message: "IMPORTANT MAJOR INFORMATION", From 029878a5e9c4c9c503ed8dae3f7bf345fb65181d Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Mon, 12 Jul 2021 00:41:08 -0700 Subject: [PATCH 07/11] feature: agreement page version 1 --- src/pages/agreement/Agreement.js | 25 +++++- src/pages/agreement/exampleData.js | 129 +++++++++++++++++++++++++++++ 2 files changed, 152 insertions(+), 2 deletions(-) diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js index 8c82891..0d77448 100644 --- a/src/pages/agreement/Agreement.js +++ b/src/pages/agreement/Agreement.js @@ -175,11 +175,32 @@ export default function Agreement() { } }; + const rawWholeAgreement = data["UCLA"]["DeAnza College"]["Physics/B.A."]; + + const wholeAgreement = []; + + for (const section of rawWholeAgreement) { + if ( + typeof section["content"] === "string" || + section["content"] instanceof String + ) { + wholeAgreement.push( +
+

{section["message"]}

+

+ {section["content"]} +

+
+ ); + } else { + wholeAgreement.push(renderRect(section)); + } + } return (

Agreement Example

-
- {renderRect(data["UCLA"]["DeAnza College"]["Physics/B.A."][1])} +
+ {wholeAgreement}
); diff --git a/src/pages/agreement/exampleData.js b/src/pages/agreement/exampleData.js index c45996f..de20a36 100644 --- a/src/pages/agreement/exampleData.js +++ b/src/pages/agreement/exampleData.js @@ -290,6 +290,135 @@ exports.data = { ], relationship: "", }, + { + message: "STRONGLY RECOMMENDED COURSES", + content: [ + { + message: "Introduction to Computer ScienceI (4.00)", + content: "COM SCI 31", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "", + content: [ + { + message: + "Beginning Programming Methodologies in C++ (4.50)", + content: "CIS 22A", + relationship: "", + }, + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "and", + }, + ], + relationship: "", + }, + { + message: "", + content: [ + { + message: + "Beginning Programming Methodologies in C++ (4.50)", + content: "CIS 22A", + relationship: "", + }, + { + message: + "Intermediate Programming Methodologies in C++ - HONORS(4.50)", + content: "CIS 22BH", + relationship: "and", + }, + ], + relationship: "or", + }, + { + message: "Programming in C++ for C/Java Programmers (4.50)", + content: "CIS 27", + relationship: "or", + }, + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Introduction to Computer ScienceII (4.00)", + content: "COM SCI 32", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "", + }, + { + message: "Data Abstraction and Structures (4.50)", + content: "CIS 22C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "Introduction to Computer Organization (5.00)", + content: "COM SCI 33", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Introduction to x86 Processor Assembly Languageand Computer Architecture(4.50)", + content: "CIS 21JA", + relationship: "", + }, + { + message: + "Advanced x86 Processor Assembly Programming (4.50)", + content: "CIS 21JB", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Logic Design of DigitalSystems (4.00)", + content: "COM SCI M51A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Introduction to DiscreteStructures (4.00)", + content: "MATH 61", + relationship: "", + equivalences: { + message: "Discrete Mathematics (5.00)", + content: "MATH 22", + relationship: "", + }, + }, + ], + relationship: "", + }, ], "Physics/B.A.": [ { From c77d84f80f1427ac6d432be55111531473eac7ad Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Mon, 12 Jul 2021 00:45:38 -0700 Subject: [PATCH 08/11] fix: typo --- src/App.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/App.js b/src/App.js index 0044815..5e317b3 100644 --- a/src/App.js +++ b/src/App.js @@ -29,9 +29,6 @@ export default function App() { About - - About - Agreement From e036a19d10d1d9daf8e693e9be5de9ebba959a98 Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Tue, 13 Jul 2021 00:21:01 -0700 Subject: [PATCH 09/11] add more test cases --- src/pages/agreement/Agreement.js | 9 +- src/pages/agreement/exampleData.js | 988 ++++++++++++++++++++++++++++- 2 files changed, 992 insertions(+), 5 deletions(-) diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js index 0d77448..a781f6b 100644 --- a/src/pages/agreement/Agreement.js +++ b/src/pages/agreement/Agreement.js @@ -175,7 +175,7 @@ export default function Agreement() { } }; - const rawWholeAgreement = data["UCLA"]["DeAnza College"]["Physics/B.A."]; + const rawWholeAgreement = data["UCLA"]["DeAnza College"]["Anthropology/B.S."]; const wholeAgreement = []; @@ -187,9 +187,10 @@ export default function Agreement() { wholeAgreement.push(

{section["message"]}

-

- {section["content"]} -

+

); } else { diff --git a/src/pages/agreement/exampleData.js b/src/pages/agreement/exampleData.js index de20a36..1a00af2 100644 --- a/src/pages/agreement/exampleData.js +++ b/src/pages/agreement/exampleData.js @@ -6,7 +6,8 @@ exports.data = { "Computer Science/B.S.": [ { message: "IMPORTANT MAJOR DETAILS", - content: "This is the major info of cs major of UCLA!", + content: + "Admission to the Henry Samueli School of Engineering and Applied Sciences at UCLA is highly competitive. The most important selection criteria are completion of the required preparatory courses and academic performance. Listed below are the lower division preparation courses for the major. All applicants must have a minimum transferable cumulative GPA of 3.4. Preparatory courses must be completed by the end of spring prior to fall enrollment. All major courses must be taken for a letter grade. HSSEAS admits students by major and does NOT consider applicants for alternate majors. Applicants are not required to complete the HSSEAS General Education Requirements in order to be admitted, although it is beneficial for students to complete 1 course from each of the following areas: arts, humanities, social sciences, and life sciences. Applicants can fulfill the lower division General Education requirement by completion of the Intersegmental General Transfer Curriculum (IGETC). Partial IGETC is NOT accepted. For more information regarding this major and UCLA's transfer selection process, visit www.admission.ucla.edu. If you still have specific questions, you may email the HSSEAS admissions office at erkki@seas.ucla.edu. PLEASE NOTE: the community college courses listed below have been approved to satisfy the preparation requirements for this major at UCLA, but they may not be exact equivalents of the UCLA courses listed. In addition, upper division requirements for the major may be satisfied by lower division community college course(s) listed below, however specific credit will be determined by the department after transfer.", relationship: "", }, { @@ -638,6 +639,991 @@ exports.data = { equivalences: "", }, ], + "Mathematics/B.S.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: "This is the major info of math major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL RECOMMENDED MAJOR PREPARATION", + content: "This is the additional info of math major of UCLA!", + relationship: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "", + content: [ + { + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1A", + relationship: "", + }, + }, + { + message: + "Differentialand Integral Calculus Laboratory (5.00)", + content: "MATH 31AL", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "", + equivalences: "", + }, + { + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1B", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32A", + relationship: "", + }, + { + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32B", + relationship: "and", + }, + ], + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1D", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "Linear Algebra and Applications (4.00)", + content: "MATH 33A", + relationship: "", + equivalences: { + message: "Linear Algebra (5.00)", + content: "MATH 2B", + relationship: "", + }, + }, + { + message: "DifferentialEquations (4.00) ", + content: "MATH 33B", + relationship: "", + equivalences: { + message: "DifferentialEquations (5.00)", + content: "MATH 2A", + relationship: "", + }, + }, + { + message: "Introduction to Programming(C++) (5.00)", + content: "COMPTNG 10A", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Programming in C++ for C/Java Programmers (4.50)", + content: "CIS 27", + relationship: "", + }, + { + message: "", + content: [ + { + message: + "Beginning Programming Methodologies in C++ (4.50)", + content: "CIS 22A", + relationship: "", + }, + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "and", + }, + ], + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Physics for Scientists and Engineers: Mechanics (5.00)", + content: "PHYSICS 1A", + relationship: "", + equivalences: { + message: + "Physics for Scientists and Engineers: Mechanics (6.00)", + content: "PHYS 4A", + relationship: "", + }, + }, + { + message: "Select 2 Course(s) from the following", + content: [ + { + message: "CHEMICAL STRUCTURE (4.00)", + content: "CHEM 20A", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "General Chemistry (5.00)", + content: "CHEM 1A", + relationship: "", + }, + { + message: "General Chemistry (5.00)", + content: "CHEM 1B", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "ChemicalEnergetics and Change(4.00) ", + content: "CHEM 20B", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "General Chemistry (5.00)", + content: "CHEM 1B", + relationship: "", + }, + { + message: + "General Chemistry and Qualitative Analysis (5.00)", + content: "CHEM 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "MicroeconomicTheory (4.00)", + content: "ECON 11", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Logic, First Course(5.00)", + content: "PHILOS 31", + relationship: "", + equivalences: { + message: "DeductiveLogic (4.00)", + content: "PHIL 7", + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: + "Physics for LifeSciences Majors: Thermodynamics, Fluids, Waves, Light, and Optics (5.00)", + content: "PHYSICS 5B -", + relationship: "", + }, + { + message: + "Physics for LifeSciences Majors: Electricity, Magnetism, and Modern Physics (5.00)", + content: "PHYSICS 5C", + relationship: "and", + }, + ], + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: "", + content: [ + { + message: + "Physics for Scientists and Engineers: Oscillations, Waves, Electricand Magnetic Fields (5.00)", + content: "PHYSICS 1B", + relationship: "", + equivalences: { + message: + "Physics for Scientists and Engineers: Electricity and Magnetism (6.00)", + content: "PHYS 4B", + relationship: "", + }, + }, + { + message: + "Physics for Scientists and Engineers: Electrodynamics, Optics, and Special Relativity (5.00)", + content: "PHYSICS 1C", + relationship: "and", + equivalences: { + message: + "Physics for Scientists and Engineers: Fluids, Waves, Optics and Thermodynamics (6.00)", + content: "PHYS 4C", + relationship: "", + }, + }, + ], + relationship: "or", + }, + { + message: "Celland Molecular Biology (5.00)", + content: "LIFESCI 7A", + relationship: "", + equivalences: { + message: "Celland Molecular Biology (6.00)", + content: "BIOL 6B", + relationship: "", + }, + }, + ], + relationship: "", + }, + ], + "Data Theory/B.S.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: "This is the major info of data theory major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL INFORMATION", + content: "ADDITIONAL INFORMATION of data theory major of UCLA!", + relationship: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "", + content: [ + { + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1A", + relationship: "", + }, + }, + { + message: + "Differentialand Integral Calculus Laboratory (5.00)", + content: "MATH 31AL", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1B", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32A", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "", + }, + }, + { + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32B", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1D", + relationship: "", + }, + }, + { + message: "Linear Algebra and Applications (4.00)", + content: "MATH 33A", + relationship: "", + equivalences: { + message: "Linear Algebra (5.00)", + content: "MATH 2B", + relationship: "", + }, + }, + { + message: + "Introduction to Data Driven Mathematical Modeling: Life, The Universe, and Everything (4.00)", + content: "MATH 42", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Introduction to Programming(C++) (5.00)", + content: "COMPTNG 10A", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Programming in C++ for C/Java Programmers (4.50)", + content: "CIS 27", + relationship: "", + }, + { + message: "", + content: [ + { + message: + "Beginning Programming Methodologies in C++ (4.50)", + content: "CIS 22A", + relationship: "", + }, + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "and", + }, + ], + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Select 1 or more Course(s) from the following", + content: [ + { + message: "Introduction to Statistical Reasoning (5.00)", + content: "STATS 10", + relationship: "", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + { + message: + "Introduction to Statistical Methods for Geography and EnvironmentalStudies (5.00)", + content: "STATS 12", + relationship: "or", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: + "Introduction to Statistical Methods for Lifeand Health Sciences (5.00)", + content: "STATS 13", + relationship: "", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + { + message: + "Introduction to Statistical Programming with R. (4.00)", + content: "STATS 20", + relationship: "and", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "or", + }, + ], + relationship: "", + }, + ], + relationship: "", + }, + ], + "Asian American Studies/B.A.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: + "This is the major info of Asian American Studies major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL NOTE", + content: + "This is the additional note for Asian American Studies major of UCLA!", + relationship: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "Select 1 Course(s) from the following", + content: [ + { + message: "History of Asian Americans (5.00)", + content: "ASIA AM 10", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Asian American Experience Past and Present (4.00)", + content: "ASAM 1", + relationship: "", + }, + { + message: + "Introduction to Pacific Islander History and Culture(4.00)", + content: "ASAM 31", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "History of Asian Americans (5.00)", + content: "ASIA AM 10W", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Contemporary Asian American Communities (5.00)", + content: "ASIA AM 20", + relationship: "or", + equivalences: { + message: "Contemporary Asian American Communities (4.00)", + content: "ASAM 10", + relationship: "", + }, + }, + { + message: "Contemporary Asian American (5.00)", + content: "ASIA AM 20W", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Asian American Literatureand Culture(5.00)", + content: "ASIA AM 30", + relationship: "or", + equivalences: { + message: "", + content: [ + { + message: + "Asian Pacific American Literature(4.00) Same-As: ASAM 20", + content: "ELIT 24", + relationship: "", + }, + { + message: + "Asian Pacific American Literature(4.00) Same-As: ELIT 24", + content: "ASAM 20", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Asian American Movement (5.00)", + content: "ASIA AM 40", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Asian American Movement (5.00)", + content: "ASIA AM 40W", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Asian American Women (5.00)", + content: "ASIA AM 50", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Asian American Women (5.00)", + content: "ASIA AM 50W", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "", + }, + ], + relationship: "", + }, + ], + "Anthropology/B.S.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: "This is the major info of Anthropology major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL NOTES:", + content: "This is the additional note for Anthropolog major of UCLA!", + relationship: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "HUMAN EVOLUTION (5.00)", + content: "ANTHRO 1", + relationship: "", + equivalences: { + message: "Physical Anthropology (4.00)", + content: "ANTH 1", + relationship: "", + }, + }, + { + message: "Archaeology: Introduction (5.00)", + content: "ANTHRO 2", + relationship: "", + equivalences: { + message: "World Prehistory (4.00)", + content: "ANTH 4", + relationship: "", + }, + }, + { + message: "CULTURE AND SOCIETY (5.00)", + content: "ANTHRO 3", + relationship: "", + equivalences: { + message: "Cultural Anthropology (4.00)", + content: "ANTH 2", + relationship: "", + }, + }, + { + message: "Cultureand Communication (5.00)", + content: "ANTHRO 4", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Celland Molecular Biology (5.00)", + content: "LIFESCI 7A", + relationship: "", + equivalences: { + message: "Celland Molecular Biology (6.00)", + content: "BIOL 6B", + relationship: "", + }, + }, + { + message: "Genetics, Evolution, and Ecology (5.00)", + content: "LIFESCI 7B", + relationship: "", + equivalences: { + message: "Ecology and Evolution (6.00)", + content: "BIOL 6C", + relationship: "", + }, + }, + { + message: "Physiology and Human Biology (5.00)", + content: "LIFESCI 7C", + relationship: "", + equivalences: { + message: "Form and Function in the Biological World (6.00)", + content: "BIOL 6A", + relationship: "", + }, + }, + { + message: + "Introduction to Laboratory and Scientific Methodology (3.00)", + content: "LIFESCI 23L", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Form and Function in the Biological World (6.00)", + content: "BIOL 6A", + relationship: "", + }, + { + message: "Celland Molecular Biology (6.00)", + content: "BIOL 6B", + relationship: "and", + }, + { + message: "Ecology and Evolution (6.00)", + content: "BIOL 6C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: "CHEMICAL STRUCTURE (4.00)", + content: "CHEM 20A", + relationship: "", + }, + { + message: "ChemicalEnergetics and Change(4.00)", + content: "CHEM 20B", + relationship: "and", + }, + { + message: "General Chemistry Laboratory (3.00)", + content: "CHEM 20L", + relationship: "and", + }, + { + message: "General Chemistry Laboratory II (4.00)", + content: "CHEM 30AL", + relationship: "and", + }, + ], + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "General Chemistry (5.00)", + content: "CHEM 1A", + relationship: "", + }, + { + message: "General Chemistry (5.00)", + content: "CHEM 1B", + relationship: "and", + }, + { + message: + "General Chemistry and Qualitative Analysis (5.00)", + content: "CHEM 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "Organic Chemistry I: Structureand Reactivity (4.00)", + content: "CHEM 30A", + relationship: "", + equivalences: { + message: "Organic Chemistry (5.00)", + content: "CHEM 12A", + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: "", + content: [ + { + message: "Calculus for LifeSciences Students (4.00)", + content: "MATH 3A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Calculus for LifeSciences Students (4.00)", + content: "MATH 3B", + relationship: "and", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Ordinary DifferentialEquations With Linear Algebra for LifeSciences Students (4.00)", + content: "MATH 3C", + relationship: "and", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Introduction to Statistical Methods for Geography and EnvironmentalStudies (5.00) -Acceptable substitute", + content: "STATS 12", + relationship: "and", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: "", + content: [ + { + message: "", + content: [ + { + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1A", + relationship: "", + }, + }, + { + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", + relationship: "and", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1B", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: + "Introduction to Statistical Methods for Geography and EnvironmentalStudies (5.00) -Acceptable substitute", + content: "STATS 12", + relationship: "and", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: "", + content: [ + { + message: "Mathematics for LifeScientists (5.00)", + content: "LIFESCI 30A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Mathematics for LifeScientists (5.00)", + content: "LIFESCI 30B", + relationship: "and", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Introduction to Statistical Methods for Lifeand Health Sciences (5.00) -Acceptable substitute", + content: "STATS 13", + relationship: "and", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + { + message: + "Physics for LifeSciences Majors: Mechanics, and Energy (5.00)", + content: "PHYSICS 5A", + relationship: "", + equivalences: { + message: "General Introductory Physics (5.00)", + content: "PHYS 2A", + relationship: "", + }, + }, + { + message: + "Physics for LifeSciences Majors: Thermodynamics, Fluids, Waves, Light, and Optics (5.00)", + content: "PHYSICS 5B", + relationship: "and", + equivalences: { + message: "General Introductory Physics (5.00)", + content: "PHYS 2B", + relationship: "", + }, + }, + { + message: + "Physics for LifeSciences Majors: Electricity, Magnetism, and Modern Physics (5.00)", + content: "PHYSICS 5C", + relationship: "", + equivalences: { + message: "General Introductory Physics (5.00)", + content: "PHYS 2C", + relationship: "", + }, + }, + ], + relationship: "or", + }, + ], + relationship: "or", + }, + ], + relationship: "", + }, + ], + relationship: "", + }, + ], }, }, }; From 14080b0cba42d4eb55c34bddec54519678332cd9 Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Tue, 13 Jul 2021 03:25:52 -0700 Subject: [PATCH 10/11] all agreement can be rendered properly --- src/pages/agreement/Agreement.js | 5 +- src/pages/agreement/exampleData.js | 2751 +++++++++++++++++++--------- 2 files changed, 1844 insertions(+), 912 deletions(-) diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js index a781f6b..778e1bb 100644 --- a/src/pages/agreement/Agreement.js +++ b/src/pages/agreement/Agreement.js @@ -93,12 +93,13 @@ export default function Agreement() {
+
{obj["relationship"]}
{rect}
- {obj["relationship"]} +
{obj["relationship"]}
{equalRect}
@@ -175,7 +176,7 @@ export default function Agreement() { } }; - const rawWholeAgreement = data["UCLA"]["DeAnza College"]["Anthropology/B.S."]; + const rawWholeAgreement = data["UCLA"]["DeAnza College"]["Physics/B.A."]; const wholeAgreement = []; diff --git a/src/pages/agreement/exampleData.js b/src/pages/agreement/exampleData.js index 1a00af2..3424131 100644 --- a/src/pages/agreement/exampleData.js +++ b/src/pages/agreement/exampleData.js @@ -3,98 +3,15 @@ exports.data = { version: "v3", UCLA: { "DeAnza College": { - "Computer Science/B.S.": [ - { - message: "IMPORTANT MAJOR DETAILS", - content: - "Admission to the Henry Samueli School of Engineering and Applied Sciences at UCLA is highly competitive. The most important selection criteria are completion of the required preparatory courses and academic performance. Listed below are the lower division preparation courses for the major. All applicants must have a minimum transferable cumulative GPA of 3.4. Preparatory courses must be completed by the end of spring prior to fall enrollment. All major courses must be taken for a letter grade. HSSEAS admits students by major and does NOT consider applicants for alternate majors. Applicants are not required to complete the HSSEAS General Education Requirements in order to be admitted, although it is beneficial for students to complete 1 course from each of the following areas: arts, humanities, social sciences, and life sciences. Applicants can fulfill the lower division General Education requirement by completion of the Intersegmental General Transfer Curriculum (IGETC). Partial IGETC is NOT accepted. For more information regarding this major and UCLA's transfer selection process, visit www.admission.ucla.edu. If you still have specific questions, you may email the HSSEAS admissions office at erkki@seas.ucla.edu. PLEASE NOTE: the community college courses listed below have been approved to satisfy the preparation requirements for this major at UCLA, but they may not be exact equivalents of the UCLA courses listed. In addition, upper division requirements for the major may be satisfied by lower division community college course(s) listed below, however specific credit will be determined by the department after transfer.", - relationship: "", - }, - { - message: "PROGRAMMING REQUIREMENT", - content: - "This is the programming requirement info of cs major of UCLA!", - relationship: "", - }, + "Physics/B.A.": [ { - message: "ADDITIONAL IMPORTANT GENERAL MAJOR INFORMATION", - content: "ADDITIONAL IMPORTANT GENERAL MAJOR INFORMATION CONTENT", + message: "IMPORTANT MAJOR INFORMATION", + content: "This is the major info of physics major of UCLA!", relationship: "", }, { message: "LOWER DIVISION MAJOR REQUIREMENTS", content: [ - { - message: "Differentialand Integral Calculus (4.00)", - content: "MATH 31A", - relationship: "", - equivalences: { - message: "Calculus (5.00)", - content: "MATH 1A", - relationship: "", - }, - }, - { - message: "Integration and InfiniteSeries (4.00)", - content: "MATH 31B", - relationship: "", - equivalences: { - message: "", - content: [ - { - message: "Calculus (5.00)", - content: "MATH 1B", - relationship: "", - }, - { - message: "Calculus (5.00)", - content: "MATH 1C", - relationship: "and", - }, - ], - relationship: "", - }, - }, - { - message: "Calculus ofSeveral Variables (4.00)", - content: "MATH 32A", - relationship: "", - equivalences: { - message: "Calculus (5.00)", - content: "MATH 1C", - relationship: "", - }, - }, - { - message: "Calculus ofSeveral Variables (4.00)", - content: "MATH 32B", - relationship: "", - equivalences: { - message: "Calculus (5.00)", - content: "MATH 1D", - relationship: "", - }, - }, - { - message: "Linear Algebra and Applications (4.00)", - content: "MATH 33A", - relationship: "", - equivalences: { - message: "Linear Algebra (5.00)", - content: "MATH 2B", - relationship: "", - }, - }, - { - message: "DifferentialEquations (4.00)", - content: "MATH 33B", - relationship: "", - equivalences: { - message: "DifferentialEquations (5.00)", - content: "MATH 2A", - relationship: "", - }, - }, { message: "", content: [ @@ -116,6 +33,18 @@ exports.data = { content: "PHYSICS 1C", relationship: "and", }, + { + message: + "Physics Laboratory for Scientists and Engineers: Mechanics (2.00)", + content: "PHYSICS 4AL", + relationship: "and", + }, + { + message: + "Physics Laboratory for Scientists and Engineers: Electricity and Magnetism (2.00)", + content: "PHYSICS 4BL", + relationship: "and", + }, ], relationship: "", equivalences: { @@ -144,230 +73,122 @@ exports.data = { }, }, { - message: "", - content: [ - { - message: - "Physics Laboratory for Scientists and Engineers: Mechanics (2.00) Please refer to additional important General Information section above", - content: "PHYSICS 4AL", - relationship: "", - }, - { - message: - "Physics Laboratory for Scientists and Engineers: Electricity and Magnetism (2.00) Please refer to additional important General Information section above", - content: "PHYSICS 4BL", - relationship: "or", - }, - ], + message: + "Elements of Quantum Mechanics and Statistical Mechanics (4.00)", + content: "PHYSICS 17", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Modern Physics Laboratory (4.00)", + content: "PHYSICS 18L", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "CHEMICAL STRUCTURE (4.00)", + content: "CHEM 20A", relationship: "", equivalences: { message: "", content: [ { - message: "Articulates as a Series Only", - content: "", + message: "General Chemistry (5.00)", + content: "CHEM 1A", relationship: "", }, { - message: "Articulates as a Series Only", - content: "", - relationship: "or", + message: "General Chemistry (5.00)", + content: "CHEM 1B", + relationship: "and", }, ], relationship: "", }, }, { - message: "English Composition, Rhetoric, and Language(5.00)", - content: "ENGCOMP 3", - relationship: "", - equivalences: { - message: "Composition and Reading (5.00)", - content: "EWRT 1A", - relationship: "", - }, - }, - { - message: "Select 1 Course(s) from the following", + message: "", content: [ { - message: "One additional course in English composition", - content: "One additional course in English composition", + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1A", + relationship: "", + }, + }, + { + message: + "Differentialand Integral Calculus Laboratory (5.00)", + content: "MATH 31AL", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", + relationship: "and", equivalences: { message: "", content: [ { - message: - "Argumentation: Analysis of Oraland Written Communication (5.00)", - content: "COMM 9", + message: "Calculus (5.00)", + content: "MATH 1B", relationship: "", }, { - message: "Reading, Writing and Research (5.00)", - content: "WRT 1B", - relationship: "or", - }, - { - message: "Reading, Writing and Research - HONORS(5.00)", - content: "EWRT 1BH", - relationship: "or", - }, - { - message: "Literatureand Composition (5.00)", - content: "EWRT 1C", - relationship: "or", - }, - { - message: - "Critical Reading, Writing and Thinking (5.00)", - content: "EWRT 2", - relationship: "or", - }, - { - message: "CriticalThinking and Writing (5.00)", - content: "PHIL 3", - relationship: "or", + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", }, ], relationship: "", }, }, ], - relationship: "and", + relationship: "", + equivalences: "", }, { - message: "Select 1 Course(s) from the following", + message: "", content: [ { - message: "One course in computer programming: C++ preferred", - content: "One course in computer programming: C++ preferred", + message: "Calculus of Several Variables (4.00)", + content: "MATH 32A", relationship: "", - equivalences: { - message: "", - content: [ - { - message: - "Programming in C++ for C/Java Programmers (4.50)", - content: "CIS 27", - relationship: "", - }, - { - message: "Advanced C++ Programming (4.50)", - content: "CIS 29", - relationship: "or", - }, - { - message: "", - content: [ - { - message: - "Beginning Programming Methodologies in C++ (4.50)", - content: "CIS 22A", - relationship: "", - }, - { - message: - "Intermediate Programming Methodologies in C++ - HONORS(4.50)", - content: "CIS 22BH", - relationship: "and", - }, - ], - relationship: "or", - }, - { - message: - "Intermediate Programming Methodologies in C++ (4.50)", - content: "CIS 22B", - relationship: "or", - }, - ], - relationship: "", - }, + }, + { + message: "Calculus of Several Variables (4.00)", + content: "MATH 32B", + relationship: "and", }, ], - relationship: "and", - }, - ], - relationship: "", - }, - { - message: "STRONGLY RECOMMENDED COURSES", - content: [ - { - message: "Introduction to Computer ScienceI (4.00)", - content: "COM SCI 31", - relationship: "", - equivalences: { - message: "", - content: [ - { - message: "", - content: [ - { - message: - "Beginning Programming Methodologies in C++ (4.50)", - content: "CIS 22A", - relationship: "", - }, - { - message: - "Intermediate Programming Methodologies in C++ (4.50)", - content: "CIS 22B", - relationship: "and", - }, - ], - relationship: "", - }, - { - message: "", - content: [ - { - message: - "Beginning Programming Methodologies in C++ (4.50)", - content: "CIS 22A", - relationship: "", - }, - { - message: - "Intermediate Programming Methodologies in C++ - HONORS(4.50)", - content: "CIS 22BH", - relationship: "and", - }, - ], - relationship: "or", - }, - { - message: "Programming in C++ for C/Java Programmers (4.50)", - content: "CIS 27", - relationship: "or", - }, - { - message: - "Intermediate Programming Methodologies in C++ (4.50)", - content: "CIS 22B", - relationship: "or", - }, - ], - relationship: "", - }, - }, - { - message: "Introduction to Computer ScienceII (4.00)", - content: "COM SCI 32", relationship: "", equivalences: { message: "", content: [ { - message: - "Intermediate Programming Methodologies in C++ (4.50)", - content: "CIS 22B", + message: "Calculus (5.00)", + content: "MATH 1C", relationship: "", }, { - message: "Data Abstraction and Structures (4.50)", - content: "CIS 22C", + message: "Calculus (5.00)", + content: "MATH 1D", relationship: "and", }, ], @@ -375,45 +196,22 @@ exports.data = { }, }, { - message: "Introduction to Computer Organization (5.00)", - content: "COM SCI 33", - relationship: "", - equivalences: { - message: "", - content: [ - { - message: - "Introduction to x86 Processor Assembly Languageand Computer Architecture(4.50)", - content: "CIS 21JA", - relationship: "", - }, - { - message: - "Advanced x86 Processor Assembly Programming (4.50)", - content: "CIS 21JB", - relationship: "or", - }, - ], - relationship: "", - }, - }, - { - message: "Logic Design of DigitalSystems (4.00)", - content: "COM SCI M51A", + message: "Linear Algebra and Applications (4.00)", + content: "MATH 33A", relationship: "", equivalences: { - message: "No Course Articulated", - content: "", + message: "Linear Algebra (5.00)", + content: "MATH 2B", relationship: "", }, }, { - message: "Introduction to DiscreteStructures (4.00)", - content: "MATH 61", + message: "DifferentialEquations (4.00)", + content: "MATH 33B", relationship: "", equivalences: { - message: "Discrete Mathematics (5.00)", - content: "MATH 22", + message: "DifferentialEquations (5.00)", + content: "MATH 2A", relationship: "", }, }, @@ -421,12 +219,16 @@ exports.data = { relationship: "", }, ], - "Physics/B.A.": [ + "Mathematics/B.S.": [ { message: "IMPORTANT MAJOR INFORMATION", - content: "This is the major info of physics major of UCLA!", + content: "This is the major info of math major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL RECOMMENDED MAJOR PREPARATION", + content: "This is the additional info of math major of UCLA!", relationship: "", - equivalences: "", }, { message: "LOWER DIVISION MAJOR REQUIREMENTS", @@ -435,33 +237,62 @@ exports.data = { message: "", content: [ { - message: - "Physics for Scientists and Engineers: Mechanics (5.00)", - content: "PHYSICS 1A", + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1A", + relationship: "", + }, }, { message: - "Physics for Scientists and Engineers: Oscillations, Waves, Electricand Magnetic Fields (5.00)", - content: "PHYSICS 1B", - relationship: "and", - }, - { - message: - "Physics for Scientists and Engineers: Electrodynamics, Optics, and Special Relativity (5.00)", - content: "PHYSICS 1C", - relationship: "and", + "Differentialand Integral Calculus Laboratory (5.00)", + content: "MATH 31AL", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, }, + ], + relationship: "", + equivalences: "", + }, + { + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1B", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "", + content: [ { - message: - "Physics Laboratory for Scientists and Engineers: Mechanics (2.00)", - content: "PHYSICS 4AL", - relationship: "and", + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32A", + relationship: "", }, { - message: - "Physics Laboratory for Scientists and Engineers: Electricity and Magnetism (2.00)", - content: "PHYSICS 4BL", + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32B", relationship: "and", }, ], @@ -470,21 +301,13 @@ exports.data = { message: "", content: [ { - message: - "Physics for Scientists and Engineers: Mechanics (6.00)", - content: "PHYS 4A", + message: "Calculus (5.00)", + content: "MATH 1C", relationship: "", }, { - message: - "Physics for Scientists and Engineers: Electricity and Magnetism (6.00)", - content: "PHYS 4B", - relationship: "and", - }, - { - message: - "Physics for Scientists and Engineers: Fluids, Waves, Optics and Thermodynamics (6.00)", - content: "PHYS 4C", + message: "Calculus (5.00)", + content: "MATH 1D", relationship: "and", }, ], @@ -492,278 +315,35 @@ exports.data = { }, }, { - message: - "Elements of Quantum Mechanics and Statistical Mechanics (4.00)", - content: "PHYSICS 17", + message: "Linear Algebra and Applications (4.00)", + content: "MATH 33A", relationship: "", equivalences: { - message: "No Course Articulated", - content: "", + message: "Linear Algebra (5.00)", + content: "MATH 2B", relationship: "", }, }, { - message: "Modern Physics Laboratory (4.00)", - content: "PHYSICS 18L", + message: "DifferentialEquations (4.00) ", + content: "MATH 33B", relationship: "", equivalences: { - message: "No Course Articulated", - content: "", + message: "DifferentialEquations (5.00)", + content: "MATH 2A", relationship: "", }, }, { - message: "CHEMICAL STRUCTURE (4.00)", - content: "CHEM 20A", + message: "Introduction to Programming(C++) (5.00)", + content: "COMPTNG 10A", relationship: "", equivalences: { message: "", content: [ { - message: "General Chemistry (5.00)", - content: "CHEM 1A", - relationship: "", - }, - { - message: "General Chemistry (5.00)", - content: "CHEM 1B", - relationship: "and", - }, - ], - relationship: "", - }, - }, - { - message: "", - content: [ - { - message: "Differentialand Integral Calculus (4.00)", - content: "MATH 31A", - relationship: "", - equivalences: { - message: "Calculus (5.00)", - content: "MATH 1A", - relationship: "", - }, - }, - { - message: - "Differentialand Integral Calculus Laboratory (5.00)", - content: "MATH 31AL", - relationship: "or", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - { - message: "Integration and InfiniteSeries (4.00)", - content: "MATH 31B", - relationship: "and", - equivalences: { - message: "", - content: [ - { - message: "Calculus (5.00)", - content: "MATH 1B", - relationship: "", - }, - { - message: "Calculus (5.00)", - content: "MATH 1C", - relationship: "and", - }, - ], - relationship: "", - }, - }, - ], - relationship: "", - equivalences: "", - }, - { - message: "", - content: [ - { - message: "Calculus of Several Variables (4.00)", - content: "MATH 32A", - relationship: "", - }, - { - message: "Calculus of Several Variables (4.00)", - content: "MATH 32B", - relationship: "and", - }, - ], - relationship: "", - equivalences: { - message: "", - content: [ - { - message: "Calculus (5.00)", - content: "MATH 1C", - relationship: "", - }, - { - message: "Calculus (5.00)", - content: "MATH 1D", - relationship: "and", - }, - ], - relationship: "", - }, - }, - { - message: "Linear Algebra and Applications (4.00)", - content: "MATH 33A", - relationship: "", - equivalences: { - message: "Linear Algebra (5.00)", - content: "MATH 2B", - relationship: "", - }, - }, - { - message: "DifferentialEquations (4.00)", - content: "MATH 33B", - relationship: "", - equivalences: { - message: "DifferentialEquations (5.00)", - content: "MATH 2A", - relationship: "", - }, - }, - ], - relationship: "", - equivalences: "", - }, - ], - "Mathematics/B.S.": [ - { - message: "IMPORTANT MAJOR INFORMATION", - content: "This is the major info of math major of UCLA!", - relationship: "", - }, - { - message: "ADDITIONAL RECOMMENDED MAJOR PREPARATION", - content: "This is the additional info of math major of UCLA!", - relationship: "", - }, - { - message: "LOWER DIVISION MAJOR REQUIREMENTS", - content: [ - { - message: "", - content: [ - { - message: "Differentialand Integral Calculus (4.00)", - content: "MATH 31A", - relationship: "", - equivalences: { - message: "Calculus (5.00)", - content: "MATH 1A", - relationship: "", - }, - }, - { - message: - "Differentialand Integral Calculus Laboratory (5.00)", - content: "MATH 31AL", - relationship: "or", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - ], - relationship: "", - equivalences: "", - }, - { - message: "Integration and InfiniteSeries (4.00)", - content: "MATH 31B", - relationship: "", - equivalences: { - message: "", - content: [ - { - message: "Calculus (5.00)", - content: "MATH 1B", - relationship: "", - }, - { - message: "Calculus (5.00)", - content: "MATH 1C", - relationship: "and", - }, - ], - relationship: "", - }, - }, - { - message: "", - content: [ - { - message: "Calculus ofSeveral Variables (4.00)", - content: "MATH 32A", - relationship: "", - }, - { - message: "Calculus ofSeveral Variables (4.00)", - content: "MATH 32B", - relationship: "and", - }, - ], - relationship: "", - equivalences: { - message: "", - content: [ - { - message: "Calculus (5.00)", - content: "MATH 1C", - relationship: "", - }, - { - message: "Calculus (5.00)", - content: "MATH 1D", - relationship: "and", - }, - ], - relationship: "", - }, - }, - { - message: "Linear Algebra and Applications (4.00)", - content: "MATH 33A", - relationship: "", - equivalences: { - message: "Linear Algebra (5.00)", - content: "MATH 2B", - relationship: "", - }, - }, - { - message: "DifferentialEquations (4.00) ", - content: "MATH 33B", - relationship: "", - equivalences: { - message: "DifferentialEquations (5.00)", - content: "MATH 2A", - relationship: "", - }, - }, - { - message: "Introduction to Programming(C++) (5.00)", - content: "COMPTNG 10A", - relationship: "", - equivalences: { - message: "", - content: [ - { - message: "Programming in C++ for C/Java Programmers (4.50)", - content: "CIS 27", + message: "Programming in C++ for C/Java Programmers (4.50)", + content: "CIS 27", relationship: "", }, { @@ -1131,253 +711,140 @@ exports.data = { relationship: "", }, ], - "Asian American Studies/B.A.": [ + "Computer Science/B.S.": [ { - message: "IMPORTANT MAJOR INFORMATION", + message: "IMPORTANT MAJOR DETAILS", content: - "This is the major info of Asian American Studies major of UCLA!", + "Admission to the Henry Samueli School of Engineering and Applied Sciences at UCLA is highly competitive. The most important selection criteria are completion of the required preparatory courses and academic performance. Listed below are the lower division preparation courses for the major. All applicants must have a minimum transferable cumulative GPA of 3.4. Preparatory courses must be completed by the end of spring prior to fall enrollment. All major courses must be taken for a letter grade. HSSEAS admits students by major and does NOT consider applicants for alternate majors. Applicants are not required to complete the HSSEAS General Education Requirements in order to be admitted, although it is beneficial for students to complete 1 course from each of the following areas: arts, humanities, social sciences, and life sciences. Applicants can fulfill the lower division General Education requirement by completion of the Intersegmental General Transfer Curriculum (IGETC). Partial IGETC is NOT accepted. For more information regarding this major and UCLA's transfer selection process, visit www.admission.ucla.edu. If you still have specific questions, you may email the HSSEAS admissions office at erkki@seas.ucla.edu. PLEASE NOTE: the community college courses listed below have been approved to satisfy the preparation requirements for this major at UCLA, but they may not be exact equivalents of the UCLA courses listed. In addition, upper division requirements for the major may be satisfied by lower division community college course(s) listed below, however specific credit will be determined by the department after transfer.", relationship: "", }, { - message: "ADDITIONAL NOTE", + message: "PROGRAMMING REQUIREMENT", content: - "This is the additional note for Asian American Studies major of UCLA!", + "This is the programming requirement info of cs major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL IMPORTANT GENERAL MAJOR INFORMATION", + content: "ADDITIONAL IMPORTANT GENERAL MAJOR INFORMATION CONTENT", relationship: "", }, { message: "LOWER DIVISION MAJOR REQUIREMENTS", content: [ { - message: "Select 1 Course(s) from the following", - content: [ - { - message: "History of Asian Americans (5.00)", - content: "ASIA AM 10", - relationship: "", - equivalences: { - message: "", - content: [ - { - message: - "Asian American Experience Past and Present (4.00)", - content: "ASAM 1", - relationship: "", - }, - { - message: - "Introduction to Pacific Islander History and Culture(4.00)", - content: "ASAM 31", - relationship: "or", - }, - ], - relationship: "", - }, - }, - { - message: "History of Asian Americans (5.00)", - content: "ASIA AM 10W", - relationship: "or", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - { - message: "Contemporary Asian American Communities (5.00)", - content: "ASIA AM 20", - relationship: "or", - equivalences: { - message: "Contemporary Asian American Communities (4.00)", - content: "ASAM 10", - relationship: "", - }, - }, - { - message: "Contemporary Asian American (5.00)", - content: "ASIA AM 20W", - relationship: "or", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - { - message: "Asian American Literatureand Culture(5.00)", - content: "ASIA AM 30", - relationship: "or", - equivalences: { - message: "", - content: [ - { - message: - "Asian Pacific American Literature(4.00) Same-As: ASAM 20", - content: "ELIT 24", - relationship: "", - }, - { - message: - "Asian Pacific American Literature(4.00) Same-As: ELIT 24", - content: "ASAM 20", - relationship: "or", - }, - ], - relationship: "", - }, - }, - { - message: "Asian American Movement (5.00)", - content: "ASIA AM 40", - relationship: "or", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - { - message: "Asian American Movement (5.00)", - content: "ASIA AM 40W", - relationship: "or", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - { - message: "Asian American Women (5.00)", - content: "ASIA AM 50", - relationship: "or", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - { - message: "Asian American Women (5.00)", - content: "ASIA AM 50W", - relationship: "or", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - ], - relationship: "", - }, - ], - relationship: "", - }, - ], - "Anthropology/B.S.": [ - { - message: "IMPORTANT MAJOR INFORMATION", - content: "This is the major info of Anthropology major of UCLA!", - relationship: "", - }, - { - message: "ADDITIONAL NOTES:", - content: "This is the additional note for Anthropolog major of UCLA!", - relationship: "", - }, - { - message: "LOWER DIVISION MAJOR REQUIREMENTS", - content: [ - { - message: "HUMAN EVOLUTION (5.00)", - content: "ANTHRO 1", - relationship: "", - equivalences: { - message: "Physical Anthropology (4.00)", - content: "ANTH 1", - relationship: "", - }, - }, - { - message: "Archaeology: Introduction (5.00)", - content: "ANTHRO 2", + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", relationship: "", equivalences: { - message: "World Prehistory (4.00)", - content: "ANTH 4", + message: "Calculus (5.00)", + content: "MATH 1A", relationship: "", }, }, { - message: "CULTURE AND SOCIETY (5.00)", - content: "ANTHRO 3", + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", relationship: "", equivalences: { - message: "Cultural Anthropology (4.00)", - content: "ANTH 2", + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1B", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", + }, + ], relationship: "", }, }, { - message: "Cultureand Communication (5.00)", - content: "ANTHRO 4", + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32A", relationship: "", equivalences: { - message: "No Course Articulated", - content: "", + message: "Calculus (5.00)", + content: "MATH 1C", relationship: "", }, }, { - message: "Celland Molecular Biology (5.00)", - content: "LIFESCI 7A", + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32B", relationship: "", equivalences: { - message: "Celland Molecular Biology (6.00)", - content: "BIOL 6B", + message: "Calculus (5.00)", + content: "MATH 1D", relationship: "", }, }, { - message: "Genetics, Evolution, and Ecology (5.00)", - content: "LIFESCI 7B", + message: "Linear Algebra and Applications (4.00)", + content: "MATH 33A", relationship: "", equivalences: { - message: "Ecology and Evolution (6.00)", - content: "BIOL 6C", + message: "Linear Algebra (5.00)", + content: "MATH 2B", relationship: "", }, }, { - message: "Physiology and Human Biology (5.00)", - content: "LIFESCI 7C", + message: "DifferentialEquations (4.00)", + content: "MATH 33B", relationship: "", equivalences: { - message: "Form and Function in the Biological World (6.00)", - content: "BIOL 6A", + message: "DifferentialEquations (5.00)", + content: "MATH 2A", relationship: "", }, }, { - message: - "Introduction to Laboratory and Scientific Methodology (3.00)", - content: "LIFESCI 23L", + message: "", + content: [ + { + message: + "Physics for Scientists and Engineers: Mechanics (5.00)", + content: "PHYSICS 1A", + relationship: "", + }, + { + message: + "Physics for Scientists and Engineers: Oscillations, Waves, Electricand Magnetic Fields (5.00)", + content: "PHYSICS 1B", + relationship: "and", + }, + { + message: + "Physics for Scientists and Engineers: Electrodynamics, Optics, and Special Relativity (5.00)", + content: "PHYSICS 1C", + relationship: "and", + }, + ], relationship: "", equivalences: { message: "", content: [ { - message: "Form and Function in the Biological World (6.00)", - content: "BIOL 6A", + message: + "Physics for Scientists and Engineers: Mechanics (6.00)", + content: "PHYS 4A", relationship: "", }, { - message: "Celland Molecular Biology (6.00)", - content: "BIOL 6B", + message: + "Physics for Scientists and Engineers: Electricity and Magnetism (6.00)", + content: "PHYS 4B", relationship: "and", }, { - message: "Ecology and Evolution (6.00)", - content: "BIOL 6C", + message: + "Physics for Scientists and Engineers: Fluids, Waves, Optics and Thermodynamics (6.00)", + content: "PHYS 4C", relationship: "and", }, ], @@ -1388,18 +855,1388 @@ exports.data = { message: "", content: [ { - message: "CHEMICAL STRUCTURE (4.00)", - content: "CHEM 20A", + message: + "Physics Laboratory for Scientists and Engineers: Mechanics (2.00) Please refer to additional important General Information section above", + content: "PHYSICS 4AL", relationship: "", }, { - message: "ChemicalEnergetics and Change(4.00)", - content: "CHEM 20B", - relationship: "and", + message: + "Physics Laboratory for Scientists and Engineers: Electricity and Magnetism (2.00) Please refer to additional important General Information section above", + content: "PHYSICS 4BL", + relationship: "or", }, - { - message: "General Chemistry Laboratory (3.00)", - content: "CHEM 20L", + ], + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Articulates as a Series Only", + content: "", + relationship: "", + }, + { + message: "Articulates as a Series Only", + content: "", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "English Composition, Rhetoric, and Language(5.00)", + content: "ENGCOMP 3", + relationship: "", + equivalences: { + message: "Composition and Reading (5.00)", + content: "EWRT 1A", + relationship: "", + }, + }, + { + message: "Select 1 Course(s) from the following", + content: [ + { + message: "One additional course in English composition", + content: "", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Argumentation: Analysis of Oraland Written Communication (5.00)", + content: "COMM 9", + relationship: "", + }, + { + message: "Reading, Writing and Research (5.00)", + content: "WRT 1B", + relationship: "or", + }, + { + message: "Reading, Writing and Research - HONORS(5.00)", + content: "EWRT 1BH", + relationship: "or", + }, + { + message: "Literatureand Composition (5.00)", + content: "EWRT 1C", + relationship: "or", + }, + { + message: + "Critical Reading, Writing and Thinking (5.00)", + content: "EWRT 2", + relationship: "or", + }, + { + message: "CriticalThinking and Writing (5.00)", + content: "PHIL 3", + relationship: "or", + }, + ], + relationship: "", + }, + }, + ], + relationship: "and", + }, + { + message: "Select 1 Course(s) from the following", + content: [ + { + message: "One course in computer programming: C++ preferred", + content: "", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Programming in C++ for C/Java Programmers (4.50)", + content: "CIS 27", + relationship: "", + }, + { + message: "Advanced C++ Programming (4.50)", + content: "CIS 29", + relationship: "or", + }, + { + message: "", + content: [ + { + message: + "Beginning Programming Methodologies in C++ (4.50)", + content: "CIS 22A", + relationship: "", + }, + { + message: + "Intermediate Programming Methodologies in C++ - HONORS(4.50)", + content: "CIS 22BH", + relationship: "and", + }, + ], + relationship: "or", + }, + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "or", + }, + ], + relationship: "", + }, + }, + ], + relationship: "and", + }, + ], + relationship: "", + }, + { + message: "STRONGLY RECOMMENDED COURSES", + content: [ + { + message: "Introduction to Computer ScienceI (4.00)", + content: "COM SCI 31", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "", + content: [ + { + message: + "Beginning Programming Methodologies in C++ (4.50)", + content: "CIS 22A", + relationship: "", + }, + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "and", + }, + ], + relationship: "", + }, + { + message: "", + content: [ + { + message: + "Beginning Programming Methodologies in C++ (4.50)", + content: "CIS 22A", + relationship: "", + }, + { + message: + "Intermediate Programming Methodologies in C++ - HONORS(4.50)", + content: "CIS 22BH", + relationship: "and", + }, + ], + relationship: "or", + }, + { + message: "Programming in C++ for C/Java Programmers (4.50)", + content: "CIS 27", + relationship: "or", + }, + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Introduction to Computer ScienceII (4.00)", + content: "COM SCI 32", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Intermediate Programming Methodologies in C++ (4.50)", + content: "CIS 22B", + relationship: "", + }, + { + message: "Data Abstraction and Structures (4.50)", + content: "CIS 22C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "Introduction to Computer Organization (5.00)", + content: "COM SCI 33", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Introduction to x86 Processor Assembly Languageand Computer Architecture(4.50)", + content: "CIS 21JA", + relationship: "", + }, + { + message: + "Advanced x86 Processor Assembly Programming (4.50)", + content: "CIS 21JB", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Logic Design of DigitalSystems (4.00)", + content: "COM SCI M51A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Introduction to DiscreteStructures (4.00)", + content: "MATH 61", + relationship: "", + equivalences: { + message: "Discrete Mathematics (5.00)", + content: "MATH 22", + relationship: "", + }, + }, + ], + relationship: "", + }, + ], + "Asian American Studies/B.A.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: + "This is the major info of Asian American Studies major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL NOTE", + content: + "This is the additional note for Asian American Studies major of UCLA!", + relationship: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "Select 1 Course(s) from the following", + content: [ + { + message: "History of Asian Americans (5.00)", + content: "ASIA AM 10", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Asian American Experience Past and Present (4.00)", + content: "ASAM 1", + relationship: "", + }, + { + message: + "Introduction to Pacific Islander History and Culture(4.00)", + content: "ASAM 31", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "History of Asian Americans (5.00)", + content: "ASIA AM 10W", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Contemporary Asian American Communities (5.00)", + content: "ASIA AM 20", + relationship: "or", + equivalences: { + message: "Contemporary Asian American Communities (4.00)", + content: "ASAM 10", + relationship: "", + }, + }, + { + message: "Contemporary Asian American (5.00)", + content: "ASIA AM 20W", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Asian American Literatureand Culture(5.00)", + content: "ASIA AM 30", + relationship: "or", + equivalences: { + message: "", + content: [ + { + message: + "Asian Pacific American Literature(4.00) Same-As: ASAM 20", + content: "ELIT 24", + relationship: "", + }, + { + message: + "Asian Pacific American Literature(4.00) Same-As: ELIT 24", + content: "ASAM 20", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Asian American Movement (5.00)", + content: "ASIA AM 40", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Asian American Movement (5.00)", + content: "ASIA AM 40W", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Asian American Women (5.00)", + content: "ASIA AM 50", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Asian American Women (5.00)", + content: "ASIA AM 50W", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "", + }, + ], + relationship: "", + }, + ], + "Anthropology/B.S.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: "This is the major info of Anthropology major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL NOTES:", + content: "This is the additional note for Anthropolog major of UCLA!", + relationship: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "HUMAN EVOLUTION (5.00)", + content: "ANTHRO 1", + relationship: "", + equivalences: { + message: "Physical Anthropology (4.00)", + content: "ANTH 1", + relationship: "", + }, + }, + { + message: "Archaeology: Introduction (5.00)", + content: "ANTHRO 2", + relationship: "", + equivalences: { + message: "World Prehistory (4.00)", + content: "ANTH 4", + relationship: "", + }, + }, + { + message: "CULTURE AND SOCIETY (5.00)", + content: "ANTHRO 3", + relationship: "", + equivalences: { + message: "Cultural Anthropology (4.00)", + content: "ANTH 2", + relationship: "", + }, + }, + { + message: "Cultureand Communication (5.00)", + content: "ANTHRO 4", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Celland Molecular Biology (5.00)", + content: "LIFESCI 7A", + relationship: "", + equivalences: { + message: "Celland Molecular Biology (6.00)", + content: "BIOL 6B", + relationship: "", + }, + }, + { + message: "Genetics, Evolution, and Ecology (5.00)", + content: "LIFESCI 7B", + relationship: "", + equivalences: { + message: "Ecology and Evolution (6.00)", + content: "BIOL 6C", + relationship: "", + }, + }, + { + message: "Physiology and Human Biology (5.00)", + content: "LIFESCI 7C", + relationship: "", + equivalences: { + message: "Form and Function in the Biological World (6.00)", + content: "BIOL 6A", + relationship: "", + }, + }, + { + message: + "Introduction to Laboratory and Scientific Methodology (3.00)", + content: "LIFESCI 23L", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Form and Function in the Biological World (6.00)", + content: "BIOL 6A", + relationship: "", + }, + { + message: "Celland Molecular Biology (6.00)", + content: "BIOL 6B", + relationship: "and", + }, + { + message: "Ecology and Evolution (6.00)", + content: "BIOL 6C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: "CHEMICAL STRUCTURE (4.00)", + content: "CHEM 20A", + relationship: "", + }, + { + message: "ChemicalEnergetics and Change(4.00)", + content: "CHEM 20B", + relationship: "and", + }, + { + message: "General Chemistry Laboratory (3.00)", + content: "CHEM 20L", + relationship: "and", + }, + { + message: "General Chemistry Laboratory II (4.00)", + content: "CHEM 30AL", + relationship: "and", + }, + ], + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "General Chemistry (5.00)", + content: "CHEM 1A", + relationship: "", + }, + { + message: "General Chemistry (5.00)", + content: "CHEM 1B", + relationship: "and", + }, + { + message: + "General Chemistry and Qualitative Analysis (5.00)", + content: "CHEM 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "Organic Chemistry I: Structureand Reactivity (4.00)", + content: "CHEM 30A", + relationship: "", + equivalences: { + message: "Organic Chemistry (5.00)", + content: "CHEM 12A", + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: "", + content: [ + { + message: "Calculus for LifeSciences Students (4.00)", + content: "MATH 3A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Calculus for LifeSciences Students (4.00)", + content: "MATH 3B", + relationship: "and", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Ordinary DifferentialEquations With Linear Algebra for LifeSciences Students (4.00)", + content: "MATH 3C", + relationship: "and", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Introduction to Statistical Methods for Geography and EnvironmentalStudies (5.00) -Acceptable substitute", + content: "STATS 12", + relationship: "and", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: "", + content: [ + { + message: "", + content: [ + { + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", + relationship: "", + equivalences: { + message: "Calculus (5.00)", + content: "MATH 1A", + relationship: "", + }, + }, + { + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", + relationship: "and", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1B", + relationship: "", + }, + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: + "Introduction to Statistical Methods for Geography and EnvironmentalStudies (5.00) -Acceptable substitute", + content: "STATS 12", + relationship: "and", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: "", + content: [ + { + message: "Mathematics for LifeScientists (5.00)", + content: "LIFESCI 30A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Mathematics for LifeScientists (5.00)", + content: "LIFESCI 30B", + relationship: "and", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Introduction to Statistical Methods for Lifeand Health Sciences (5.00) -Acceptable substitute", + content: "STATS 13", + relationship: "and", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + { + message: + "Physics for LifeSciences Majors: Mechanics, and Energy (5.00)", + content: "PHYSICS 5A", + relationship: "", + equivalences: { + message: "General Introductory Physics (5.00)", + content: "PHYS 2A", + relationship: "", + }, + }, + { + message: + "Physics for LifeSciences Majors: Thermodynamics, Fluids, Waves, Light, and Optics (5.00)", + content: "PHYSICS 5B", + relationship: "and", + equivalences: { + message: "General Introductory Physics (5.00)", + content: "PHYS 2B", + relationship: "", + }, + }, + { + message: + "Physics for LifeSciences Majors: Electricity, Magnetism, and Modern Physics (5.00)", + content: "PHYSICS 5C", + relationship: "", + equivalences: { + message: "General Introductory Physics (5.00)", + content: "PHYS 2C", + relationship: "", + }, + }, + ], + relationship: "or", + }, + ], + relationship: "or", + }, + ], + relationship: "", + }, + ], + relationship: "", + }, + ], + "Labor Studies/B.A.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: "This is the major info of Labor Studies major of UCLA!", + relationship: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "", + content: [ + { + message: "Introduction to Labor and WorkplaceStudies (5.00)", + content: "LBR & WS 10", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Select 2 Course(s) from the following", + content: [ + { + message: "Introduction to Black Studies (5.00)", + content: "AF AMER 1", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Social Organization of Black Communities (5.00) Same-As: AF AMER M5", + content: "SOCIOL M5", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "History of Asian Americans (5.00)", + content: "ASIA AM 10", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Asian American Experience Past and Present (4.00)", + content: "ASAM 1", + relationship: "", + }, + { + message: + "Introduction to Pacific Islander History and Culture (4.00)", + content: "ASAM 31", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Contemporary Asian American Communities (5.00)", + content: "ASIA AM 20", + relationship: "", + equivalences: { + message: + "Contemporary Asian American Communities (4.00)", + content: "ASAM 10", + relationship: "", + }, + }, + { + message: "Asian American Movement (5.00)", + content: "ASIA AM 40", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Asian American Women (5.00)", + content: "ASIA AM 50", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Introduction to Chicana/Chicano Studies: Social Structureand Contemporary Conditions (5.00)", + content: "CHICANO 10B", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Introduction to Gender Studies (5.00)", + content: "GENDER 10", + relationship: "", + equivalences: { + message: "Introduction to Women's Studies (4.00)", + content: "WMST 1", + relationship: "", + }, + }, + { + message: + "Globalization: Regional Development and World Economy (5.00)", + content: "GEOG 4", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Social Knowledgeand Social Power (5.00)", + content: "HIST 2B", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Modern Latin America (5.00)", + content: "HIST 8B", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Inequality: History of Mass Imprisonment (5.00)", + content: "HIST 12A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Inequality: History of Neoliberalism (5.00)", + content: "HIST 12B", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Inequality: Global History of Anti-ColonialThought and Struggle(5.00)", + content: "HIST 12C", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Community and Labor Development from Ground Up (4.00)", + content: "HNRS 82", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Ethics and Governance(5.00) ", + content: "POL SCI 60", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Introduction to Public Policy (5.00)", + content: "PUB PLC 10A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "California Policy Issues (4.00)", + content: "PUB PLC 10B", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Latin American Cultures (5.00)", + content: "SPAN 44", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "and", + }, + ], + relationship: "", + }, + { + message: "Select 2 Course(s) from the following", + content: [ + { + message: "Work, Labor, and Social Justicein U.S. (6.00)", + content: "CLUSTER M24A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Work, Labor, and Social Justice(6.00)", + content: "CLUSTER 24B", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Work, Labor and Social Justice(6.00)", + content: "CLUSTER 24C", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "or", + }, + ], + relationship: "", + }, + ], + "Global Studies/B.A.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: "This is the major info of Global Studies major of UCLA!", + relationship: "", + }, + { message: "AP CREDIT", content: "AP CREDIT info", relationship: "" }, + { + message: "FOREIGN LANGUAGE REQUIREMENT", + content: "FOREIGN LANGUAGE REQUIREMENT info", + relationship: "", + }, + { + message: "ADDITIONAL NOTES:", + content: "ADDITIONAL NOTES: for Global Studies", + relationship: "", + }, + { + message: "METHODS COURSE", + content: [ + { + message: "Select 1 Course(s) from the following", + content: [ + { + message: "Introduction to Data Analysis (5.00)", + content: "POL SCI 6", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Introduction to Data Analysis- Research Version (5.00)", + content: "POL SCI 6R", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Politics and Strategy (5.00)", + content: "POL SCI 30", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Introduction to Statistical Reasoning (5.00)", + content: "STATS 10", + relationship: "or", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, + { + message: "One Introductory Statistics Course", + content: "", + relationship: "or", + equivalences: { + message: "", + content: [ + { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + { + message: "Introductory Statistics - HONORS(5.00)", + content: "MATH 10H", + relationship: "or", + }, + { + message: "Engineering Statistics (5.00)", + content: "MATH 23", + relationship: "or", + }, + { + message: + "Statistics and Research Methods in SocialScience(4.00) Same-As: SOC 15", + content: "PSYC 15", + relationship: "or", + }, + ], + relationship: "", + }, + }, + ], + relationship: "", + }, + ], + relationship: "", + }, + { + message: "GOVERNANCE AND CONFLICT", + content: [ + { + message: "History of Africa, 1800 to Present (5.00)", + content: "HIST 10B", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Contemporary World History, 1760 to Present (5.00)", + content: "HIST 22", + relationship: "or", + equivalences: { + message: "World History from 1750 CE to the Present (4.00)", + content: "HIST 3C", + relationship: "", + }, + }, + { + message: "Introduction to PoliticalTheory (5.00)", + content: "POL SCI 10", + relationship: "or", + equivalences: { + message: "Introduction to PoliticalThought and Theory (4.00)", + content: "POLI 5", + relationship: "", + }, + }, + { + message: "WORLD POLITICS(5.00)", + content: "POL SCI 20", + relationship: "or", + equivalences: { + message: "International Relations (4.00)", + content: "POLI 3", + relationship: "", + }, + }, + { + message: "Introduction to Comparative Politics (5.00)", + content: "POL SCI 50", + relationship: "or", + equivalences: { + message: "Comparative Politics (4.00)", + content: "POLI 2", + relationship: "", + }, + }, + { + message: "Introductory Sociology (5.00) ", + content: "SOCIOL 1", + relationship: "or", + equivalences: { + message: "Introduction to Sociology (4.00)", + content: "SOC 1", + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: "MARKET/RESOURCES", + content: [ + { + message: "Principles ofEconomics(Microeconomics) (4.00)", + content: "ECON 1", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Principles of Microeconomics (4.00)", + content: "ECON 2", + relationship: "", + }, + { + message: "Principles of Microeconomics - HONORS(4.00)", + content: "ECON 2H", + relationship: "or", + }, + ], + relationship: "", + }, + }, + { + message: "Principles ofEconomics(Macroeconomics) (4.00)", + content: "ECON 2", + relationship: "or", + equivalences: { + message: "Principles of Macroeconomics (4.00)", + content: "ECON 1", + relationship: "", + }, + }, + { + message: "Sustainability and Environment (4.00)", + content: "ENVIRON 12", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Sociology of Migration (5.00)", + content: "SOCIOL 51", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: + "Globalization: Regional Development and World Economy (5.00)", + content: "GEOG 4", + relationship: "or", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "", + }, + ], + "Psychobiology/B.S.": [ + { + message: "IMPORTANT MAJOR INFORMATION", + content: "This is the major info of Psychobiology major of UCLA!", + relationship: "", + }, + { + message: "ADDITIONAL NOTES", + content: "ADDITIONAL NOTES: for Psychobiology", + relationship: "", + }, + { + message: "LOWER DIVISION MAJOR REQUIREMENTS", + content: [ + { + message: "Introductory Psychology (4.00)", + content: "PSYCH 10", + relationship: "", + equivalences: { + message: "General Psychology (4.00)", + content: "PSYC 1", + relationship: "", + }, + }, + { + message: "Celland Molecular Biology (5.00)", + content: "LIFESCI 7A", + relationship: "", + equivalences: { + message: "Celland Molecular Biology (6.00)", + content: "BIOL 6B", + relationship: "", + }, + }, + { + message: "Genetics, Evolution, and Ecology (5.00)", + content: "LIFESCI 7B", + relationship: "", + equivalences: { + message: "Ecology and Evolution (6.00)", + content: "BIOL 6C", + relationship: "", + }, + }, + { + message: "Physiology and Human Biology (5.00)", + content: "LIFESCI 7C", + relationship: "", + equivalences: { + message: "Form and Function in the Biological World (6.00)", + content: "BIOL 6A", + relationship: "", + }, + }, + { + message: + "Introduction to Laboratory and Scientific Methodology (3.00)", + content: "LIFESCI 23L", + relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Form and Function in the Biological World (6.00)", + content: "BIOL 6A", + relationship: "", + }, + { + message: "Celland Molecular Biology (6.00)", + content: "BIOL 6B", + relationship: "and", + }, + { + message: "Ecology and Evolution (6.00)", + content: "BIOL 6C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + { + message: "", + content: [ + { + message: "CHEMICAL STRUCTURE (4.00)", + content: "CHEM 20A", + relationship: "", + }, + { + message: "ChemicalEnergetics and Change(4.00)", + content: "CHEM 20B", + relationship: "and", + }, + { + message: "General Chemistry Laboratory (3.00)", + content: "CHEM 20L", relationship: "and", }, { @@ -1432,19 +2269,56 @@ exports.data = { relationship: "", }, }, - { - message: "Organic Chemistry I: Structureand Reactivity (4.00)", - content: "CHEM 30A", - relationship: "", - equivalences: { - message: "Organic Chemistry (5.00)", - content: "CHEM 12A", - relationship: "", - }, - }, { message: "", content: [ + { + message: "", + content: [ + { + message: "Mathematics for LifeScientists (5.00)", + content: "LIFESCI 30A", + relationship: "", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Mathematics for LifeScientists (5.00)", + content: "LIFESCI 30B", + relationship: "and", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + { + message: "Statisitics of BiologicalSystems (5.00)", + content: "LIFESCI 40", + relationship: "and", + equivalences: { + message: "No Course Articulated", + content: "", + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: + "Introduction to Statistical Methods for Lifeand Health Sciences (5.00) -Acceptable substitute", + content: "STATS 13", + relationship: "or", + equivalences: { + message: "Introductory Statistics (5.00)", + content: "MATH 10", + relationship: "", + }, + }, { message: "", content: [ @@ -1479,146 +2353,203 @@ exports.data = { relationship: "", }, }, + ], + relationship: "or", + }, + { + message: "", + content: [ + { + message: "Differentialand Integral Calculus (4.00)", + content: "MATH 31A", + relationship: "", + }, { - message: - "Introduction to Statistical Methods for Geography and EnvironmentalStudies (5.00) -Acceptable substitute", - content: "STATS 12", + message: "Integration and InfiniteSeries (4.00)", + content: "MATH 31B", relationship: "and", - equivalences: { - message: "Introductory Statistics (5.00)", - content: "MATH 10", + }, + { + message: "Calculus ofSeveral Variables (4.00)", + content: "MATH 32A", + relationship: "and", + }, + ], + relationship: "or", + equivalences: { + message: "", + content: [ + { + message: "Calculus (5.00)", + content: "MATH 1A", relationship: "", }, + { + message: "Calculus (5.00)", + content: "MATH 1B", + relationship: "and", + }, + { + message: "Calculus (5.00)", + content: "MATH 1C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: "", + content: [ + { + message: "", + content: [ + { + message: + "Physics for Scientists and Engineers: Mechanics (5.00)", + content: "PHYSICS 1A", + relationship: "", + }, + { + message: + "Physics for Scientists and Engineers: Oscillations, Waves, Electricand Magnetic Fields (5.00)", + content: "PHYSICS 1B", + relationship: "and", + }, + { + message: + "Physics for Scientists and Engineers: Electrodynamics, Optics, and Special Relativity (5.00)", + content: "PHYSICS 1C", + relationship: "and", + }, + { + message: + "Physics Laboratory for Scientists and Engineers: Mechanics (2.00)", + content: "PHYSICS 4AL", + relationship: "and", + }, + { + message: + "Physics Laboratory for Scientists and Engineers: Electricity and Magnetism (2.00) -Articulates as a sequence only", + content: "PHYSICS 4BL", + relationship: "and", }, ], relationship: "", + equivalences: { + message: "", + content: [ + { + message: + "Physics for Scientists and Engineers: Mechanics (6.00)", + content: "PHYS 4A", + relationship: "", + }, + { + message: + "Physics for Scientists and Engineers: Electricity and Magnetism (6.00)", + content: "PHYS 4B", + relationship: "and", + }, + { + message: + "Physics for Scientists and Engineers: Fluids, Waves, Optics and Thermodynamics (6.00)", + content: "PHYS 4C", + relationship: "and", + }, + ], + relationship: "", + }, }, { message: "", content: [ { - message: "", - content: [ - { - message: "Differentialand Integral Calculus (4.00)", - content: "MATH 31A", - relationship: "", - equivalences: { - message: "Calculus (5.00)", - content: "MATH 1A", - relationship: "", - }, - }, - { - message: "Integration and InfiniteSeries (4.00)", - content: "MATH 31B", - relationship: "and", - equivalences: { - message: "", - content: [ - { - message: "Calculus (5.00)", - content: "MATH 1B", - relationship: "", - }, - { - message: "Calculus (5.00)", - content: "MATH 1C", - relationship: "and", - }, - ], - relationship: "", - }, - }, - { - message: - "Introduction to Statistical Methods for Geography and EnvironmentalStudies (5.00) -Acceptable substitute", - content: "STATS 12", - relationship: "and", - equivalences: { - message: "Introductory Statistics (5.00)", - content: "MATH 10", - relationship: "", - }, - }, - ], + message: + "Physics for LifeSciences Majors: Mechanics, and Energy (5.00)", + content: "PHYSICS 5A", relationship: "", }, { - message: "", - content: [ - { - message: "Mathematics for LifeScientists (5.00)", - content: "LIFESCI 30A", - relationship: "", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - { - message: "Mathematics for LifeScientists (5.00)", - content: "LIFESCI 30B", - relationship: "and", - equivalences: { - message: "No Course Articulated", - content: "", - relationship: "", - }, - }, - { - message: - "Introduction to Statistical Methods for Lifeand Health Sciences (5.00) -Acceptable substitute", - content: "STATS 13", - relationship: "and", - equivalences: { - message: "Introductory Statistics (5.00)", - content: "MATH 10", - relationship: "", - }, - }, - { - message: - "Physics for LifeSciences Majors: Mechanics, and Energy (5.00)", - content: "PHYSICS 5A", - relationship: "", - equivalences: { - message: "General Introductory Physics (5.00)", - content: "PHYS 2A", - relationship: "", - }, - }, - { - message: - "Physics for LifeSciences Majors: Thermodynamics, Fluids, Waves, Light, and Optics (5.00)", - content: "PHYSICS 5B", - relationship: "and", - equivalences: { - message: "General Introductory Physics (5.00)", - content: "PHYS 2B", - relationship: "", - }, - }, - { - message: - "Physics for LifeSciences Majors: Electricity, Magnetism, and Modern Physics (5.00)", - content: "PHYSICS 5C", - relationship: "", - equivalences: { - message: "General Introductory Physics (5.00)", - content: "PHYS 2C", - relationship: "", - }, - }, - ], - relationship: "or", + message: + "Physics for LifeSciences Majors: Thermodynamics, Fluids, Waves, Light, and Optics (5.00)", + content: "PHYSICS 5B", + relationship: "and", + }, + { + message: + "Physics for LifeSciences Majors: Electricity, Magnetism, and Modern Physics (5.00)", + content: "PHYSICS 5C", + relationship: "and", }, ], relationship: "or", + equivalences: { + message: "", + content: [ + { + message: "General Introductory Physics (5.00)", + content: "PHYS 2A", + relationship: "", + }, + { + message: "General Introductory Physics (5.00)", + content: "PHYS 2B", + relationship: "and", + }, + { + message: "General Introductory Physics (5.00)", + content: "PHYS 2C", + relationship: "and", + }, + ], + relationship: "", + }, + }, + ], + relationship: "", + }, + { + message: "", + content: [ + { + message: + "Organic Chemistry I: Structureand Reactivity (4.00)", + content: "CHEM 30A", + relationship: "", + }, + { + message: + "Organic Chemistry II: Reactivity, Synthesis, and Spectroscopy (4.00)", + content: "CHEM 30B", + relationship: "and", + }, + { + message: "Organic Chemistry Laboratory I (3.00)", + content: "CHEM 30BL", + relationship: "and", }, ], relationship: "", + equivalences: { + message: "", + content: [ + { + message: "Organic Chemistry (5.00)", + content: "CHEM 12A", + relationship: "", + }, + { + message: "Organic Chemistry (5.00)", + content: "CHEM 12B", + relationship: "and", + }, + ], + relationship: "", + }, }, ], relationship: "", From c25f1622d864a209de16add225da00a11fcc74da Mon Sep 17 00:00:00 2001 From: biankaiwen111 Date: Tue, 13 Jul 2021 21:22:09 -0700 Subject: [PATCH 11/11] feature: basic agreement functionality --- package-lock.json | 143 +++++++++++++ package.json | 1 + src/pages/agreement/Agreement.js | 304 +++++++++------------------ src/pages/agreement/ShowAgreement.js | 210 ++++++++++++++++++ 4 files changed, 455 insertions(+), 203 deletions(-) create mode 100644 src/pages/agreement/ShowAgreement.js diff --git a/package-lock.json b/package-lock.json index 0f81f4e..a286c9f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1202,6 +1202,94 @@ "resolved": "https://registry.npmjs.org/@csstools/normalize.css/-/normalize.css-10.1.0.tgz", "integrity": "sha512-ij4wRiunFfaJxjB0BdrYHIH8FxBJpOwNPhhAcunlmPdXudL1WQV1qoP9un6JsEBAgQH+7UXyyjh0g7jTxXK6tg==" }, + "@emotion/cache": { + "version": "10.0.29", + "resolved": "https://registry.nlark.com/@emotion/cache/download/@emotion/cache-10.0.29.tgz", + "integrity": "sha1-h+fmT0EsBgEC1Yn+fG3AQub50eA=", + "requires": { + "@emotion/sheet": "0.9.4", + "@emotion/stylis": "0.8.5", + "@emotion/utils": "0.11.3", + "@emotion/weak-memoize": "0.2.5" + } + }, + "@emotion/core": { + "version": "10.1.1", + "resolved": "https://registry.npm.taobao.org/@emotion/core/download/@emotion/core-10.1.1.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40emotion%2Fcore%2Fdownload%2F%40emotion%2Fcore-10.1.1.tgz", + "integrity": "sha1-yVbBNl8vJIGWAGS8uMRzLl+2EsM=", + "requires": { + "@babel/runtime": "^7.5.5", + "@emotion/cache": "^10.0.27", + "@emotion/css": "^10.0.27", + "@emotion/serialize": "^0.11.15", + "@emotion/sheet": "0.9.4", + "@emotion/utils": "0.11.3" + } + }, + "@emotion/css": { + "version": "10.0.27", + "resolved": "https://registry.npm.taobao.org/@emotion/css/download/@emotion/css-10.0.27.tgz", + "integrity": "sha1-OnRYGY+767U7AbK4f2Tl4hJB4Uw=", + "requires": { + "@emotion/serialize": "^0.11.15", + "@emotion/utils": "0.11.3", + "babel-plugin-emotion": "^10.0.27" + } + }, + "@emotion/hash": { + "version": "0.8.0", + "resolved": "https://registry.npm.taobao.org/@emotion/hash/download/@emotion/hash-0.8.0.tgz", + "integrity": "sha1-u7/2iXj+/b5ozLUzvIy+HRr7VBM=" + }, + "@emotion/memoize": { + "version": "0.7.4", + "resolved": "https://registry.npm.taobao.org/@emotion/memoize/download/@emotion/memoize-0.7.4.tgz", + "integrity": "sha1-Gb8PWvGRSREcQNmLsM+CEZ9dnus=" + }, + "@emotion/serialize": { + "version": "0.11.16", + "resolved": "https://registry.npm.taobao.org/@emotion/serialize/download/@emotion/serialize-0.11.16.tgz", + "integrity": "sha1-3uBfnpatL7JaUga211my0e0zea0=", + "requires": { + "@emotion/hash": "0.8.0", + "@emotion/memoize": "0.7.4", + "@emotion/unitless": "0.7.5", + "@emotion/utils": "0.11.3", + "csstype": "^2.5.7" + }, + "dependencies": { + "csstype": { + "version": "2.6.17", + "resolved": "https://registry.nlark.com/csstype/download/csstype-2.6.17.tgz", + "integrity": "sha1-TPMOuH4dGgBdi2UQ+VKSQT9qHA4=" + } + } + }, + "@emotion/sheet": { + "version": "0.9.4", + "resolved": "https://registry.npm.taobao.org/@emotion/sheet/download/@emotion/sheet-0.9.4.tgz", + "integrity": "sha1-iUN0vqOeww9Im7/DQ4GSuXdNMuU=" + }, + "@emotion/stylis": { + "version": "0.8.5", + "resolved": "https://registry.npm.taobao.org/@emotion/stylis/download/@emotion/stylis-0.8.5.tgz?cache=0&sync_timestamp=1577056415075&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40emotion%2Fstylis%2Fdownload%2F%40emotion%2Fstylis-0.8.5.tgz", + "integrity": "sha1-3qyzib1u530ef8rMzp4WxcfnjgQ=" + }, + "@emotion/unitless": { + "version": "0.7.5", + "resolved": "https://registry.npm.taobao.org/@emotion/unitless/download/@emotion/unitless-0.7.5.tgz", + "integrity": "sha1-dyESkcGQCnALinjPr9oxYNdpSe0=" + }, + "@emotion/utils": { + "version": "0.11.3", + "resolved": "https://registry.npm.taobao.org/@emotion/utils/download/@emotion/utils-0.11.3.tgz", + "integrity": "sha1-p1mGOGe++n5YNADTImUqP0SCCSQ=" + }, + "@emotion/weak-memoize": { + "version": "0.2.5", + "resolved": "https://registry.npm.taobao.org/@emotion/weak-memoize/download/@emotion/weak-memoize-0.2.5.tgz", + "integrity": "sha1-ju2YLi7m9/TkTCU+EpYpgHke/UY=" + }, "@eslint/eslintrc": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-0.4.0.tgz", @@ -3266,6 +3354,23 @@ "object.assign": "^4.1.0" } }, + "babel-plugin-emotion": { + "version": "10.2.2", + "resolved": "https://registry.npm.taobao.org/babel-plugin-emotion/download/babel-plugin-emotion-10.2.2.tgz", + "integrity": "sha1-of41A8/4Cr/QvdoUq9Lo5Xp50X0=", + "requires": { + "@babel/helper-module-imports": "^7.0.0", + "@emotion/hash": "0.8.0", + "@emotion/memoize": "0.7.4", + "@emotion/serialize": "^0.11.16", + "babel-plugin-macros": "^2.0.0", + "babel-plugin-syntax-jsx": "^6.18.0", + "convert-source-map": "^1.5.0", + "escape-string-regexp": "^1.0.5", + "find-root": "^1.1.0", + "source-map": "^0.5.7" + } + }, "babel-plugin-istanbul": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.0.0.tgz", @@ -3352,6 +3457,11 @@ "@babel/helper-define-polyfill-provider": "^0.2.0" } }, + "babel-plugin-syntax-jsx": { + "version": "6.18.0", + "resolved": "https://registry.npm.taobao.org/babel-plugin-syntax-jsx/download/babel-plugin-syntax-jsx-6.18.0.tgz", + "integrity": "sha1-CvMqmm4Tyno/1QaeYtew9Y0NiUY=" + }, "babel-plugin-syntax-object-rest-spread": { "version": "6.13.0", "resolved": "https://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz", @@ -6675,6 +6785,11 @@ "pkg-dir": "^3.0.0" } }, + "find-root": { + "version": "1.1.0", + "resolved": "https://registry.npm.taobao.org/find-root/download/find-root-1.1.0.tgz", + "integrity": "sha1-q8/Iunb3CMQql7PWhbfpRQv7nOQ=" + }, "find-up": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", @@ -10188,6 +10303,11 @@ "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=" }, + "memoize-one": { + "version": "5.2.1", + "resolved": "https://registry.nlark.com/memoize-one/download/memoize-one-5.2.1.tgz", + "integrity": "sha1-gzeqPEM1WBg57AHD1ZQJDOvo8A4=" + }, "memory-fs": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/memory-fs/-/memory-fs-0.4.1.tgz", @@ -12787,6 +12907,14 @@ "resolved": "https://registry.npmjs.org/react-error-overlay/-/react-error-overlay-6.0.9.tgz", "integrity": "sha512-nQTTcUu+ATDbrSD1BZHr5kgSD4oF8OFjxun8uAaL8RwPBacGBNPf/yAuVVdx17N8XNzRDMrZ9XcKZHCjPW+9ew==" }, + "react-input-autosize": { + "version": "2.2.2", + "resolved": "https://registry.npm.taobao.org/react-input-autosize/download/react-input-autosize-2.2.2.tgz?cache=0&sync_timestamp=1607939981071&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Freact-input-autosize%2Fdownload%2Freact-input-autosize-2.2.2.tgz", + "integrity": "sha1-/KpwIFaOwga8BL429Oto5kfE2MI=", + "requires": { + "prop-types": "^15.5.8" + } + }, "react-is": { "version": "16.13.1", "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", @@ -12942,6 +13070,21 @@ "workbox-webpack-plugin": "5.1.4" } }, + "react-select": { + "version": "3.1.0", + "resolved": "https://registry.nlark.com/react-select/download/react-select-3.1.0.tgz", + "integrity": "sha1-qwmHILLp/idQR8mT8NDK9d7RfCc=", + "requires": { + "@babel/runtime": "^7.4.4", + "@emotion/cache": "^10.0.9", + "@emotion/core": "^10.0.9", + "@emotion/css": "^10.0.9", + "memoize-one": "^5.0.0", + "prop-types": "^15.6.0", + "react-input-autosize": "^2.2.2", + "react-transition-group": "^4.3.0" + } + }, "react-transition-group": { "version": "4.4.1", "resolved": "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.1.tgz", diff --git a/package.json b/package.json index 6e135a1..0187f9a 100644 --- a/package.json +++ b/package.json @@ -19,6 +19,7 @@ "react-router": "^5.2.0", "react-router-dom": "^5.2.0", "react-scripts": "4.0.3", + "react-select": "^3.1.0", "web-vitals": "^1.1.2" }, "scripts": { diff --git a/src/pages/agreement/Agreement.js b/src/pages/agreement/Agreement.js index 778e1bb..51575fa 100644 --- a/src/pages/agreement/Agreement.js +++ b/src/pages/agreement/Agreement.js @@ -1,209 +1,107 @@ -import React from "react"; - +import React, { useState, useRef } from "react"; +import Select from "react-select"; +import { Form, Button } from "react-bootstrap"; +import ShowAgreement from "./ShowAgreement"; const { data } = require("./exampleData"); -export default function Agreement() { - const renderRect = (obj) => { - if ( - typeof obj["content"] === "string" || - obj["content"] instanceof String - ) { - let relationshipKeyword = null; - { - if ("relationship" in obj && obj["relationship"] !== "") { - relationshipKeyword = ( -
{obj["relationship"]}
- ); - } - } - let foundEq = false; - let needBorder = false; - let equalRect = []; - if ("equivalences" in obj && obj["equivalences"] !== "") { - //console.log(obj["equivalences"]); - foundEq = true; - equalRect = renderEq(obj["equivalences"]); - } - - let result = null; - if ("equivalences" in obj) { - needBorder = true; - } - - if (needBorder) { - result = ( - -
-
-
-
- {relationshipKeyword ? relationshipKeyword : null} -
-
{`${obj["content"]} - ${obj["message"]}`}
-
-
-
- {relationshipKeyword ? relationshipKeyword : null} - {equalRect} -
-
-
-
- ); - } else { - result = ( - - {relationshipKeyword ? relationshipKeyword : null} -
-
{`${obj["content"]} - ${obj["message"]}`}
-
- {equalRect} -
- ); - } - - return result; - } else { - //console.log(typeof obj["content"]); - const rect = []; - - for (const component of obj["content"]) { - const courseRect = renderRect(component, true); - rect.push(courseRect); - } - - let equalRect = []; - let foundEql = false; - if ("equivalences" in obj && obj["equivalences"] !== "") { - //console.log(obj["equivalences"]); - foundEql = true; - equalRect = renderEq(obj["equivalences"]); - } - - let needTitle = false; - if (obj["message"] !== "") { - needTitle = true; - } - - if (foundEql) { - return ( - -
- {needTitle &&

{obj["message"]}

} -
-
-
-
{obj["relationship"]}
-
- {rect} -
-
-
-
{obj["relationship"]}
- {equalRect} -
-
-
-
- ); - } - - let flag = true; - if (equalRect.length === 0) { - flag = false; - } - - return ( - -
-
{obj["relationship"]}
- {needTitle &&

{obj["message"]}

} -
{rect}
- {flag && ( -
{obj["relationship"]}
- )} - {equalRect} -
- ); - } +const universityList = [ + { label: "UCLA", value: "UCLA" }, + { label: "UC Berkeley", value: "UC Berkeley" }, + { label: "UCSD", value: "UCSD" }, +]; + +const ccList = [ + { label: "DeAnza College", value: "DeAnza College" }, + { label: "Foothill College", value: "Foothill College" }, +]; + +//this can be done by ajax +const majorList = [ + { label: "Physics/B.A.", value: "Physics/B.A." }, + { label: "Mathematics/B.S.", value: "Mathematics/B.S." }, + { label: "Data Theory/B.S.", value: "Data Theory/B.S." }, + { label: "Computer Science/B.S.", value: "Computer Science/B.S." }, + { + label: "Asian American Studies/B.A.", + value: "Asian American Studies/B.A.", + }, + { label: "Anthropology/B.S.", value: "Anthropology/B.S." }, + { label: "Labor Studies/B.A.", value: "Labor Studies/B.A." }, + { label: "Global Studies/B.A.", value: "Global Studies/B.A." }, + { label: "Psychobiology/B.S.", value: "Psychobiology/B.S." }, +]; + +function Agreement() { + const [onSearchTab, setOnSearchTab] = useState(true); + const [loadingMajor, setLoadingMajor] = useState(false); + + const [university, setUniversity] = useState(""); + const [cc, setCc] = useState(""); + const [major, setMajor] = useState(""); + const [agreement, setAgreement] = useState([]); + + const univRef = useRef(); + const ccRef = useRef(); + const majorRef = useRef(); + + const searchHandler = (event) => { + console.log(university, cc, major); + //fetch Data from DB, suppose we have data here + + setAgreement(data["UCLA"]["DeAnza College"][major]); + setOnSearchTab(false); }; - const renderEq = (obj) => { - if ( - typeof obj["content"] === "string" || - obj["content"] instanceof String - ) { - let relationshipKeyword = null; - { - if ("relationship" in obj && obj["relationship"] !== "") { - //console.log(obj["relationship"]); - relationshipKeyword = ( -
{obj["relationship"]}
- ); - } - } - - return ( - - {relationshipKeyword ? relationshipKeyword : null} -
-
{`${obj["content"]} - ${obj["message"]}`}
-
-
- ); - } else { - const rect = []; - for (const component of obj["content"]) { - const courseRect = renderEq(component); - rect.push(courseRect); - } - - let relationshipKeyword = null; - { - if ("relationship" in obj && obj["relationship"] !== "") { - relationshipKeyword = ( -
{obj["relationship"]}
- ); - } - } - - return ( - - {relationshipKeyword ? relationshipKeyword : null} -
{rect}
-
- ); - } - }; - - const rawWholeAgreement = data["UCLA"]["DeAnza College"]["Physics/B.A."]; - - const wholeAgreement = []; - - for (const section of rawWholeAgreement) { - if ( - typeof section["content"] === "string" || - section["content"] instanceof String - ) { - wholeAgreement.push( -
-

{section["message"]}

-

-
- ); - } else { - wholeAgreement.push(renderRect(section)); - } + if (onSearchTab) { + return ( +
+ + { + setCc(e.value); + }} + /> + +