Skip to content

Videos updated and Small Theme Addition With Some Bug Fixes (REOPENED)#74

Closed
impxcts wants to merge 20 commits intomainfrom
updatedVideos
Closed

Videos updated and Small Theme Addition With Some Bug Fixes (REOPENED)#74
impxcts wants to merge 20 commits intomainfrom
updatedVideos

Conversation

@impxcts
Copy link
Copy Markdown
Contributor

@impxcts impxcts commented May 6, 2026

This PR fixes an issue where there was originally a white screen that would appear rather than the application. This was due to the missing getCuratedVideosForTopics export inside of the subjectVideos.js file. I also did fix some minor issues such as some of the videos under Pre-Algebra either not playing properly or not working at all.

A small addition I did add was a 'galaxy' theme for the user to select in the 'themes' selection.

I also did have to fix an issue where there was a naming consistency issue inside subjectVideos.test.js as well as exports the getYouTubeVideoId function to fix a testing issue.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

…udes: saving, saved x minutes ago, offline pending, etc.
@impxcts
Copy link
Copy Markdown
Contributor Author

impxcts commented May 6, 2026

A new addition was that I added a time stamp for how long ago the changes/additions were made/saved.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 6 out of 7 changed files in this pull request and generated 15 comments.

Files not reviewed (1)
  • frontend/package-lock.json: Language not supported
Comments suppressed due to low confidence (2)

frontend/src/components/CreateCheatSheet.jsx:1424

  • aria-label="Compile PDF" overrides the button’s accessible name, so screen readers will announce “Compile PDF” even though the visible label is “GET CHEAT SHEET”. Either remove the aria-label (the visible text is sufficient) or make it match the visible label so assistive tech users get consistent wording.
                  required
                  className="input-field"
                />
              </div>

              <FormulaSelection
                classesData={classesData}
                selectedClasses={selectedClasses}

frontend/src/components/CreateCheatSheet.jsx:1423

  • The new CSS includes styles for .btn-compile.is-compiling, but the button never toggles an is-compiling class (it only sets disabled={isCompiling}). Consider conditionally adding is-compiling to the button’s className when isCompiling is true, otherwise the shimmer/spin styles will never apply.
              </div>

              <FormulaSelection
                classesData={classesData}

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +1 to +5
import { afterEach, describe, expect, it } from 'vitest';

// Mock the dependencies
vi.mock('../hooks/formulas');
vi.mock('../hooks/latex');
vi.mock('../hooks/youtubeResources');
vi.mock('react-pdf', () => ({
Document: ({ children }) => <div data-testid="mock-document">{children}</div>,
Page: () => <div data-testid="mock-page" />,
pdfjs: { GlobalWorkerOptions: { workerSrc: '' } }
}));
import { SUBJECT_VIDEOS, getCuratedVideosForTopics, getYouTubeVideoId } from '../data/subjectVideos';

describe('CreateCheatSheet Component', () => {
const mockUseFormulas = {
classesData: [
{
name: 'Math 101',
categories: [
{ name: 'Algebra', formulas: [] }
]
}
],
selectedClasses: {},
selectedCategories: {},
groupedFormulas: [],
toggleClass: vi.fn(),
toggleCategory: vi.fn(),
getSelectedFormulasList: vi.fn(),
clearSelections: vi.fn(),
reorderClass: vi.fn(),
reorderFormula: vi.fn(),
removeClassFromOrder: vi.fn(),
removeSingleFormula: vi.fn(),
selectedCount: 0,
hasSelectedClasses: false
};

const mockUseLatex = {
title: '',
setTitle: vi.fn(),
content: '',
contentModified: false,
contentSource: 'empty',
canRegenerateFromSelections: true,
hasLayoutChanges: false,
handleContentChange: vi.fn(),
columns: 4,
setColumns: vi.fn(),
fontSize: '9pt',
setFontSize: vi.fn(),
spacing: 'small',
setSpacing: vi.fn(),
margins: '0.15in',
setMargins: vi.fn(),
pdfBlob: null,
isGenerating: false,
isCompiling: false,
isLoading: false,
compileError: null,
canGoBack: false,
canGoForward: false,
goBack: vi.fn(),
goForward: vi.fn(),
handleGenerateSheet: vi.fn(),
handlePreview: vi.fn(),
handleCompileOnly: vi.fn(),
handleDownloadPDF: vi.fn(),
handleDownloadTex: vi.fn(),
clearLatex: vi.fn()
};

beforeEach(() => {
vi.clearAllMocks();
window.ResizeObserver = class ResizeObserver {
observe = vi.fn();
disconnect = vi.fn();
};
CURATED_SUBJECT_VIDEOS['Math 101'] = [];
useFormulas.mockReturnValue(mockUseFormulas);
useLatex.mockReturnValue(mockUseLatex);
useYouTubeResources.mockReturnValue({ resources: [], isLoading: false, error: '', topicLimit: 6 });
describe('subjectVideos helpers', () => {
Comment thread frontend/src/data/subjectVideos.js Outdated
title: "Types of Angles and Angle Relationships",
videoId: "dA94zyaLuhk",
channel: "Professor Dave Explains",
topic: "Angle Relationships"
Comment thread frontend/src/data/subjectVideos.js Outdated
Comment on lines +299 to +305
topic: "Functions and Graphs"
},
{
title: "Verifying Trigonometric Identities",
videoId: "LlFbHDQVRk4",
channel: "The Organic Chemistry Tutor",
topic: "Functions and Graphs"
Comment thread frontend/src/data/subjectVideos.js Outdated
Comment on lines +354 to +361
channel: "The Organic Chemistry Tutor",
topic: "Derivatives"
},
{
title: "Calculus 1 Full Course",
videoId: "5yfh5cf4-0w",
channel: "Professor Leonard",
topic: "Derivatives"
Comment thread frontend/src/data/subjectVideos.js Outdated
title: "Momentum and Impulse",
videoId: "40sww1q5_hc",
channel: "The Organic Chemistry Tutor",
topic: "Momentum and Collisions"
Comment thread frontend/src/data/subjectVideos.js Outdated
Comment thread frontend/src/data/subjectVideos.js Outdated
title: "Statistics Exam 1 Review",
videoId: "xxpc-HPWX28",
channel: "The Organic Chemistry Tutor",
topic: "Descriptive Stats"
Comment thread frontend/src/data/subjectVideos.js Outdated
title: "What Is Statistics: Crash Course #1",
videoId: "zouPoc49xbk",
channel: "CrashCourse",
topic: "Intro to Statistics"
Comment on lines +482 to +483
channel: "The Organic Chemistry Tutor",
topic: "Hypothesis Testing"
@bdtran2002 bdtran2002 closed this May 6, 2026
@impxcts impxcts reopened this May 6, 2026
@impxcts impxcts closed this May 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants