@magmamath/students-features 1.3.8 → 1.3.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/settings.local.json +25 -0
- package/.editorconfig +15 -0
- package/.eslintignore +2 -0
- package/.eslintrc +22 -0
- package/.gitattributes +3 -0
- package/.github/actions/setup/action.yml +37 -0
- package/.github/workflows/ci.yml +73 -0
- package/.gitignore +84 -0
- package/.idea/.gitignore +8 -0
- package/.idea/codeStyles/Project.xml +62 -0
- package/.idea/codeStyles/codeStyleConfig.xml +5 -0
- package/.idea/copilot.data.migration.agent.xml +6 -0
- package/.idea/copilot.data.migration.ask.xml +6 -0
- package/.idea/copilot.data.migration.ask2agent.xml +6 -0
- package/.idea/copilot.data.migration.edit.xml +6 -0
- package/.idea/inspectionProfiles/Project_Default.xml +8 -0
- package/.idea/jsLinters/eslint.xml +6 -0
- package/.idea/modules.xml +8 -0
- package/.idea/prettier.xml +7 -0
- package/.idea/students-features.iml +12 -0
- package/.idea/vcs.xml +6 -0
- package/.idea/workspace.xml +675 -0
- package/.nvmrc +1 -0
- package/.prettierrc +11 -0
- package/.release-it.json +17 -0
- package/.watchmanconfig +1 -0
- package/.yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs +541 -0
- package/.yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs +28 -0
- package/.yarn/releases/yarn-3.6.1.cjs +874 -0
- package/babel.config.js +5 -0
- package/bob.config.js +25 -0
- package/dist/commonjs/features/chatbot/helpers.js +5 -1
- package/dist/commonjs/features/chatbot/helpers.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatBotModel.js +1 -0
- package/dist/commonjs/features/chatbot/model/ChatBotModel.js.map +1 -1
- package/dist/commonjs/features/chatbot/types/model.types.js.map +1 -1
- package/dist/module/features/chatbot/helpers.js +5 -1
- package/dist/module/features/chatbot/helpers.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatBotModel.js +1 -0
- package/dist/module/features/chatbot/model/ChatBotModel.js.map +1 -1
- package/dist/module/features/chatbot/types/model.types.js.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/helpers.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/ChatBotModel.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/types/api.types.d.ts +2 -0
- package/dist/typescript/commonjs/features/chatbot/types/api.types.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/types/model.types.d.ts +1 -0
- package/dist/typescript/commonjs/features/chatbot/types/model.types.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/helpers.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/ChatBotModel.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/types/api.types.d.ts +2 -0
- package/dist/typescript/module/features/chatbot/types/api.types.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/types/model.types.d.ts +1 -0
- package/dist/typescript/module/features/chatbot/types/model.types.d.ts.map +1 -1
- package/example/.expo/README.md +8 -0
- package/example/.expo/devices.json +3 -0
- package/example/.expo/web/cache/production/images/favicon/favicon-24272cdaeff82cc5facdaccd982a6f05b60c4504704bbf94c19a6388659880bb-contain-transparent/favicon-48.png +0 -0
- package/example/app.json +30 -0
- package/example/assets/adaptive-icon.png +0 -0
- package/example/assets/favicon.png +0 -0
- package/example/assets/icon.png +0 -0
- package/example/assets/splash-icon.png +0 -0
- package/example/babel.config.js +28 -0
- package/example/index.js +8 -0
- package/example/metro.config.js +18 -0
- package/example/package.json +25 -0
- package/example/src/App.tsx +8 -0
- package/example/tsconfig.json +6 -0
- package/package.json +1 -1
- package/src/features/chatbot/helpers.ts +2 -0
- package/src/features/chatbot/model/ChatBotModel.ts +1 -0
- package/src/features/chatbot/types/api.types.ts +2 -0
- package/src/features/chatbot/types/model.types.ts +1 -0
- package/tsconfig.build.json +4 -0
- package/tsconfig.json +34 -0
- package/yarn.lock +10984 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
const path = require('path');
|
|
2
|
+
const { getDefaultConfig } = require('@expo/metro-config');
|
|
3
|
+
const { getConfig } = require('react-native-builder-bob/metro-config');
|
|
4
|
+
const pkg = require('../package.json');
|
|
5
|
+
|
|
6
|
+
const root = path.resolve(__dirname, '..');
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Metro configuration
|
|
10
|
+
* https://facebook.github.io/metro/docs/configuration
|
|
11
|
+
*
|
|
12
|
+
* @type {import('metro-config').MetroConfig}
|
|
13
|
+
*/
|
|
14
|
+
module.exports = getConfig(getDefaultConfig(__dirname), {
|
|
15
|
+
root,
|
|
16
|
+
pkg,
|
|
17
|
+
project: __dirname,
|
|
18
|
+
});
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@magmamath/students-features-example",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"main": "index.js",
|
|
5
|
+
"scripts": {
|
|
6
|
+
"start": "expo start",
|
|
7
|
+
"android": "expo start --android",
|
|
8
|
+
"ios": "expo start --ios",
|
|
9
|
+
"web": "expo start --web"
|
|
10
|
+
},
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"@expo/metro-runtime": "~4.0.0",
|
|
13
|
+
"expo": "~52.0.11",
|
|
14
|
+
"expo-status-bar": "~2.0.0",
|
|
15
|
+
"react": "18.3.1",
|
|
16
|
+
"react-dom": "18.3.1",
|
|
17
|
+
"react-native": "0.76.3",
|
|
18
|
+
"react-native-web": "~0.19.13"
|
|
19
|
+
},
|
|
20
|
+
"devDependencies": {
|
|
21
|
+
"@babel/core": "^7.20.0",
|
|
22
|
+
"react-native-builder-bob": "^0.33.3"
|
|
23
|
+
},
|
|
24
|
+
"private": true
|
|
25
|
+
}
|
package/package.json
CHANGED
|
@@ -66,6 +66,7 @@ export function prepareChatRequestPayload(
|
|
|
66
66
|
answerOptions,
|
|
67
67
|
answer,
|
|
68
68
|
chatHistory,
|
|
69
|
+
assignmentGrade,
|
|
69
70
|
} = payload
|
|
70
71
|
|
|
71
72
|
if (freeTextMessage) {
|
|
@@ -106,6 +107,7 @@ export function prepareChatRequestPayload(
|
|
|
106
107
|
...(imageAltText && { altText: imageAltText }),
|
|
107
108
|
...(!!problemStandards?.length && { problemStandards }),
|
|
108
109
|
...(!!answerOptions?.length && { answerOptions }),
|
|
110
|
+
...(assignmentGrade !== undefined && { assignmentGrade }),
|
|
109
111
|
},
|
|
110
112
|
}
|
|
111
113
|
}
|
|
@@ -245,6 +245,7 @@ export class ChatbotModel {
|
|
|
245
245
|
imageAltText: context.imageDescription,
|
|
246
246
|
imageCdnId: context.imageCdnId,
|
|
247
247
|
conversationId: cache[key].conversationId,
|
|
248
|
+
assignmentGrade: context.assignmentGrade,
|
|
248
249
|
...(isFreeText && { freeTextMessage: message }),
|
|
249
250
|
...(context.assignmentId && {
|
|
250
251
|
chatHistory: {
|
|
@@ -64,6 +64,7 @@ export type PostMessagePayload = {
|
|
|
64
64
|
freeTextMessage?: string
|
|
65
65
|
conversationId?: string | null
|
|
66
66
|
chatHistory?: ChatHistory
|
|
67
|
+
assignmentGrade?: number
|
|
67
68
|
}
|
|
68
69
|
|
|
69
70
|
export type PostMessageResponse = {
|
|
@@ -128,6 +129,7 @@ export type ChatHintPayload = {
|
|
|
128
129
|
hintNumber: number
|
|
129
130
|
studentInput: string
|
|
130
131
|
answerOptions?: string[]
|
|
132
|
+
assignmentGrade?: number
|
|
131
133
|
}
|
|
132
134
|
|
|
133
135
|
export type ChatHintResponse = {
|
package/tsconfig.json
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"paths": {
|
|
4
|
+
"@magmamath/students-features": ["./src/index"]
|
|
5
|
+
},
|
|
6
|
+
"target": "esnext",
|
|
7
|
+
"baseUrl": "./",
|
|
8
|
+
"lib": [
|
|
9
|
+
"dom",
|
|
10
|
+
"dom.iterable",
|
|
11
|
+
"esnext"
|
|
12
|
+
],
|
|
13
|
+
"declaration": true,
|
|
14
|
+
"allowJs": true,
|
|
15
|
+
"skipLibCheck": true,
|
|
16
|
+
"esModuleInterop": true,
|
|
17
|
+
"allowSyntheticDefaultImports": true,
|
|
18
|
+
"strict": true,
|
|
19
|
+
"forceConsistentCasingInFileNames": true,
|
|
20
|
+
"module": "esnext",
|
|
21
|
+
"moduleResolution": "node",
|
|
22
|
+
"resolveJsonModule": true,
|
|
23
|
+
"isolatedModules": true,
|
|
24
|
+
"jsx": "react",
|
|
25
|
+
"experimentalDecorators": true
|
|
26
|
+
},
|
|
27
|
+
"include": [
|
|
28
|
+
"src"
|
|
29
|
+
],
|
|
30
|
+
"exclude": [
|
|
31
|
+
"node_modules",
|
|
32
|
+
"example"
|
|
33
|
+
]
|
|
34
|
+
}
|