@magmamath/students-features 1.8.0 → 1.8.1-rc.0
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/dist/commonjs/features/fluency/components/FluencySolving.js +2 -2
- package/dist/commonjs/features/fluency/components/FluencySolving.js.map +1 -1
- package/dist/commonjs/features/fluency/components/fluency-solving/components/DebugBoxIndicator.js +48 -0
- package/dist/commonjs/features/fluency/components/fluency-solving/components/DebugBoxIndicator.js.map +1 -0
- package/dist/commonjs/features/fluency/components/fluency-solving/components/EquationContent.js +9 -8
- package/dist/commonjs/features/fluency/components/fluency-solving/components/EquationContent.js.map +1 -1
- package/dist/commonjs/features/fluency/components/fluency-solving/components/FluencyCardDeck.js +3 -1
- package/dist/commonjs/features/fluency/components/fluency-solving/components/FluencyCardDeck.js.map +1 -1
- package/dist/commonjs/features/fluency/components/fluency-solving/components/FluencyEquationCard.js +63 -10
- package/dist/commonjs/features/fluency/components/fluency-solving/components/FluencyEquationCard.js.map +1 -1
- package/dist/commonjs/features/fluency/components/fluency-solving/components/FluencySolvingHeader.js +10 -0
- package/dist/commonjs/features/fluency/components/fluency-solving/components/FluencySolvingHeader.js.map +1 -1
- package/dist/commonjs/features/fluency/components/fluency-solving/components/FluencySolvingProgress.js +0 -2
- package/dist/commonjs/features/fluency/components/fluency-solving/components/FluencySolvingProgress.js.map +1 -1
- package/dist/commonjs/features/fluency/index.js +12 -0
- package/dist/commonjs/features/fluency/index.js.map +1 -1
- package/dist/commonjs/features/fluency/visual-scaffolding/adapter.js +36 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/adapter.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/DiscreteCounterGrid.js +232 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/DiscreteCounterGrid.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/Dot.js +51 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/Dot.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/DynamicNumberLine.js +104 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/DynamicNumberLine.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/FactVisual.js +75 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/FactVisual.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/QuotativeBars.js +91 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/QuotativeBars.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/RelationalBlock.js +279 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/RelationalBlock.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/visualColors.js +44 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/components/visualColors.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/index.js +73 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/index.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/renderFact.js +276 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/renderFact.js.map +1 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/types.js +2 -0
- package/dist/commonjs/features/fluency/visual-scaffolding/types.js.map +1 -0
- package/dist/commonjs/features/fluency-teacher/assets/{DivisionIcon.js → SortDefaultIcon.js} +8 -11
- package/dist/commonjs/features/fluency-teacher/assets/SortDefaultIcon.js.map +1 -0
- package/dist/commonjs/features/fluency-teacher/components/FluencyTeacher.js +3 -4
- package/dist/commonjs/features/fluency-teacher/components/FluencyTeacher.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerHeader.js +43 -48
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerHeader.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerMasteryLegend.js +80 -0
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerMasteryLegend.js.map +1 -0
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerMatrixes.js +28 -11
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerMatrixes.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerOperatorBox.js +44 -27
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerOperatorBox.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerOperatorStatCard.js +40 -47
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerOperatorStatCard.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerStats.js +24 -14
- package/dist/commonjs/features/fluency-teacher/components/drawer/DrawerStats.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/drawer/FluencyTeacherDrawer.js +6 -6
- package/dist/commonjs/features/fluency-teacher/components/drawer/FluencyTeacherDrawer.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/matrix/DrawerMatrix.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/matrix/MatrixCell.js +16 -2
- package/dist/commonjs/features/fluency-teacher/components/matrix/MatrixCell.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/matrix/MatrixRow.js +2 -1
- package/dist/commonjs/features/fluency-teacher/components/matrix/MatrixRow.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/table/AllPupilsTableRow.js +41 -15
- package/dist/commonjs/features/fluency-teacher/components/table/AllPupilsTableRow.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/table/AverageSortButton.js +62 -6
- package/dist/commonjs/features/fluency-teacher/components/table/AverageSortButton.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/table/FluencyTeacherStudentsTable.js +40 -42
- package/dist/commonjs/features/fluency-teacher/components/table/FluencyTeacherStudentsTable.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/table/OperatorBadge.js +16 -25
- package/dist/commonjs/features/fluency-teacher/components/table/OperatorBadge.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/table/TableColumnSortButton.js +40 -30
- package/dist/commonjs/features/fluency-teacher/components/table/TableColumnSortButton.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/table/TableRow.js +72 -59
- package/dist/commonjs/features/fluency-teacher/components/table/TableRow.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/components/table/TableRowAverageProgress.js +71 -0
- package/dist/commonjs/features/fluency-teacher/components/table/TableRowAverageProgress.js.map +1 -0
- package/dist/commonjs/features/fluency-teacher/context/TeacherFluencyContext.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/fluencyTeacher.constants.js +38 -103
- package/dist/commonjs/features/fluency-teacher/fluencyTeacher.constants.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/fluencyTeacher.helpers.js +10 -52
- package/dist/commonjs/features/fluency-teacher/fluencyTeacher.helpers.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/hooks/useDrawerGrid.js +2 -3
- package/dist/commonjs/features/fluency-teacher/hooks/useDrawerGrid.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/hooks/useDrawerMatrix.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/model/TeacherFluencyFiltersModel.js +1 -2
- package/dist/commonjs/features/fluency-teacher/model/TeacherFluencyFiltersModel.js.map +1 -1
- package/dist/commonjs/features/fluency-teacher/model/TeacherFluencyModel.js +0 -9
- package/dist/commonjs/features/fluency-teacher/model/TeacherFluencyModel.js.map +1 -1
- package/dist/module/features/fluency/components/FluencySolving.js +2 -2
- package/dist/module/features/fluency/components/FluencySolving.js.map +1 -1
- package/dist/module/features/fluency/components/fluency-solving/components/DebugBoxIndicator.js +43 -0
- package/dist/module/features/fluency/components/fluency-solving/components/DebugBoxIndicator.js.map +1 -0
- package/dist/module/features/fluency/components/fluency-solving/components/EquationContent.js +9 -8
- package/dist/module/features/fluency/components/fluency-solving/components/EquationContent.js.map +1 -1
- package/dist/module/features/fluency/components/fluency-solving/components/FluencyCardDeck.js +3 -1
- package/dist/module/features/fluency/components/fluency-solving/components/FluencyCardDeck.js.map +1 -1
- package/dist/module/features/fluency/components/fluency-solving/components/FluencyEquationCard.js +64 -11
- package/dist/module/features/fluency/components/fluency-solving/components/FluencyEquationCard.js.map +1 -1
- package/dist/module/features/fluency/components/fluency-solving/components/FluencySolvingHeader.js +10 -0
- package/dist/module/features/fluency/components/fluency-solving/components/FluencySolvingHeader.js.map +1 -1
- package/dist/module/features/fluency/components/fluency-solving/components/FluencySolvingProgress.js +0 -2
- package/dist/module/features/fluency/components/fluency-solving/components/FluencySolvingProgress.js.map +1 -1
- package/dist/module/features/fluency/index.js +1 -0
- package/dist/module/features/fluency/index.js.map +1 -1
- package/dist/module/features/fluency/visual-scaffolding/adapter.js +31 -0
- package/dist/module/features/fluency/visual-scaffolding/adapter.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/components/DiscreteCounterGrid.js +225 -0
- package/dist/module/features/fluency/visual-scaffolding/components/DiscreteCounterGrid.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/components/Dot.js +45 -0
- package/dist/module/features/fluency/visual-scaffolding/components/Dot.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/components/DynamicNumberLine.js +96 -0
- package/dist/module/features/fluency/visual-scaffolding/components/DynamicNumberLine.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/components/FactVisual.js +69 -0
- package/dist/module/features/fluency/visual-scaffolding/components/FactVisual.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/components/QuotativeBars.js +83 -0
- package/dist/module/features/fluency/visual-scaffolding/components/QuotativeBars.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/components/RelationalBlock.js +272 -0
- package/dist/module/features/fluency/visual-scaffolding/components/RelationalBlock.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/components/visualColors.js +41 -0
- package/dist/module/features/fluency/visual-scaffolding/components/visualColors.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/index.js +8 -0
- package/dist/module/features/fluency/visual-scaffolding/index.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/renderFact.js +269 -0
- package/dist/module/features/fluency/visual-scaffolding/renderFact.js.map +1 -0
- package/dist/module/features/fluency/visual-scaffolding/types.js +2 -0
- package/dist/module/features/fluency/visual-scaffolding/types.js.map +1 -0
- package/dist/module/features/fluency-teacher/assets/SortDefaultIcon.js +23 -0
- package/dist/module/features/fluency-teacher/assets/SortDefaultIcon.js.map +1 -0
- package/dist/module/features/fluency-teacher/components/FluencyTeacher.js +3 -4
- package/dist/module/features/fluency-teacher/components/FluencyTeacher.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/drawer/DrawerHeader.js +44 -49
- package/dist/module/features/fluency-teacher/components/drawer/DrawerHeader.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/drawer/DrawerMasteryLegend.js +74 -0
- package/dist/module/features/fluency-teacher/components/drawer/DrawerMasteryLegend.js.map +1 -0
- package/dist/module/features/fluency-teacher/components/drawer/DrawerMatrixes.js +31 -14
- package/dist/module/features/fluency-teacher/components/drawer/DrawerMatrixes.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/drawer/DrawerOperatorBox.js +45 -28
- package/dist/module/features/fluency-teacher/components/drawer/DrawerOperatorBox.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/drawer/DrawerOperatorStatCard.js +41 -48
- package/dist/module/features/fluency-teacher/components/drawer/DrawerOperatorStatCard.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/drawer/DrawerStats.js +27 -17
- package/dist/module/features/fluency-teacher/components/drawer/DrawerStats.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/drawer/FluencyTeacherDrawer.js +6 -6
- package/dist/module/features/fluency-teacher/components/drawer/FluencyTeacherDrawer.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/matrix/DrawerMatrix.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/matrix/MatrixCell.js +17 -3
- package/dist/module/features/fluency-teacher/components/matrix/MatrixCell.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/matrix/MatrixRow.js +2 -1
- package/dist/module/features/fluency-teacher/components/matrix/MatrixRow.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/table/AllPupilsTableRow.js +42 -16
- package/dist/module/features/fluency-teacher/components/table/AllPupilsTableRow.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/table/AverageSortButton.js +63 -7
- package/dist/module/features/fluency-teacher/components/table/AverageSortButton.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/table/FluencyTeacherStudentsTable.js +42 -44
- package/dist/module/features/fluency-teacher/components/table/FluencyTeacherStudentsTable.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/table/OperatorBadge.js +16 -25
- package/dist/module/features/fluency-teacher/components/table/OperatorBadge.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/table/TableColumnSortButton.js +42 -32
- package/dist/module/features/fluency-teacher/components/table/TableColumnSortButton.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/table/TableRow.js +75 -62
- package/dist/module/features/fluency-teacher/components/table/TableRow.js.map +1 -1
- package/dist/module/features/fluency-teacher/components/table/TableRowAverageProgress.js +65 -0
- package/dist/module/features/fluency-teacher/components/table/TableRowAverageProgress.js.map +1 -0
- package/dist/module/features/fluency-teacher/context/TeacherFluencyContext.js.map +1 -1
- package/dist/module/features/fluency-teacher/fluencyTeacher.constants.js +37 -102
- package/dist/module/features/fluency-teacher/fluencyTeacher.constants.js.map +1 -1
- package/dist/module/features/fluency-teacher/fluencyTeacher.helpers.js +8 -43
- package/dist/module/features/fluency-teacher/fluencyTeacher.helpers.js.map +1 -1
- package/dist/module/features/fluency-teacher/hooks/useDrawerGrid.js +2 -3
- package/dist/module/features/fluency-teacher/hooks/useDrawerGrid.js.map +1 -1
- package/dist/module/features/fluency-teacher/hooks/useDrawerMatrix.js.map +1 -1
- package/dist/module/features/fluency-teacher/model/TeacherFluencyFiltersModel.js +1 -2
- package/dist/module/features/fluency-teacher/model/TeacherFluencyFiltersModel.js.map +1 -1
- package/dist/module/features/fluency-teacher/model/TeacherFluencyModel.js +0 -9
- package/dist/module/features/fluency-teacher/model/TeacherFluencyModel.js.map +1 -1
- package/dist/typescript/commonjs/features/fluency/components/fluency-solving/components/DebugBoxIndicator.d.ts +3 -0
- package/dist/typescript/commonjs/features/fluency/components/fluency-solving/components/DebugBoxIndicator.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/components/fluency-solving/components/EquationContent.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency/components/fluency-solving/components/FluencyCardDeck.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency/components/fluency-solving/components/FluencyEquationCard.d.ts +2 -1
- package/dist/typescript/commonjs/features/fluency/components/fluency-solving/components/FluencyEquationCard.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency/components/fluency-solving/components/FluencySolvingHeader.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency/index.d.ts +1 -0
- package/dist/typescript/commonjs/features/fluency/index.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/__tests__/renderFact.test.d.ts +2 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/__tests__/renderFact.test.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/adapter.d.ts +4 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/adapter.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/DiscreteCounterGrid.d.ts +10 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/DiscreteCounterGrid.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/Dot.d.ts +10 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/Dot.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/DynamicNumberLine.d.ts +10 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/DynamicNumberLine.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/FactVisual.d.ts +10 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/FactVisual.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/QuotativeBars.d.ts +10 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/QuotativeBars.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/RelationalBlock.d.ts +10 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/RelationalBlock.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/visualColors.d.ts +16 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/components/visualColors.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/index.d.ts +6 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/index.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/renderFact.d.ts +23 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/renderFact.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/types.d.ts +103 -0
- package/dist/typescript/commonjs/features/fluency/visual-scaffolding/types.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency-teacher/assets/SortDefaultIcon.d.ts +4 -0
- package/dist/typescript/commonjs/features/fluency-teacher/assets/SortDefaultIcon.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/DrawerHeader.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/DrawerMasteryLegend.d.ts +3 -0
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/DrawerMasteryLegend.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/DrawerMatrixes.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/DrawerOperatorBox.d.ts +4 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/DrawerOperatorBox.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/DrawerOperatorStatCard.d.ts +4 -6
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/DrawerOperatorStatCard.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/DrawerStats.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/drawer/FluencyTeacherDrawer.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/DrawerMatrix.d.ts +2 -3
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/DrawerMatrix.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/MatrixCell.d.ts +5 -6
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/MatrixCell.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/MatrixHeaderRow.d.ts +1 -2
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/MatrixHeaderRow.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/MatrixRow.d.ts +3 -5
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/MatrixRow.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/AllPupilsTableRow.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/AverageSortButton.d.ts +1 -2
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/AverageSortButton.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/FluencyTeacherStudentsTable.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/OperatorBadge.d.ts +4 -5
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/OperatorBadge.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/TableColumnSortButton.d.ts +6 -7
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/TableColumnSortButton.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/TableRow.d.ts +3 -4
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/TableRow.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/TableRowAverageProgress.d.ts +7 -0
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/TableRowAverageProgress.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/fluency-teacher/context/TeacherFluencyContext.d.ts +0 -1
- package/dist/typescript/commonjs/features/fluency-teacher/context/TeacherFluencyContext.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/fluencyTeacher.constants.d.ts +3 -16
- package/dist/typescript/commonjs/features/fluency-teacher/fluencyTeacher.constants.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/fluencyTeacher.helpers.d.ts +4 -11
- package/dist/typescript/commonjs/features/fluency-teacher/fluencyTeacher.helpers.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/fluencyTeacher.types.d.ts +6 -35
- package/dist/typescript/commonjs/features/fluency-teacher/fluencyTeacher.types.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/hooks/useDrawerGrid.d.ts +12 -1
- package/dist/typescript/commonjs/features/fluency-teacher/hooks/useDrawerGrid.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/hooks/useDrawerMatrix.d.ts +3 -3
- package/dist/typescript/commonjs/features/fluency-teacher/hooks/useDrawerMatrix.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/model/TeacherFluencyFiltersModel.d.ts +0 -1
- package/dist/typescript/commonjs/features/fluency-teacher/model/TeacherFluencyFiltersModel.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/fluency-teacher/model/TeacherFluencyModel.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency/components/fluency-solving/components/DebugBoxIndicator.d.ts +3 -0
- package/dist/typescript/module/features/fluency/components/fluency-solving/components/DebugBoxIndicator.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/components/fluency-solving/components/EquationContent.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency/components/fluency-solving/components/FluencyCardDeck.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency/components/fluency-solving/components/FluencyEquationCard.d.ts +2 -1
- package/dist/typescript/module/features/fluency/components/fluency-solving/components/FluencyEquationCard.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency/components/fluency-solving/components/FluencySolvingHeader.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency/index.d.ts +1 -0
- package/dist/typescript/module/features/fluency/index.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency/visual-scaffolding/__tests__/renderFact.test.d.ts +2 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/__tests__/renderFact.test.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/adapter.d.ts +4 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/adapter.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/DiscreteCounterGrid.d.ts +10 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/DiscreteCounterGrid.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/Dot.d.ts +10 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/Dot.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/DynamicNumberLine.d.ts +10 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/DynamicNumberLine.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/FactVisual.d.ts +10 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/FactVisual.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/QuotativeBars.d.ts +10 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/QuotativeBars.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/RelationalBlock.d.ts +10 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/RelationalBlock.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/visualColors.d.ts +16 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/components/visualColors.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/index.d.ts +6 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/index.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/renderFact.d.ts +23 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/renderFact.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/types.d.ts +103 -0
- package/dist/typescript/module/features/fluency/visual-scaffolding/types.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency-teacher/assets/SortDefaultIcon.d.ts +4 -0
- package/dist/typescript/module/features/fluency-teacher/assets/SortDefaultIcon.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency-teacher/components/drawer/DrawerHeader.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/drawer/DrawerMasteryLegend.d.ts +3 -0
- package/dist/typescript/module/features/fluency-teacher/components/drawer/DrawerMasteryLegend.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency-teacher/components/drawer/DrawerMatrixes.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/drawer/DrawerOperatorBox.d.ts +4 -1
- package/dist/typescript/module/features/fluency-teacher/components/drawer/DrawerOperatorBox.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/drawer/DrawerOperatorStatCard.d.ts +4 -6
- package/dist/typescript/module/features/fluency-teacher/components/drawer/DrawerOperatorStatCard.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/drawer/DrawerStats.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/drawer/FluencyTeacherDrawer.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/matrix/DrawerMatrix.d.ts +2 -3
- package/dist/typescript/module/features/fluency-teacher/components/matrix/DrawerMatrix.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/matrix/MatrixCell.d.ts +5 -6
- package/dist/typescript/module/features/fluency-teacher/components/matrix/MatrixCell.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/matrix/MatrixHeaderRow.d.ts +1 -2
- package/dist/typescript/module/features/fluency-teacher/components/matrix/MatrixHeaderRow.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/matrix/MatrixRow.d.ts +3 -5
- package/dist/typescript/module/features/fluency-teacher/components/matrix/MatrixRow.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/AllPupilsTableRow.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/AverageSortButton.d.ts +1 -2
- package/dist/typescript/module/features/fluency-teacher/components/table/AverageSortButton.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/FluencyTeacherStudentsTable.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/OperatorBadge.d.ts +4 -5
- package/dist/typescript/module/features/fluency-teacher/components/table/OperatorBadge.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/TableColumnSortButton.d.ts +6 -7
- package/dist/typescript/module/features/fluency-teacher/components/table/TableColumnSortButton.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/TableRow.d.ts +3 -4
- package/dist/typescript/module/features/fluency-teacher/components/table/TableRow.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/TableRowAverageProgress.d.ts +7 -0
- package/dist/typescript/module/features/fluency-teacher/components/table/TableRowAverageProgress.d.ts.map +1 -0
- package/dist/typescript/module/features/fluency-teacher/context/TeacherFluencyContext.d.ts +0 -1
- package/dist/typescript/module/features/fluency-teacher/context/TeacherFluencyContext.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/fluencyTeacher.constants.d.ts +3 -16
- package/dist/typescript/module/features/fluency-teacher/fluencyTeacher.constants.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/fluencyTeacher.helpers.d.ts +4 -11
- package/dist/typescript/module/features/fluency-teacher/fluencyTeacher.helpers.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/fluencyTeacher.types.d.ts +6 -35
- package/dist/typescript/module/features/fluency-teacher/fluencyTeacher.types.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/hooks/useDrawerGrid.d.ts +12 -1
- package/dist/typescript/module/features/fluency-teacher/hooks/useDrawerGrid.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/hooks/useDrawerMatrix.d.ts +3 -3
- package/dist/typescript/module/features/fluency-teacher/hooks/useDrawerMatrix.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/model/TeacherFluencyFiltersModel.d.ts +0 -1
- package/dist/typescript/module/features/fluency-teacher/model/TeacherFluencyFiltersModel.d.ts.map +1 -1
- package/dist/typescript/module/features/fluency-teacher/model/TeacherFluencyModel.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/features/fluency/components/FluencySolving.tsx +2 -2
- package/src/features/fluency/components/fluency-solving/components/DebugBoxIndicator.tsx +40 -0
- package/src/features/fluency/components/fluency-solving/components/EquationContent.tsx +12 -8
- package/src/features/fluency/components/fluency-solving/components/FluencyCardDeck.tsx +6 -1
- package/src/features/fluency/components/fluency-solving/components/FluencyEquationCard.tsx +63 -11
- package/src/features/fluency/components/fluency-solving/components/FluencySolvingHeader.tsx +9 -0
- package/src/features/fluency/components/fluency-solving/components/FluencySolvingProgress.tsx +0 -2
- package/src/features/fluency/index.ts +1 -0
- package/src/features/fluency/visual-scaffolding/__tests__/__snapshots__/renderFact.test.ts.snap +64 -0
- package/src/features/fluency/visual-scaffolding/__tests__/renderFact.test.ts +192 -0
- package/src/features/fluency/visual-scaffolding/adapter.ts +33 -0
- package/src/features/fluency/visual-scaffolding/components/DiscreteCounterGrid.tsx +222 -0
- package/src/features/fluency/visual-scaffolding/components/Dot.tsx +36 -0
- package/src/features/fluency/visual-scaffolding/components/DynamicNumberLine.tsx +98 -0
- package/src/features/fluency/visual-scaffolding/components/FactVisual.tsx +61 -0
- package/src/features/fluency/visual-scaffolding/components/QuotativeBars.tsx +92 -0
- package/src/features/fluency/visual-scaffolding/components/RelationalBlock.tsx +225 -0
- package/src/features/fluency/visual-scaffolding/components/visualColors.ts +45 -0
- package/src/features/fluency/visual-scaffolding/index.ts +5 -0
- package/src/features/fluency/visual-scaffolding/renderFact.ts +219 -0
- package/src/features/fluency/visual-scaffolding/types.ts +108 -0
- package/src/features/fluency-teacher/assets/SortDefaultIcon.tsx +10 -0
- package/src/features/fluency-teacher/components/FluencyTeacher.tsx +3 -3
- package/src/features/fluency-teacher/components/drawer/DrawerHeader.tsx +35 -37
- package/src/features/fluency-teacher/components/drawer/DrawerMasteryLegend.tsx +63 -0
- package/src/features/fluency-teacher/components/drawer/DrawerMatrixes.tsx +32 -13
- package/src/features/fluency-teacher/components/drawer/DrawerOperatorBox.tsx +40 -20
- package/src/features/fluency-teacher/components/drawer/DrawerOperatorStatCard.tsx +35 -35
- package/src/features/fluency-teacher/components/drawer/DrawerStats.tsx +28 -16
- package/src/features/fluency-teacher/components/drawer/FluencyTeacherDrawer.tsx +5 -4
- package/src/features/fluency-teacher/components/matrix/DrawerMatrix.tsx +2 -3
- package/src/features/fluency-teacher/components/matrix/MatrixCell.tsx +16 -7
- package/src/features/fluency-teacher/components/matrix/MatrixHeaderRow.tsx +1 -1
- package/src/features/fluency-teacher/components/matrix/MatrixRow.tsx +4 -4
- package/src/features/fluency-teacher/components/table/AllPupilsTableRow.tsx +40 -13
- package/src/features/fluency-teacher/components/table/AverageSortButton.tsx +62 -8
- package/src/features/fluency-teacher/components/table/FluencyTeacherStudentsTable.tsx +35 -49
- package/src/features/fluency-teacher/components/table/OperatorBadge.tsx +11 -18
- package/src/features/fluency-teacher/components/table/TableColumnSortButton.tsx +49 -28
- package/src/features/fluency-teacher/components/table/TableRow.tsx +64 -65
- package/src/features/fluency-teacher/components/table/TableRowAverageProgress.tsx +65 -0
- package/src/features/fluency-teacher/context/TeacherFluencyContext.ts +0 -1
- package/src/features/fluency-teacher/fluencyTeacher.constants.ts +40 -138
- package/src/features/fluency-teacher/fluencyTeacher.helpers.ts +10 -82
- package/src/features/fluency-teacher/fluencyTeacher.types.ts +6 -39
- package/src/features/fluency-teacher/hooks/useDrawerGrid.ts +7 -4
- package/src/features/fluency-teacher/hooks/useDrawerMatrix.ts +3 -4
- package/src/features/fluency-teacher/model/TeacherFluencyFiltersModel.ts +5 -8
- package/src/features/fluency-teacher/model/TeacherFluencyModel.ts +0 -8
- package/dist/commonjs/features/fluency-teacher/assets/DivisionIcon.js.map +0 -1
- package/dist/commonjs/features/fluency-teacher/components/matrix/MatrixLegend.js +0 -83
- package/dist/commonjs/features/fluency-teacher/components/matrix/MatrixLegend.js.map +0 -1
- package/dist/commonjs/features/fluency-teacher/components/table/AverageCell.js +0 -55
- package/dist/commonjs/features/fluency-teacher/components/table/AverageCell.js.map +0 -1
- package/dist/commonjs/features/fluency-teacher/components/table/SortOrderCarets.js +0 -40
- package/dist/commonjs/features/fluency-teacher/components/table/SortOrderCarets.js.map +0 -1
- package/dist/commonjs/features/fluency-teacher/components/table/tableCell.styles.js +0 -45
- package/dist/commonjs/features/fluency-teacher/components/table/tableCell.styles.js.map +0 -1
- package/dist/module/features/fluency-teacher/assets/DivisionIcon.js +0 -26
- package/dist/module/features/fluency-teacher/assets/DivisionIcon.js.map +0 -1
- package/dist/module/features/fluency-teacher/components/matrix/MatrixLegend.js +0 -77
- package/dist/module/features/fluency-teacher/components/matrix/MatrixLegend.js.map +0 -1
- package/dist/module/features/fluency-teacher/components/table/AverageCell.js +0 -49
- package/dist/module/features/fluency-teacher/components/table/AverageCell.js.map +0 -1
- package/dist/module/features/fluency-teacher/components/table/SortOrderCarets.js +0 -34
- package/dist/module/features/fluency-teacher/components/table/SortOrderCarets.js.map +0 -1
- package/dist/module/features/fluency-teacher/components/table/tableCell.styles.js +0 -42
- package/dist/module/features/fluency-teacher/components/table/tableCell.styles.js.map +0 -1
- package/dist/typescript/commonjs/features/fluency-teacher/assets/DivisionIcon.d.ts +0 -4
- package/dist/typescript/commonjs/features/fluency-teacher/assets/DivisionIcon.d.ts.map +0 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/MatrixLegend.d.ts +0 -10
- package/dist/typescript/commonjs/features/fluency-teacher/components/matrix/MatrixLegend.d.ts.map +0 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/AverageCell.d.ts +0 -9
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/AverageCell.d.ts.map +0 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/SortOrderCarets.d.ts +0 -9
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/SortOrderCarets.d.ts.map +0 -1
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/tableCell.styles.d.ts +0 -35
- package/dist/typescript/commonjs/features/fluency-teacher/components/table/tableCell.styles.d.ts.map +0 -1
- package/dist/typescript/module/features/fluency-teacher/assets/DivisionIcon.d.ts +0 -4
- package/dist/typescript/module/features/fluency-teacher/assets/DivisionIcon.d.ts.map +0 -1
- package/dist/typescript/module/features/fluency-teacher/components/matrix/MatrixLegend.d.ts +0 -10
- package/dist/typescript/module/features/fluency-teacher/components/matrix/MatrixLegend.d.ts.map +0 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/AverageCell.d.ts +0 -9
- package/dist/typescript/module/features/fluency-teacher/components/table/AverageCell.d.ts.map +0 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/SortOrderCarets.d.ts +0 -9
- package/dist/typescript/module/features/fluency-teacher/components/table/SortOrderCarets.d.ts.map +0 -1
- package/dist/typescript/module/features/fluency-teacher/components/table/tableCell.styles.d.ts +0 -35
- package/dist/typescript/module/features/fluency-teacher/components/table/tableCell.styles.d.ts.map +0 -1
- package/src/features/fluency-teacher/assets/DivisionIcon.tsx +0 -20
- package/src/features/fluency-teacher/components/matrix/MatrixLegend.tsx +0 -81
- package/src/features/fluency-teacher/components/table/AverageCell.tsx +0 -45
- package/src/features/fluency-teacher/components/table/SortOrderCarets.tsx +0 -37
- package/src/features/fluency-teacher/components/table/tableCell.styles.ts +0 -39
|
@@ -53,10 +53,6 @@ export const EquationContent = ({
|
|
|
53
53
|
}: EquationContentProps) => {
|
|
54
54
|
const t = useText()
|
|
55
55
|
const modePreset = useFluencySolvingPreset({ mode })
|
|
56
|
-
const labelColor = status ? STATUS_COLOR[status] : COLORS.NEUTRAL_7
|
|
57
|
-
const labelText = status
|
|
58
|
-
? t(STATUS_LABELS[status], { answer: correctAnswer })
|
|
59
|
-
: t('student.fluency.typeYourAnswer')
|
|
60
56
|
const answerAreaColor =
|
|
61
57
|
status === AttemptStatus.INCORRECT ? COLORS.PRIMARY_RED : modePreset.colors.accent
|
|
62
58
|
|
|
@@ -65,9 +61,14 @@ export const EquationContent = ({
|
|
|
65
61
|
|
|
66
62
|
return (
|
|
67
63
|
<>
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
64
|
+
{status && (
|
|
65
|
+
<Typography
|
|
66
|
+
variant={HeadingVariants.H9}
|
|
67
|
+
style={[styles.cardLabel, { color: STATUS_COLOR[status] }]}
|
|
68
|
+
>
|
|
69
|
+
{t(STATUS_LABELS[status], { answer: correctAnswer })}
|
|
70
|
+
</Typography>
|
|
71
|
+
)}
|
|
71
72
|
<View style={styles.equationRow}>
|
|
72
73
|
<Typography style={styles.number}>{leftOperand}</Typography>
|
|
73
74
|
<Typography style={[styles.number, { color: modePreset.colors.accent }]}>
|
|
@@ -107,7 +108,10 @@ const styles = StyleSheet.create({
|
|
|
107
108
|
flexDirection: 'row',
|
|
108
109
|
alignItems: 'center',
|
|
109
110
|
gap: SPACING[300],
|
|
110
|
-
|
|
111
|
+
// The answer input hangs ~16px below the number row; counting that here
|
|
112
|
+
// makes the row's measured box match its visual extent, so the parent
|
|
113
|
+
// centers the equation accurately at any card height (visual or mastered).
|
|
114
|
+
paddingBottom: SPACING[400],
|
|
111
115
|
},
|
|
112
116
|
number: {
|
|
113
117
|
fontSize: 75,
|
|
@@ -45,7 +45,11 @@ export const FluencyCardDeck = ({
|
|
|
45
45
|
<Animated.View style={[styles.card, styles.cardMid, snapStyles.mid]} />
|
|
46
46
|
|
|
47
47
|
<Animated.View style={[styles.card, styles.cardNear, snapStyles.near]}>
|
|
48
|
-
<FluencyEquationCard
|
|
48
|
+
<FluencyEquationCard
|
|
49
|
+
cardContent={backingCardContent}
|
|
50
|
+
readOnly
|
|
51
|
+
showVisual={!!exitingCardContent}
|
|
52
|
+
/>
|
|
49
53
|
</Animated.View>
|
|
50
54
|
|
|
51
55
|
{!exitingCardContent && (
|
|
@@ -92,6 +96,7 @@ const styles = StyleSheet.create({
|
|
|
92
96
|
height: 260,
|
|
93
97
|
borderRadius: BORDER_RADIUS[400],
|
|
94
98
|
backgroundColor: COLORS.NEUTRAL_1,
|
|
99
|
+
overflow: 'hidden',
|
|
95
100
|
...SHADOWS[5],
|
|
96
101
|
},
|
|
97
102
|
cardFar: {
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
|
+
import { View, StyleSheet } from 'react-native'
|
|
3
|
+
import { SPACING } from '@magmamath/react-native-ui'
|
|
2
4
|
|
|
3
5
|
import { EquationContent } from './EquationContent'
|
|
6
|
+
import { FactVisual, renderFact, toFactPresentation, VISUAL_COLORS } from '../../../visual-scaffolding'
|
|
4
7
|
import type { FluencyCardDisplayContent, SolvingFact } from '../../../shared/fluencySolving.types'
|
|
5
8
|
import type { AttemptStatus, FluencyMode } from '../../../shared/fluency.constants'
|
|
6
9
|
|
|
@@ -14,6 +17,10 @@ type FluencyEquationCardProps = {
|
|
|
14
17
|
cardContent: FluencyCardDisplayContent
|
|
15
18
|
readOnly?: boolean
|
|
16
19
|
status?: AttemptStatus
|
|
20
|
+
// Whether to render the visual. The deck enables it on the active card, the
|
|
21
|
+
// exiting card, and the backing card *while it steps up*, so the visual is
|
|
22
|
+
// present as fast as the equation (no pop-in after the swipe).
|
|
23
|
+
showVisual?: boolean
|
|
17
24
|
onAnswerChange?: (text: string) => void
|
|
18
25
|
}
|
|
19
26
|
|
|
@@ -32,20 +39,65 @@ export const FluencyEquationCard = ({
|
|
|
32
39
|
cardContent,
|
|
33
40
|
readOnly = false,
|
|
34
41
|
status,
|
|
42
|
+
showVisual = true,
|
|
35
43
|
onAnswerChange,
|
|
36
44
|
}: FluencyEquationCardProps) => {
|
|
37
|
-
const
|
|
45
|
+
const { fact } = cardContent
|
|
46
|
+
const equation = getDisplayedEquation(fact)
|
|
47
|
+
|
|
48
|
+
const presentation = fact && showVisual ? toFactPresentation(fact) : null
|
|
49
|
+
const spec = presentation ? renderFact(presentation) : null
|
|
50
|
+
const colors = presentation ? VISUAL_COLORS[presentation.operation] : null
|
|
51
|
+
// Narrow away the "none" variant (L4/L5 → no visual).
|
|
52
|
+
const visualSpec = spec && spec.kind !== 'none' ? spec : null
|
|
38
53
|
|
|
39
54
|
return (
|
|
40
|
-
<
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
55
|
+
<View style={styles.body}>
|
|
56
|
+
{visualSpec && colors && (
|
|
57
|
+
<View style={[styles.visualZone, { backgroundColor: colors.bg }]}>
|
|
58
|
+
<FactVisual spec={visualSpec} colors={colors} />
|
|
59
|
+
</View>
|
|
60
|
+
)}
|
|
61
|
+
<View style={styles.eqZone}>
|
|
62
|
+
<EquationContent
|
|
63
|
+
leftOperand={equation.leftOperand}
|
|
64
|
+
rightOperand={equation.rightOperand}
|
|
65
|
+
mode={equation.mode}
|
|
66
|
+
value={cardContent.answer}
|
|
67
|
+
readOnly={readOnly}
|
|
68
|
+
status={status}
|
|
69
|
+
correctAnswer={fact?.answer}
|
|
70
|
+
onChange={onAnswerChange}
|
|
71
|
+
/>
|
|
72
|
+
</View>
|
|
73
|
+
</View>
|
|
50
74
|
)
|
|
51
75
|
}
|
|
76
|
+
|
|
77
|
+
const styles = StyleSheet.create({
|
|
78
|
+
body: {
|
|
79
|
+
flex: 1,
|
|
80
|
+
alignSelf: 'stretch',
|
|
81
|
+
},
|
|
82
|
+
// Tinted top zone (background set per operation), ~40% of the card height.
|
|
83
|
+
// Clips oversized visuals so the fixed-size card never grows.
|
|
84
|
+
visualZone: {
|
|
85
|
+
flex: 4,
|
|
86
|
+
alignSelf: 'stretch',
|
|
87
|
+
alignItems: 'center',
|
|
88
|
+
justifyContent: 'center',
|
|
89
|
+
overflow: 'hidden',
|
|
90
|
+
paddingVertical: SPACING[200],
|
|
91
|
+
paddingHorizontal: SPACING[400],
|
|
92
|
+
},
|
|
93
|
+
// White equation zone, ~60% of the card height. The equation is centered so
|
|
94
|
+
// it keeps whitespace above and below (and clears the negative-margin answer
|
|
95
|
+
// input under the card's overflow:hidden clip).
|
|
96
|
+
eqZone: {
|
|
97
|
+
flex: 6,
|
|
98
|
+
alignSelf: 'stretch',
|
|
99
|
+
alignItems: 'center',
|
|
100
|
+
justifyContent: 'center',
|
|
101
|
+
paddingHorizontal: SPACING[400],
|
|
102
|
+
},
|
|
103
|
+
})
|
|
@@ -13,6 +13,7 @@ import {
|
|
|
13
13
|
Typography,
|
|
14
14
|
} from '@magmamath/react-native-ui'
|
|
15
15
|
import { useFluencySolvingPreset } from '../../../hooks/useFluencySolvingPreset'
|
|
16
|
+
import { FluencySolvingProgress } from './FluencySolvingProgress'
|
|
16
17
|
import { XCloseIcon } from '../../../../../shared/icons/XCloseIcon'
|
|
17
18
|
|
|
18
19
|
type FluencySolvingHeaderProps = {
|
|
@@ -39,6 +40,9 @@ export const FluencySolvingHeader = ({ onClosePress }: FluencySolvingHeaderProps
|
|
|
39
40
|
<Typography variant={HeadingVariants.H4} style={styles.title}>
|
|
40
41
|
{modePreset.label}
|
|
41
42
|
</Typography>
|
|
43
|
+
<View style={styles.progress} pointerEvents="none">
|
|
44
|
+
<FluencySolvingProgress />
|
|
45
|
+
</View>
|
|
42
46
|
</View>
|
|
43
47
|
)
|
|
44
48
|
}
|
|
@@ -54,6 +58,11 @@ const styles = StyleSheet.create({
|
|
|
54
58
|
backgroundColor: COLORS.NEUTRAL_1,
|
|
55
59
|
...SHADOWS[1],
|
|
56
60
|
},
|
|
61
|
+
progress: {
|
|
62
|
+
...StyleSheet.absoluteFillObject,
|
|
63
|
+
alignItems: 'center',
|
|
64
|
+
justifyContent: 'center',
|
|
65
|
+
},
|
|
57
66
|
operatorBadge: {
|
|
58
67
|
width: 32,
|
|
59
68
|
height: 32,
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export * from './shared/fluency.constants'
|
|
2
2
|
export * from './shared/fluency.types'
|
|
3
3
|
export * from './shared/fluency.helpers'
|
|
4
|
+
export * from './visual-scaffolding'
|
|
4
5
|
export { Fluency } from './components/Fluency'
|
|
5
6
|
export { FluencySolving } from './components/FluencySolving'
|
|
6
7
|
export { FluencyModel } from './model/FluencyModel'
|
package/src/features/fluency/visual-scaffolding/__tests__/__snapshots__/renderFact.test.ts.snap
ADDED
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
|
|
2
|
+
|
|
3
|
+
exports[`L1 — DiscreteCounterGrid (box 0) addition 6 + 9 → two ten-frames, a tone-A + b tone-B 1`] = `
|
|
4
|
+
{
|
|
5
|
+
"kind": "grid",
|
|
6
|
+
"layout": {
|
|
7
|
+
"a": 6,
|
|
8
|
+
"b": 9,
|
|
9
|
+
"capacity": 10,
|
|
10
|
+
"type": "tenframes",
|
|
11
|
+
},
|
|
12
|
+
"left": 6,
|
|
13
|
+
"level": "L1",
|
|
14
|
+
"operation": "addition",
|
|
15
|
+
"right": 9,
|
|
16
|
+
}
|
|
17
|
+
`;
|
|
18
|
+
|
|
19
|
+
exports[`L2 — RelationalBlock (box 1) addition → bond with empty sum (top) node 1`] = `
|
|
20
|
+
{
|
|
21
|
+
"kind": "relational",
|
|
22
|
+
"left": 6,
|
|
23
|
+
"level": "L2",
|
|
24
|
+
"model": {
|
|
25
|
+
"bottomLeft": 6,
|
|
26
|
+
"bottomRight": 9,
|
|
27
|
+
"top": null,
|
|
28
|
+
"type": "bond",
|
|
29
|
+
},
|
|
30
|
+
"operation": "addition",
|
|
31
|
+
"right": 9,
|
|
32
|
+
}
|
|
33
|
+
`;
|
|
34
|
+
|
|
35
|
+
exports[`L3 — DynamicNumberLine (box 2) addition 7 + 6 → bridges 10 (7→10→13), end tick hidden 1`] = `
|
|
36
|
+
{
|
|
37
|
+
"hi": 13,
|
|
38
|
+
"hiddenTick": 13,
|
|
39
|
+
"jumps": [
|
|
40
|
+
{
|
|
41
|
+
"from": 7,
|
|
42
|
+
"label": "+3",
|
|
43
|
+
"to": 10,
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
"from": 10,
|
|
47
|
+
"label": "+3",
|
|
48
|
+
"to": 13,
|
|
49
|
+
},
|
|
50
|
+
],
|
|
51
|
+
"kind": "line",
|
|
52
|
+
"left": 7,
|
|
53
|
+
"level": "L3",
|
|
54
|
+
"lo": 0,
|
|
55
|
+
"operation": "addition",
|
|
56
|
+
"right": 6,
|
|
57
|
+
"ticks": [
|
|
58
|
+
0,
|
|
59
|
+
7,
|
|
60
|
+
10,
|
|
61
|
+
13,
|
|
62
|
+
],
|
|
63
|
+
}
|
|
64
|
+
`;
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import { renderFact, levelForBox, hasVisual } from '../renderFact'
|
|
2
|
+
import type { FactPresentation } from '../types'
|
|
3
|
+
|
|
4
|
+
describe('levelForBox', () => {
|
|
5
|
+
it.each([
|
|
6
|
+
[0, 'L1'],
|
|
7
|
+
[1, 'L2'],
|
|
8
|
+
[2, 'L3'],
|
|
9
|
+
[3, 'L4'],
|
|
10
|
+
[4, 'L5'],
|
|
11
|
+
] as const)('box %i → %s', (box, level) => {
|
|
12
|
+
expect(levelForBox(box)).toBe(level)
|
|
13
|
+
})
|
|
14
|
+
})
|
|
15
|
+
|
|
16
|
+
const fact = (
|
|
17
|
+
p: Partial<FactPresentation> & Pick<FactPresentation, 'operation'>,
|
|
18
|
+
): FactPresentation => ({ left: 0, right: 0, box: 0, ...p })
|
|
19
|
+
|
|
20
|
+
describe('L1 — DiscreteCounterGrid (box 0)', () => {
|
|
21
|
+
it('addition 6 + 9 → two ten-frames, a tone-A + b tone-B', () => {
|
|
22
|
+
const spec = renderFact(fact({ operation: 'addition', left: 6, right: 9, box: 0 }))
|
|
23
|
+
expect(spec).toMatchSnapshot()
|
|
24
|
+
if (spec.kind !== 'grid' || spec.layout.type !== 'tenframes') throw new Error('expected tenframes')
|
|
25
|
+
expect(spec.layout.a).toBe(6)
|
|
26
|
+
expect(spec.layout.b).toBe(9)
|
|
27
|
+
expect(spec.layout.capacity).toBe(10)
|
|
28
|
+
})
|
|
29
|
+
|
|
30
|
+
it('subtraction 15 − 9 → fill 15, strike last 9', () => {
|
|
31
|
+
const spec = renderFact(fact({ operation: 'subtraction', left: 15, right: 9, box: 0 }))
|
|
32
|
+
if (spec.kind !== 'grid' || spec.layout.type !== 'tenframes_takeaway') throw new Error('bad')
|
|
33
|
+
expect(spec.layout.total).toBe(15)
|
|
34
|
+
expect(spec.layout.removed).toBe(9)
|
|
35
|
+
})
|
|
36
|
+
|
|
37
|
+
it('multiplication 3 × 4 → 3 groups of 4', () => {
|
|
38
|
+
const spec = renderFact(fact({ operation: 'multiplication', left: 3, right: 4, box: 0 }))
|
|
39
|
+
if (spec.kind !== 'grid' || spec.layout.type !== 'groups') throw new Error('expected groups')
|
|
40
|
+
expect(spec.layout.groupCount).toBe(3)
|
|
41
|
+
expect(spec.layout.perGroup).toBe(4)
|
|
42
|
+
})
|
|
43
|
+
|
|
44
|
+
it('division 12 ÷ 4 → 3 clusters of 4', () => {
|
|
45
|
+
const spec = renderFact(fact({ operation: 'division', left: 12, right: 4, box: 0 }))
|
|
46
|
+
if (spec.kind !== 'grid' || spec.layout.type !== 'groups') throw new Error('expected groups')
|
|
47
|
+
expect(spec.layout.groupCount).toBe(3)
|
|
48
|
+
expect(spec.layout.perGroup).toBe(4)
|
|
49
|
+
})
|
|
50
|
+
})
|
|
51
|
+
|
|
52
|
+
describe('L2 — RelationalBlock (box 1)', () => {
|
|
53
|
+
it('addition → bond with empty sum (top) node', () => {
|
|
54
|
+
const spec = renderFact(fact({ operation: 'addition', left: 6, right: 9, box: 1 }))
|
|
55
|
+
expect(spec).toMatchSnapshot()
|
|
56
|
+
if (spec.kind !== 'relational' || spec.model.type !== 'bond') throw new Error('expected bond')
|
|
57
|
+
expect(spec.model.top).toBeNull()
|
|
58
|
+
expect(spec.model.bottomLeft).toBe(6)
|
|
59
|
+
expect(spec.model.bottomRight).toBe(9)
|
|
60
|
+
})
|
|
61
|
+
|
|
62
|
+
it('subtraction → bond with empty part (bottom-right) node', () => {
|
|
63
|
+
const spec = renderFact(fact({ operation: 'subtraction', left: 15, right: 9, box: 1 }))
|
|
64
|
+
if (spec.kind !== 'relational' || spec.model.type !== 'bond') throw new Error('expected bond')
|
|
65
|
+
expect(spec.model.top).toBe(15)
|
|
66
|
+
expect(spec.model.bottomLeft).toBe(9)
|
|
67
|
+
expect(spec.model.bottomRight).toBeNull()
|
|
68
|
+
})
|
|
69
|
+
|
|
70
|
+
it('multiplication (box 1) → number line: three +4 hops, end hidden', () => {
|
|
71
|
+
const spec = renderFact(fact({ operation: 'multiplication', left: 3, right: 4, box: 1 }))
|
|
72
|
+
if (spec.kind !== 'line') throw new Error('expected line')
|
|
73
|
+
expect(spec.jumps.map((j) => j.to)).toEqual([4, 8, 12])
|
|
74
|
+
expect(spec.ticks).toEqual([0, 4, 8, 12])
|
|
75
|
+
expect(spec.hiddenTick).toBe(12)
|
|
76
|
+
})
|
|
77
|
+
|
|
78
|
+
it('division (box 1) → quotative bars: 3 groups of 4 spanning 12', () => {
|
|
79
|
+
const spec = renderFact(fact({ operation: 'division', left: 12, right: 4, box: 1 }))
|
|
80
|
+
if (spec.kind !== 'bars') throw new Error('expected bars')
|
|
81
|
+
expect(spec.total).toBe(12)
|
|
82
|
+
expect(spec.segment).toBe(4)
|
|
83
|
+
expect(spec.segmentCount).toBe(3)
|
|
84
|
+
})
|
|
85
|
+
})
|
|
86
|
+
|
|
87
|
+
describe('L3 — DynamicNumberLine (box 2)', () => {
|
|
88
|
+
it('addition 7 + 6 → bridges 10 (7→10→13), end tick hidden', () => {
|
|
89
|
+
const spec = renderFact(fact({ operation: 'addition', left: 7, right: 6, box: 2 }))
|
|
90
|
+
expect(spec).toMatchSnapshot()
|
|
91
|
+
if (spec.kind !== 'line') throw new Error('expected line')
|
|
92
|
+
expect(spec.jumps).toEqual([
|
|
93
|
+
{ from: 7, to: 10, label: '+3' },
|
|
94
|
+
{ from: 10, to: 13, label: '+3' },
|
|
95
|
+
])
|
|
96
|
+
expect(spec.ticks).toEqual([0, 7, 10, 13])
|
|
97
|
+
expect(spec.hiddenTick).toBe(13)
|
|
98
|
+
})
|
|
99
|
+
|
|
100
|
+
it('addition 4 + 3 → single jump, no bridge', () => {
|
|
101
|
+
const spec = renderFact(fact({ operation: 'addition', left: 4, right: 3, box: 2 }))
|
|
102
|
+
if (spec.kind !== 'line') throw new Error('expected line')
|
|
103
|
+
expect(spec.jumps).toEqual([{ from: 4, to: 7, label: '+3' }])
|
|
104
|
+
expect(spec.ticks).toEqual([0, 4, 7])
|
|
105
|
+
})
|
|
106
|
+
|
|
107
|
+
it('subtraction 13 − 5 → backward, bridges 10 (13→10→8)', () => {
|
|
108
|
+
const spec = renderFact(fact({ operation: 'subtraction', left: 13, right: 5, box: 2 }))
|
|
109
|
+
if (spec.kind !== 'line') throw new Error('expected line')
|
|
110
|
+
expect(spec.jumps).toEqual([
|
|
111
|
+
{ from: 13, to: 10, label: '−3' },
|
|
112
|
+
{ from: 10, to: 8, label: '−2' },
|
|
113
|
+
])
|
|
114
|
+
expect(spec.lo).toBe(8)
|
|
115
|
+
expect(spec.hi).toBe(13)
|
|
116
|
+
expect(spec.hiddenTick).toBe(8)
|
|
117
|
+
})
|
|
118
|
+
|
|
119
|
+
it('addition 8 + 15 → bridges every ten (8→10→20→23)', () => {
|
|
120
|
+
const spec = renderFact(fact({ operation: 'addition', left: 8, right: 15, box: 2 }))
|
|
121
|
+
if (spec.kind !== 'line') throw new Error('expected line')
|
|
122
|
+
expect(spec.jumps).toEqual([
|
|
123
|
+
{ from: 8, to: 10, label: '+2' },
|
|
124
|
+
{ from: 10, to: 20, label: '+10' },
|
|
125
|
+
{ from: 20, to: 23, label: '+3' },
|
|
126
|
+
])
|
|
127
|
+
expect(spec.ticks).toEqual([0, 8, 10, 20, 23])
|
|
128
|
+
expect(spec.hiddenTick).toBe(23)
|
|
129
|
+
})
|
|
130
|
+
|
|
131
|
+
it('subtraction 23 − 15 → steps back through every ten (23→20→10→8)', () => {
|
|
132
|
+
const spec = renderFact(fact({ operation: 'subtraction', left: 23, right: 15, box: 2 }))
|
|
133
|
+
if (spec.kind !== 'line') throw new Error('expected line')
|
|
134
|
+
expect(spec.jumps).toEqual([
|
|
135
|
+
{ from: 23, to: 20, label: '−3' },
|
|
136
|
+
{ from: 20, to: 10, label: '−10' },
|
|
137
|
+
{ from: 10, to: 8, label: '−2' },
|
|
138
|
+
])
|
|
139
|
+
expect(spec.ticks).toEqual([8, 10, 20, 23])
|
|
140
|
+
expect(spec.hiddenTick).toBe(8)
|
|
141
|
+
})
|
|
142
|
+
|
|
143
|
+
it('multiplication (box 2) → area model with empty center (first factor = vertical side)', () => {
|
|
144
|
+
const spec = renderFact(fact({ operation: 'multiplication', left: 3, right: 4, box: 2 }))
|
|
145
|
+
if (spec.kind !== 'relational' || spec.model.type !== 'area') throw new Error('expected area')
|
|
146
|
+
// "3×4" = 3 rows of 4: left (3) → height (side), right (4) → width (top).
|
|
147
|
+
expect(spec.model.top).toBe(4)
|
|
148
|
+
expect(spec.model.side).toBe(3)
|
|
149
|
+
expect(spec.model.center).toBeNull()
|
|
150
|
+
})
|
|
151
|
+
|
|
152
|
+
it('division (box 2) → area model with empty side, dividend in center', () => {
|
|
153
|
+
const spec = renderFact(fact({ operation: 'division', left: 12, right: 4, box: 2 }))
|
|
154
|
+
if (spec.kind !== 'relational' || spec.model.type !== 'area') throw new Error('expected area')
|
|
155
|
+
expect(spec.model.top).toBe(4)
|
|
156
|
+
expect(spec.model.side).toBeNull()
|
|
157
|
+
expect(spec.model.center).toBe(12)
|
|
158
|
+
})
|
|
159
|
+
})
|
|
160
|
+
|
|
161
|
+
describe('L4 / L5 — no visual', () => {
|
|
162
|
+
it.each([3, 4] as const)('box %i → none', (box) => {
|
|
163
|
+
const spec = renderFact(fact({ operation: 'multiplication', left: 7, right: 8, box }))
|
|
164
|
+
expect(spec.kind).toBe('none')
|
|
165
|
+
expect(hasVisual(fact({ operation: 'multiplication', left: 7, right: 8, box }))).toBe(false)
|
|
166
|
+
})
|
|
167
|
+
})
|
|
168
|
+
|
|
169
|
+
describe('orientation matches the prompt', () => {
|
|
170
|
+
it('3×4 ≠ 4×3 as L1 groups (first factor = number of groups)', () => {
|
|
171
|
+
const a = renderFact(fact({ operation: 'multiplication', left: 3, right: 4, box: 0 }))
|
|
172
|
+
const b = renderFact(fact({ operation: 'multiplication', left: 4, right: 3, box: 0 }))
|
|
173
|
+
if (a.kind !== 'grid' || a.layout.type !== 'groups') throw new Error('bad')
|
|
174
|
+
if (b.kind !== 'grid' || b.layout.type !== 'groups') throw new Error('bad')
|
|
175
|
+
expect([a.layout.groupCount, a.layout.perGroup]).toEqual([3, 4])
|
|
176
|
+
expect([b.layout.groupCount, b.layout.perGroup]).toEqual([4, 3])
|
|
177
|
+
})
|
|
178
|
+
})
|
|
179
|
+
|
|
180
|
+
describe('defensive guards', () => {
|
|
181
|
+
it('subtracting more than the minuend clamps removed', () => {
|
|
182
|
+
const spec = renderFact(fact({ operation: 'subtraction', left: 3, right: 9, box: 0 }))
|
|
183
|
+
if (spec.kind !== 'grid' || spec.layout.type !== 'tenframes_takeaway') throw new Error('bad')
|
|
184
|
+
expect(spec.layout.removed).toBe(3)
|
|
185
|
+
})
|
|
186
|
+
|
|
187
|
+
it('division by zero does not throw', () => {
|
|
188
|
+
const spec = renderFact(fact({ operation: 'division', left: 8, right: 0, box: 0 }))
|
|
189
|
+
if (spec.kind !== 'grid' || spec.layout.type !== 'groups') throw new Error('bad')
|
|
190
|
+
expect(spec.layout.groupCount).toBe(0)
|
|
191
|
+
})
|
|
192
|
+
})
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Adapts the fluency model's `SolvingFact` (the shape held in
|
|
3
|
+
* `FluencyModel.solving.$current`) to the pure `FactPresentation` contract.
|
|
4
|
+
*
|
|
5
|
+
* The picker has already resolved the presented direction, so `numbers` is in
|
|
6
|
+
* prompt order: numbers[0] = left, numbers[1] = right. `mode` is the operation
|
|
7
|
+
* (its enum values match `Operation` exactly), and `box` is the Leitner box.
|
|
8
|
+
*/
|
|
9
|
+
import { FluencyMode } from '../shared/fluency.constants'
|
|
10
|
+
import type { SolvingFact } from '../shared/fluencySolving.types'
|
|
11
|
+
import type { FactPresentation, Operation } from './types'
|
|
12
|
+
|
|
13
|
+
const MODE_TO_OPERATION: Record<FluencyMode, Operation> = {
|
|
14
|
+
[FluencyMode.ADDITION]: 'addition',
|
|
15
|
+
[FluencyMode.SUBTRACTION]: 'subtraction',
|
|
16
|
+
[FluencyMode.MULTIPLICATION]: 'multiplication',
|
|
17
|
+
[FluencyMode.DIVISION]: 'division',
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
const clampBox = (box: number): FactPresentation['box'] => {
|
|
21
|
+
const clamped = Math.max(0, Math.min(4, Math.round(box)))
|
|
22
|
+
return clamped as FactPresentation['box']
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export function toFactPresentation(fact: SolvingFact): FactPresentation {
|
|
26
|
+
const [left, right] = fact.numbers
|
|
27
|
+
return {
|
|
28
|
+
operation: MODE_TO_OPERATION[fact.mode],
|
|
29
|
+
left,
|
|
30
|
+
right,
|
|
31
|
+
box: clampBox(fact.box),
|
|
32
|
+
}
|
|
33
|
+
}
|