Skip to content

Commit

Permalink
Merge bed4854 into 6cb6918
Browse files Browse the repository at this point in the history
  • Loading branch information
sjschlapbach authored Jan 8, 2025
2 parents 6cb6918 + bed4854 commit 2a1e058
Show file tree
Hide file tree
Showing 50 changed files with 1,223 additions and 288 deletions.
2 changes: 1 addition & 1 deletion apps/auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"@klicker-uzh/prisma": "workspace:*",
"@klicker-uzh/shared-components": "workspace:*",
"@next-auth/prisma-adapter": "1.0.7",
"@uzh-bf/design-system": "3.0.0-alpha.37",
"@uzh-bf/design-system": "3.0.0-alpha.38",
"axios": "1.7.7",
"bcryptjs": "2.4.3",
"js-cookie": "3.0.5",
Expand Down
2 changes: 1 addition & 1 deletion apps/backend-docker/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
"@types/passport": "^1.0.16",
"@types/passport-jwt": "^4.0.1",
"@types/ws": "^8.5.12",
"@uzh-bf/design-system": "3.0.0-alpha.37",
"@uzh-bf/design-system": "3.0.0-alpha.38",
"axios": "~1.7.7",
"cross-env": "~7.0.3",
"dotenv": "~16.4.5",
Expand Down
3 changes: 3 additions & 0 deletions apps/backend-docker/src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ function prepareApp({ prisma, redisExec, pubSub, cache, emitter }: any) {
maxDepth: {
enabled: false,
},
costLimit: {
enabled: false,
},
})
const enhancements = armor.protect()

Expand Down
2 changes: 1 addition & 1 deletion apps/docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"@mdx-js/react": "~3.1.0",
"@tailwindcss/typography": "~0.5.15",
"@types/react": "^18.3.11",
"@uzh-bf/design-system": "3.0.0-alpha.37",
"@uzh-bf/design-system": "3.0.0-alpha.38",
"autoprefixer": "~10.4.20",
"cross-env": "~7.0.3",
"docusaurus-plugin-matomo": "~0.0.8",
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend-control/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"@klicker-uzh/prisma": "workspace:*",
"@klicker-uzh/shared-components": "workspace:*",
"@socialgouv/matomo-next": "1.9.1",
"@uzh-bf/design-system": "3.0.0-alpha.37",
"@uzh-bf/design-system": "3.0.0-alpha.38",
"cross-env": "7.0.3",
"dayjs": "1.11.13",
"deepmerge": "4.3.1",
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend-manage/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"@socialgouv/matomo-next": "1.9.1",
"@tanstack/react-table": "8.20.5",
"@uidotdev/usehooks": "2.4.1",
"@uzh-bf/design-system": "3.0.0-alpha.37",
"@uzh-bf/design-system": "3.0.0-alpha.38",
"dayjs": "1.11.13",
"deepmerge": "4.3.1",
"formik": "2.4.6",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ const acceptedTypes = [
ElementType.Numerical,
ElementType.FreeText,
ElementType.Content,
ElementType.Selection,
]

interface GroupActivityWizardProps {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ const acceptedTypes = [
ElementType.FreeText,
// ElementType.Flashcard,
// ElementType.Content,
ElementType.Selection,
]

function LiveQuizQuestionsStep({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ const acceptedTypes = [
ElementType.FreeText,
ElementType.Flashcard,
ElementType.Content,
ElementType.Selection,
]

interface MicroLearningWizardProps {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ const acceptedTypes = [
ElementType.FreeText,
ElementType.Flashcard,
ElementType.Content,
ElementType.Selection,
]

interface PracticeQuizWizardProps {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ function ElementTypeMonitor({
setElementDataTypename('FreeTextElementData')
} else if (elementType === ElementType.Flashcard) {
setElementDataTypename('FlashcardElementData')
} else if (elementType === ElementType.Selection) {
setElementDataTypename('SelectionElementData')
} else {
setElementDataTypename('ContentElementData')
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,9 @@ function useElementFormInitialValues({
options: {
hasSampleSolution: options.hasSampleSolution ?? false,
numberOfInputs: String(options.numberOfInputs),
answerCollection: String(options.answerCollectionId),
answerCollection: options.answerCollection
? String(options.answerCollection?.id)
: '',
correctAnswers: options.answerCollectionSolutionIds ?? undefined,
},
}
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend-manage/src/pages/quizzes/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ function LiveQuizList() {
.sort((a, b) => (dayjs(b.finishedAt) > dayjs(a.finishedAt) ? 1 : -1))
}, [data])

if (!data || loading) {
if (loading) {
return (
<Layout displayName={t('shared.generic.liveQuizzes')}>
<Loader />
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend-pwa/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"@radix-ui/react-collapsible": "1.1.1",
"@socialgouv/matomo-next": "1.9.1",
"@uidotdev/usehooks": "2.4.1",
"@uzh-bf/design-system": "3.0.0-alpha.37",
"@uzh-bf/design-system": "3.0.0-alpha.38",
"body-parser": "1.20.3",
"dayjs": "1.11.13",
"deepmerge": "4.3.1",
Expand Down
2 changes: 1 addition & 1 deletion apps/func-incoming-responses/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"devDependencies": {
"@types/jsonwebtoken": "^9.0.7",
"@types/node": "^20.16.1",
"@uzh-bf/design-system": "3.0.0-alpha.37",
"@uzh-bf/design-system": "3.0.0-alpha.38",
"azure-functions-core-tools": "~4.0.6610",
"cross-env": "~7.0.3",
"dotenv": "~16.4.5",
Expand Down
2 changes: 1 addition & 1 deletion apps/func-response-processor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"devDependencies": {
"@types/jsonwebtoken": "^9.0.7",
"@types/node": "^20.16.1",
"@uzh-bf/design-system": "3.0.0-alpha.37",
"@uzh-bf/design-system": "3.0.0-alpha.38",
"azure-functions-core-tools": "~4.0.6610",
"cross-env": "~7.0.3",
"dotenv": "~16.4.5",
Expand Down
2 changes: 1 addition & 1 deletion apps/office-addin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"version": "3.3.0-alpha.18",
"license": "AGPL-3.0",
"dependencies": {
"@uzh-bf/design-system": "3.0.0-alpha.37",
"@uzh-bf/design-system": "3.0.0-alpha.38",
"core-js": "3.30.2",
"es6-promise": "4.2.8",
"formik": "2.4.6",
Expand Down
23 changes: 23 additions & 0 deletions packages/graphql/src/graphql/ops/FElementData.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,29 @@ fragment ElementData on ElementInstance {
}
}

... on SelectionElementData {
__typename
id
elementId
name
type
content
explanation
pointsMultiplier
options {
hasSampleSolution
numberOfInputs
answerCollection {
id
entries {
id
value
}
}
answerCollectionSolutionIds
}
}

... on FlashcardElementData {
__typename
id
Expand Down
11 changes: 11 additions & 0 deletions packages/graphql/src/graphql/ops/FElementDataInfo.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,17 @@ fragment ElementDataInfo on ElementInstance {
pointsMultiplier
}

... on SelectionElementData {
__typename
id
elementId
name
type
content
explanation
pointsMultiplier
}

... on FlashcardElementData {
__typename
id
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,27 @@ fragment ElementDataWithoutSolutions on ElementInstance {
}
}

... on SelectionElementData {
__typename
id
elementId
name
type
content
explanation
pointsMultiplier
options {
numberOfInputs
answerCollection {
id
entries {
id
value
}
}
}
}

... on FlashcardElementData {
id
elementId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ mutation ManipulateSelectionQuestion(
options {
hasSampleSolution
numberOfInputs
answerCollectionId
answerCollection {
id
}
answerCollectionSolutionIds
}
tags {
Expand Down
4 changes: 3 additions & 1 deletion packages/graphql/src/graphql/ops/QGetSingleQuestion.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,9 @@ query GetSingleQuestion($id: Int!) {
options {
hasSampleSolution
numberOfInputs
answerCollectionId
answerCollection {
id
}
answerCollectionSolutionIds
}

Expand Down
Loading

0 comments on commit 2a1e058

Please sign in to comment.