Skip to content

Commit

Permalink
Merge branch 'development' of https://github.com/gustavomm19/app into…
Browse files Browse the repository at this point in the history
… saas-courses
  • Loading branch information
gustavomm19 committed Sep 19, 2024
2 parents c31e21c + 3d736f4 commit 0b9a381
Show file tree
Hide file tree
Showing 72 changed files with 3,285 additions and 1,722 deletions.
3 changes: 2 additions & 1 deletion public/locales/en/alert-message.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,5 +78,6 @@
"event-access-error": "You dont have access to apply for this event",
"error-event-already-started": "You cannot reserve a spot for this event because it has already started.",
"success-event-reservation": "You have successfully reserved a spot for this event.",
"error-creating-code-review": "Something went wrong creating the code review"
"error-creating-code-review": "Something went wrong creating the code review",
"error-ai-chat": "Something went wrong opening the AI Chat"
}
2 changes: 2 additions & 0 deletions public/locales/en/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@
"mark-as-not-done": "Mark as not done"
},
"learnpack": {
"title": "This is a Learnpack interactive exercise",
"description": "<strong>\"{{projectName}}\"</strong> uses LearnPack for an interactive and auto-graded experience; choose one of the following options to start working on the project:",
"description2": "This practice will reroute your browser to LearnPack - an interactive learning tool that runs integrated with VSCode.",
"new-exercise": "Start from the beginning",
Expand All @@ -147,6 +148,7 @@
"description": "We take care of <a class=\"link\" href=\"https://4geeks.com/click-and-learn\">setup and installations</a> for all the required technologies to run this exercise or project.",
"type": "dropdown"
},
"clone-title": "How to clone a project?",
"cloneInstructions": "This exercise can be downloaded and run locally if you have node.js installed (<a class=\"link\" href=\"https://4geeks.com/how-to/install-nvm-on-every-operating-system\" target=\"_blank\">installation steps</a>).\n\n Once you have node.js, it's time to install learnpack and clone this project into your computer by typing the following command on your terminal:\n\n``` bash\n$ npm i @learnpack/learnpack -g\n$ git clone {{urlToClone}}\n```\nNote: This will create a new folder <strong>\"{{repoName}}\"</strong> in your computer.\n\n<strong>If you want to use VSCode:</strong> Make sure you have the <a class=\"link\" target=\"_blank\" href=\"https://marketplace.visualstudio.com/items?itemName=learn-pack.learnpack-vscode\">LearnPack extension</a> installed, open the folder in VSCode and type `learnpack start` on your vscode terminal.\n\n<strong>To run without VSCode:</strong> Use your computer terminal to get inside your recently created folder and start learnpack:\n\n```bash\n$ cd {{repoName}}\n$ learnpack start\n```\nRead the <a class=\"link\" href=\"{{readmeUrl}}\">README.md</a> file and follow the rest of the instructions."
},
"upgrade-plan": {
Expand Down
1 change: 1 addition & 0 deletions public/locales/en/dashboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"title": "Dashboard"
},
"title": "Your News",
"back-to-dashboard": "Back to dashboard",
"backToChooseProgram": "Back to choose program",
"moduleMap": "Module map",
"progressText": "progress in the program",
Expand Down
28 changes: 26 additions & 2 deletions public/locales/en/syllabus.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,31 @@
"module-not-started": "You haven't started this module yet",
"no-modules-to-show": "No modules to show",
"edit-page": "Edit in GitHub",
"watch-intro": "Watch intro",
"get-help": "Get help from Rigobot",
"contribute": "Contribute to this lesson",
"show-menu": "Show menu",
"hide-menu": "Hide menu",
"open-google-collab": "Open in Colab",
"next-page": "Next page",
"teachers-feedback": "Teacher’s feedback",
"no-feedback": "You don't have any feedback yet",
"task-notification": "You will receive an email when your teacher reviews the task",
"code-reviews": "Code reviews",
"no-code-reviews": "You don't have any code review yet",
"rate-comment": "Rate this comment",
"start-review": "Start you review here...",
"like": "You sent a positive rating to this comment",
"dislike": "You sent a negative rating to this comment",
"you": "You",
"back": "Back",
"next-page": "Next",
"back-to-top": "Back to the top",
"start-next": "Start next module:",
"no-traduction-found": "No translation found",
"no-traduction-found-description": ">We are sorry, a translation for this content was not found. We are constantly working to offer our modules in various languages. We appreciate your patience and if you wish to contribute with translations, please visit our repository on GitHub. In the meantime, you can try accessing the content in another available language or check back later to see if the translation has been added.",
"no-content-found": "No content found",
"no-content-found-description": ">Unfortunately, the content you are looking for is not available at the specified path. We are constantly working on improvements and appreciate your understanding. If you need assistance or have additional questions, please do not hesitate to contact us. We are committed to providing you with the best service. Thank you for your patience and understanding.",
"previous-page": "Previous page",
"previous-page": "Previous",
"ask-to-done": "Would you like to mark this \"{{taskType}}\" as done before moving on?",
"mark-later": "Mark as done later",
"blank-page": "This content cannot be visualized inside of <a href='/'>4Geeks.com</a>, please <a href='{{url}}' target='_blank' rel='noopener noreferrer'>Click here</a> to open it on a new window",
Expand All @@ -31,5 +49,11 @@
"superseded-message": "This lesson belongs to the legacy archive, we recommend reading a more updated version:",
"solution-message": "This project includes a model solution that you can review if you need additional guidance.",
"open-solution": "Click here to review the model solution",
"completion-percentage": "Completion percentage",
"total-steps": "Total steps completed",
"total-time": "Total time worked on this package",
"successful-compiles": "Successfull compiles",
"successful-tests": "Successfull tests",
"total-errors": "Total errors",
"click-to-review": "Click here to review the solution."
}
3 changes: 2 additions & 1 deletion public/locales/es/alert-message.json
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,6 @@
"event-access-error": "No tienes acceso para aplicar en este evento",
"error-event-already-started": "No puedes reservar cupo para este evento porque ya ha comenzado",
"success-event-reservation": "¡Has reservado con éxito un cupo para este evento.!",
"error-creating-code-review": "Algo salió mal al crear la revisión de código"
"error-creating-code-review": "Algo salió mal al crear la revisión de código",
"error-ai-chat": "Algo salio mal abriendo el chat de IA"
}
2 changes: 2 additions & 0 deletions public/locales/es/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@
"mark-as-not-done": "Marcar como no hecho"
},
"learnpack": {
"title": "Este es un ejercicio interactivo de Learnpack",
"description": "<strong>\"{{projectName}}\"</strong> utiliza LearnPack para una experiencia interactiva y autoevaluada; elige una de las siguientes opciones para comenzar a trabajar en el proyecto:",
"new-exercise": "Comenzar desde el principio",
"continue-exercise": "Continuar desde una sesión anterior",
Expand All @@ -146,6 +147,7 @@
"description": "Nosotros nos encargamos de la <a class=\"link\" href=\"/es/aprende-en-un-clic\">configuración e instalación</a> de todas las tecnologías requeridas para realizar este ejercicio.",
"type": "dropdown"
},
"clone-title": "¿Cómo clonar un proyecto?",
"cloneInstructions": "Este ejercicio se puede descargar y ejecutar localmente si tienes node.js instalado (<a class=\"link\" href=\"/es/how-to/como-instalar-nvm-node-version-manager-en-cualquier-sistema-operativo\" target=\"_blank\">pasos de instalación</a>).\n\n Si ya tienes node, toca instalar learnpack y clonar el proyecto en tu computadora escribiendo el siguiente comando en tu terminal:\n\n```bash\n$ npm i @learnpack/learnpack -g\n$ git clone {{urlToClone}}\n```\nNota: Esto creará una nueva carpeta <strong>\"{{repoName}}\"</strong> en tu computadora con el código del proyecto dentro.\n\n<strong>Si quieres usar VSCode:</strong> asegúrate de tener el <a class=\"link\" target=\"_blank\" href=\"https://marketplace.visualstudio.com/items?itemName=learn-pack.learnpack-vscode\">LearnPack extension</a> instalado, abre la carpeta en VSCode y escribe `learnpack start` en tu terminal de vscode.\n\n<strong>Para realizar los ejercicios sin VSCode:</strong> abre tu terminal en la carpeta recién creada y comienza el programa learnpack:\n\n```bash\n$ cd {{repoName}}\n$ learnpack start\n```\nLee el archivo <a class=\"link\" href=\"{{readmeUrl}}\">README.md</a> y sigue el resto de las instrucciones."
},
"upgrade-plan": {
Expand Down
1 change: 1 addition & 0 deletions public/locales/es/dashboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
},
"title": "Tus noticias",
"moduleMap": "Mapa de módulos",
"back-to-dashboard": "Volver a dashboard",
"backToChooseProgram": "Volver a elegir programa",
"progressText": "Progreso en el programa",
"whiteLabeledText": "Este curso es traído a ti gracias a nuestra alianza con esta universidad.",
Expand Down
2 changes: 1 addition & 1 deletion public/locales/es/exercises.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"or": " o "
},
"clone-modal" : {
"title": "¿Como clonar un proyecto?",
"title": "¿Cómo clonar un proyecto?",
"text-part-one": "No lo recomendamos, pero algunos ejercicios se pueden descargar y ejecutar localmente usando VSCode y el ",
"text-part-two": ". Si quieres hacerlo, debes comenzar por clonar el proyecto en tu computadora escribiendo el siguiente comando en tu terminal:",
"note": "Nota: Esto creará una nueva carpeta “{{folder}}” en su computadora con el código del proyecto dentro.",
Expand Down
28 changes: 26 additions & 2 deletions public/locales/es/syllabus.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,31 @@
"module-not-started": "Aún no has iniciado este módulo",
"edit-page": "Editar en Github",
"no-modules-to-show": "No hay módulos para mostrar",
"watch-intro": "Ver introducción",
"get-help": "Pide ayuda a Rigobot",
"contribute": "Contribuye a esta lección",
"show-menu": "Abrir menú",
"hide-menu": "Cerrar menú",
"open-google-collab": "Abrir en Colab",
"next-page": "Siguiente página",
"teachers-feedback": "Comentario del profesor",
"no-feedback": "Aún no tienes ningún comentario",
"notification": "Recibirás un email cuando tu profesor revise la asignación",
"code-reviews": "Revisiones de código",
"no-code-reviews": "No tienes revisiones aún",
"rate-comment": "Califica este comentario",
"start-review": "Deja tu comentario aquí...",
"like": "Enviaste una calificación positiva a este comentario",
"dislike": "Enviaste una calificación negativa a este comentario",
"you": "Tu",
"back": "Volver",
"next-page": "Siguiente",
"back-to-top": "Volver arriba",
"start-next": "Comenzar siguiente module:",
"no-traduction-found": "No se encontró traducción",
"no-traduction-found-description": ">Lo sentimos, no se encontró una traducción para este contenido. Estamos trabajando constantemente para ofrecer nuestros módulos en varios idiomas. Apreciamos tu paciencia y si deseas contribuir con traducciones, por favor visita nuestro repositorio en Github. Mientras tanto, puedes intentar acceder al contenido en otro idioma disponible o volver más tarde para verificar si la traducción ha sido agregada.",
"no-content-found": "No se encontró contenido",
"no-content-found-description": ">Lamentablemente, el contenido que buscas no está disponible en la ruta especificada. Estamos trabajando en mejoras continuas y valoramos tu comprensión. Si necesitas asistencia o tienes preguntas adicionales, no dudes en comunicarte con nosotros. Estamos comprometidos a brindarte el mejor servicio. Gracias por tu paciencia y comprensión.",
"previous-page": "Anterior página",
"previous-page": "Anterior",
"ask-to-done": "¿Te gustaría marcar este \"{{taskType}}\" como completado antes de continuar?",
"mark-later": "Marcar luego",
"blank-page": "Este contenido no se puede visualizar dentro de <a href='/'>4Geeks.com</a>, please <a href='{{url}}' target='_blank' rel='noopener noreferrer'>Haga clic aquí</a> para abrirlo en una nueva ventana",
Expand All @@ -31,5 +49,11 @@
"superseded-message": "Esta lección pertenece al archivo de legado, recomendamos leer una versión más actualizada:",
"solution-message": "Este proyecto tiene una solución modelo que puedes revisar en caso de necesitar orientación adicional.",
"open-solution": "Haz clic aquí para revisar el modelo de solución",
"completion-percentage": "Porcentaje de finalización",
"total-steps": "Pasos completados",
"total-time": "Tiempo total",
"successful-compiles": "Compilaciones exitosas",
"successful-tests": "Pasos exitosos",
"total-errors": "Total de errores",
"click-to-review": "Pincha aquí para revisar la solución."
}
5 changes: 2 additions & 3 deletions src/common/components/AttendanceModal/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ import useCohortHandler from '../../hooks/useCohortHandler';
import handlers from '../../handlers';

