mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-03-20 13:02:19 -04:00
feat(Curriculum): Add new BlockType tags for the Language Curricula Chapter Based Certifications (#62156)
Co-authored-by: Huyen Nguyen <25715018+huyenltnguyen@users.noreply.github.com>
This commit is contained in:
@@ -1,4 +1,7 @@
|
||||
const Joi = require('joi');
|
||||
const {
|
||||
chapterBasedSuperBlocks
|
||||
} = require('../../../shared/config/curriculum');
|
||||
|
||||
const blockSchema = Joi.object({}).keys({
|
||||
desc: Joi.array().min(1),
|
||||
@@ -40,9 +43,12 @@ const blockSchema = Joi.object({}).keys({
|
||||
'lab',
|
||||
'review',
|
||||
'quiz',
|
||||
'exam'
|
||||
'exam',
|
||||
'warm-up',
|
||||
'learn',
|
||||
'practice'
|
||||
).when('superBlock', {
|
||||
is: 'full-stack-developer',
|
||||
is: chapterBasedSuperBlocks,
|
||||
then: Joi.required(),
|
||||
otherwise: Joi.optional()
|
||||
}),
|
||||
|
||||
@@ -45,7 +45,10 @@ const blockSchema = Joi.object().keys({
|
||||
'lab',
|
||||
'review',
|
||||
'quiz',
|
||||
'exam'
|
||||
'exam',
|
||||
'warm-up',
|
||||
'learn',
|
||||
'practice'
|
||||
).when('superBlock', {
|
||||
is: chapterBasedSuperBlocks,
|
||||
then: Joi.required(),
|
||||
|
||||
Reference in New Issue
Block a user