function AttendanceModal({
title, message, isOpen, onClose, sortedAssignments, students,
title, message, isOpen, onClose, students,
}) {
const { t } = useTranslation('dashboard');
const { state, setCohortSession } = useCohortHandler();
const { cohortSession } = state;
const { cohortSession, sortedAssignments } = state;
const [historyLog, setHistoryLog] = useState();
const [day, setDay] = useState(cohortSession.current_day);
const [attendanceTaken, setAttendanceTaken] = useState({});
Expand Down Expand Up @@ -440,7 +440,6 @@ CheckboxCard.propTypes = {
AttendanceModal.propTypes = {
title: PropTypes.string,
message: PropTypes.string,
sortedAssignments: PropTypes.arrayOf(PropTypes.objectOf(PropTypes.any)).isRequired,
students: PropTypes.arrayOf(PropTypes.objectOf(PropTypes.any)).isRequired,
isOpen: PropTypes.bool,
onClose: PropTypes.func,
Expand Down
7 changes: 4 additions & 3 deletions src/common/components/CodeViewer.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -125,14 +125,14 @@ function CodeViewer({ languagesData, allowNotLogged, fileContext, ...rest }) {

let endpoint;
if (path) {
endpoint = 'https://rigobot.herokuapp.com/v1/prompting/completion/code-compiler-with-context/';
endpoint = `${RIGOBOT_HOST}/v1/prompting/completion/code-compiler-with-context/`;
completionJob.inputs = {
main_file: `File path: ${path}\nFile content:\n${code}`,
language_and_version: language,
secondary_files: fileContext,
};
} else {
endpoint = 'https://rigobot.herokuapp.com/v1/prompting/completion/code-compiler/';
endpoint = `${RIGOBOT_HOST}/v1/prompting/completion/code-compiler/`;
completionJob.inputs = {
code,
language_and_version: language,
Expand Down Expand Up @@ -241,8 +241,9 @@ function CodeViewer({ languagesData, allowNotLogged, fileContext, ...rest }) {
]);
}}
defaultLanguage={language}
height="300px"
height="290px"
options={{
scrollBeyondLastLine: false,
borderRadius: '4px',
scrollbar: {
alwaysConsumeMouseWheel: false,
Expand Down
10 changes: 5 additions & 5 deletions src/common/components/CohortSideBar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import AvatarUser from '../../js_modules/cohortSidebar/avatarUser';
import { AvatarSkeleton } from './Skeleton';
import useOnline from '../hooks/useOnline';
import useStyle from '../hooks/useStyle';
import useCohortHandler from '../hooks/useCohortHandler';
import useProgramList from '../store/actions/programListAction';
import { isWindow } from '../../utils';

Expand Down Expand Up @@ -215,7 +216,7 @@ function ProfilesSection({
}

function CohortSideBar({
title, teacherVersionActive, cohort, cohortCity, width, containerStyle,
title, teacherVersionActive, width, containerStyle,
studentAndTeachers, isDisabled,
}) {
const { t } = useTranslation('dashboard');
Expand All @@ -226,6 +227,9 @@ function CohortSideBar({
const [activeStudentsLoading, setActiveStudentsLoading] = useState(true);
const [graduatedStudentsLoading, setGraduatedStudentsLoading] = useState(true);
const { addTeacherProgramList } = useProgramList();
const { state } = useCohortHandler();
const { cohortSession: cohort } = state;
const cohortCity = cohort?.name;
const teacher = studentAndTeachers.filter((st) => st?.role === 'TEACHER');
const activeStudents = studentAndTeachers.filter(
(st) => st?.role === 'STUDENT' && ['ACTIVE', 'GRADUATED'].includes(st?.educational_status),
Expand Down Expand Up @@ -517,8 +521,6 @@ CohortSideBar.propTypes = {
teacherVersionActive: PropTypes.bool,
containerStyle: PropTypes.objectOf(PropTypes.oneOfType([PropTypes.any])),
studentAndTeachers: PropTypes.arrayOf(PropTypes.objectOf(PropTypes.oneOfType([PropTypes.any]))),
cohortCity: PropTypes.string,
cohort: PropTypes.objectOf(PropTypes.oneOfType([PropTypes.any])),
isDisabled: PropTypes.bool,
// handleStudySession: PropTypes.func,
};
Expand All @@ -528,8 +530,6 @@ CohortSideBar.defaultProps = {
teacherVersionActive: false,
containerStyle: {},
studentAndTeachers: [],
cohortCity: 'Miami Downtown',
cohort: {},
isDisabled: false,
// handleStudySession: () => {},
};
Expand Down
2 changes: 1 addition & 1 deletion src/common/components/DynamicContentCard/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ function DynamicContentCard({ data, type, technologies, usersWorkedHere, ...rest
padding={isWorkshop ? '10px 16px 0px' : '16px'}
gridGap="14px"
width={isWorkshop ? { base: '310px', md: '360px' } : 'auto'}
minWidth={{ base: '280px', md: '310px' }}
minWidth="280px"
background={isWorkshopStarted ? featuredColor : backgroundColor}
color={fontColor}
borderRadius="10px"
Expand Down
23 changes: 23 additions & 0 deletions src/common/components/Icon/set/graph-up.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
const graphUp = ({
width, height, style, color,
}) => (
<svg
width={width || '28'}
height={height || '26'}
style={style}
viewBox="0 0 28 26"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M14.8696 11.3305C17.5644 8.63696 20.1976 6.00371 22.8514 3.35115C21.9262 3.35115 20.9709 3.35356 20.0167 3.35115C18.9926 3.34874 18.3304 2.75888 18.3472 1.87108C18.3641 1.01343 19.0179 0.456141 20.0191 0.454934C22.1289 0.452522 24.2386 0.452522 26.3483 0.454934C27.4267 0.456141 27.9961 1.01343 27.9973 2.07373C28.0009 4.20397 28.0009 6.33301 27.9973 8.46326C27.9961 9.44997 27.4135 10.105 26.551 10.105C25.6861 10.105 25.1059 9.45239 25.1023 8.46688C25.0987 7.5079 25.1023 6.54773 25.1023 5.45727C24.8634 5.67319 24.7054 5.80588 24.5595 5.95184C21.802 8.70692 19.0469 11.4644 16.2894 14.2195C15.3183 15.1905 14.6332 15.1942 13.6742 14.2364C12.6803 13.2436 11.6899 12.2473 10.6525 11.2063C10.4704 11.3764 10.31 11.5163 10.1592 11.6671C7.67189 14.152 5.19063 16.6441 2.69127 19.1181C2.43072 19.3762 2.09176 19.6199 1.74677 19.7152C1.15329 19.8805 0.634605 19.6344 0.27876 19.129C-0.0770853 18.6211 -0.0951788 18.0771 0.241366 17.5488C0.369229 17.3485 0.544136 17.1748 0.714218 17.006C3.58269 14.1339 6.45237 11.2642 9.32325 8.3945C10.2883 7.4295 10.9734 7.4307 11.9384 8.3945C12.9324 9.38604 13.9227 10.3812 14.8708 11.3317L14.8696 11.3305Z"
fill={color || '#EFF9FF'}
/>
<path
d="M13.9571 25.546C9.81965 25.546 5.68099 25.5484 1.54354 25.5436C0.732935 25.5436 0.115334 25.0213 0.0200398 24.2891C-0.0716356 23.593 0.360203 22.9151 1.04656 22.7137C1.23474 22.6582 1.44221 22.651 1.64004 22.651C9.87514 22.6485 18.1114 22.6473 26.3465 22.6498C27.3393 22.6498 27.9907 23.2215 27.9979 24.0852C28.0051 24.9718 27.3453 25.5448 26.3104 25.546C22.1922 25.5472 18.0753 25.546 13.9571 25.546Z"
fill={color || '#EFF9FF'}
/>
</svg>
);

export default graphUp;
50 changes: 50 additions & 0 deletions src/common/components/Icon/set/layout.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
const layout = ({
width, height, color, style,
}) => (
<svg
width={width || '14'}
height={height || '14'}
style={style}
viewBox="0 0 14 14"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<rect
x="0.5"
y="0.5"
width="5.26087"
height="7.72839"
rx="0.5"
stroke={color || '#0097CF'}
/>
<rect
x="13.5"
y="13.5"
width="5.26087"
height="7.7284"
rx="0.5"
transform="rotate(180 13.5 13.5)"
stroke={color || '#0097CF'}
/>
<rect
x="0.5"
y="10.8672"
width="5.26087"
height="2.62963"
rx="0.5"
stroke={color || '#0097CF'}
/>
<rect
x="13.5"
y="3.13281"
width="5.26087"
height="2.62963"
rx="0.5"
transform="rotate(180 13.5 3.13281)"
stroke={color || '#0097CF'}
/>
</svg>

);

export default layout;
Loading

0 comments on commit 0b9a381

Please sign in to comment.