Skip to content

Conversation

ianyong
Copy link
Member

@ianyong ianyong commented Oct 11, 2022

Description

Merging the (disabled) feature into master so as to avoid a single big bang integration at the end which might have a lot of conflicts. Please see the squashed commits and their respective PRs for more information on the changes.

Part of #2176.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update
  • Code quality improvements

How to test

There should not be any change in behaviour since the feature is disabled on production.

@ianyong ianyong requested a review from chownces October 11, 2022 04:11
@ianyong
Copy link
Member Author

ianyong commented Oct 11, 2022

@chownces I'll need your help in merging without squashing (so as to preserve the git history of the feature branch), thank you!

@coveralls
Copy link

coveralls commented Oct 11, 2022

Pull Request Test Coverage Report for Build 3226226277

  • 3 of 283 (1.06%) changed or added relevant lines in 19 files are covered.
  • 7 unchanged lines in 4 files lost coverage.
  • Overall coverage decreased (-0.6%) to 32.968%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/commons/editingWorkspace/EditingWorkspace.tsx 0 1 0.0%
src/commons/utils/DialogHelper.tsx 0 1 0.0%
src/pages/githubAssessments/GitHubAssessmentWorkspace.tsx 0 1 0.0%
src/commons/sideContent/SideContentHelper.ts 1 4 25.0%
src/commons/fileSystemView/FileSystemViewIndentationPadding.tsx 0 5 0.0%
src/commons/mobileWorkspace/mobileSideContent/MobileSideContent.tsx 1 6 16.67%
src/commons/sideContent/SideContent.tsx 0 6 0.0%
src/commons/delay/Delay.tsx 0 7 0.0%
src/pages/fileSystem/FileSystemProvider.tsx 0 8 0.0%
src/commons/fileSystemView/FileSystemViewContextMenu.tsx 0 10 0.0%
Files with Coverage Reduction New Missed Lines %
src/commons/sideContent/SideContentHelper.ts 1 11.54%
src/commons/sideContent/SideContent.tsx 1 1.82%
src/pages/githubAssessments/GitHubAssessmentWorkspace.tsx 1 0.24%
src/commons/mobileWorkspace/mobileSideContent/MobileSideContent.tsx 4 1.72%
Totals Coverage Status
Change from base Build 3225205971: -0.6%
Covered Lines: 4334
Relevant Lines: 12234

💛 - Coveralls

* Move editor out of MobileSideContent into MobileWorkspace

This is consistent with the desktop equivalent files of SideContent
& Workspace, where the editor is a child of Workspace.

* Remove manual rendering of the editor

No longer needed as the editor is no longer hidden, only overlaid.

* Fix side content panels overlapping control bar
…ce (#2206)

* Move REPL run logic out of MobileSideContent into MobileWorkspace

* Standardise signature of handleShowRepl with that of handleHideRepl

* Separate out checks in handleTabChangeForRepl for readability

* Fix comment ending with a comma instead of period
* Specify tab positions relative to dynamic tabs in MobileSideContent

This removes the implicit precondition that the mobile run tab is
the last element of the tabs array.

* Align the interface of SideContent with MobileSideContent

For consistency.
* Add BrowserFS as a dependency

* Initialise file system & inject via FileSystemProvider
* Move responsibility of converting module tabs into getDynamicTabs

* Remove unnecessary toSpawn property on SideContentTab

* Remove unused Modules type
* Add sidebar to workspace layout

* Add SideBar component & preliminary sideways styling

* Add styling for sidebar tabs

* Collapse tab padding styling into a single property

* Add notion of SideBarTab

* Add tab selection state to SideBar

* Allow unselecting of tabs in SideBar

* Prevent selecting of SideBar tab text

* Fix SideBar tab styling in Firefox

* Add SideBar panel

* Make SideBar accept the list of tabs as a property

This is similar to SideContent.

* Update AssessmentWorkspace snapshots

To account for the addition of sideBarProps.

* Add FileSystemView and logic to read list of files

Directories are just a special case of files.

* Add FileSystemViewNode

* Remove padding in sidebar panel

* Add preliminary layout styling

* Add logic to determine whether a file is a file or directory

* Extract out directory listing concerns into FileSystemViewList

* Add directory & file nodes to handle file type specific behaviour

* Add toggling of expanded/collapsed state of directory node

* Add directory & file icons

* Add indentation to files under directories

* Fix indentation being slightly misaligned

* Prevent selecting of file system view text

* Add dependency on @szhsin/react-menu

* Add FileSystemViewContextMenu

* Undo unintended change in comment when refactoring

* Fix overflow when resizing workspace

* Remove unused CSS style

* Dynamically display context menu options based off callback props

* Add renaming of files

* Add check to prevent overwriting existing files when renaming

* Extract out renaming logic into FileSystemViewFileName

* Add renaming of directories

* Fix directory context menu applying to children

* Display directories before files, then sort by alphabetical order

* Fix context menu not appearing in between file entries

Resolved by making use of padding (which are considered part of
the element) rather than gaps.

* Change background colour of file entries on hover

* Move responsibility of indentations into file entries

This is so that clicking anywhere within the row of a file entry
will result in the file entry handling the click.

* Add styling to context menu

* Add creating of files

* Add deleting of files

* Forcibly re-render list after file creation

* Lose focus when escape key is pressed

* Add creating of directories

* Add error dialog when renaming to an existing file/directory name

* Add error dialog when adding a duplicate file/directory

* Fix context menu appearing underneath editor & prevent line breaks

* Add deleting of directories

* Implement recursive directory removal

* Style file system error message

* Display spinner while directory contents are being loaded

* Add context menu to the empty space in the file system view

* Fix context menu items text being center aligned

* Add creating of files in the root directory

* Add creating of directories in the root directory

* Add confirmation prompt before deleting files

* Add confirmation prompt before deleting directories

* Introduce delay before rendering spinner to prevent flickering

* Remove test sidebar tab

* Remove leftover TODO

* Add automatic selection of file/directory name when renaming

* Remove shifting around of file entries when renaming

* Add scrolling to file system view when file names overflow

* Make time unit in Delay obvious & add header comment

* Remove white space at intersection of scrollbars on Chromium browsers

* Disable spellcheck in Input elements

* Disable toggling of directory expanded state when renaming

* Fix hidden scrollbars taking up space on Chromium browsers

* Rename 'Project' sidebar tab to 'Files'
@ianyong ianyong force-pushed the multiple-files-and-directories branch from 5b9d217 to 8d92d3e Compare October 11, 2022 10:53
Copy link
Contributor

@chownces chownces left a comment

Choose a reason for hiding this comment

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

Let's get this merged in as per discussion this week.

@chownces chownces merged commit 40c3ea4 into master Oct 14, 2022
@ianyong ianyong deleted the multiple-files-and-directories branch October 15, 2022 04:52
@coveralls
Copy link

coveralls commented Sep 21, 2024

Pull Request Test Coverage Report for Build 3224065056

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 4 of 287 (1.39%) changed or added relevant lines in 20 files are covered.
  • 88 unchanged lines in 5 files lost coverage.
  • Overall coverage decreased (-0.6%) to 32.935%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/commons/editingWorkspace/EditingWorkspace.tsx 0 1 0.0%
src/commons/utils/DialogHelper.tsx 0 1 0.0%
src/pages/githubAssessments/GitHubAssessmentWorkspace.tsx 0 1 0.0%
src/commons/sideContent/SideContentHelper.ts 1 4 25.0%
src/pages/playground/Playground.tsx 1 4 25.0%
src/commons/fileSystemView/FileSystemViewIndentationPadding.tsx 0 5 0.0%
src/commons/mobileWorkspace/mobileSideContent/MobileSideContent.tsx 1 6 16.67%
src/commons/sideContent/SideContent.tsx 0 6 0.0%
src/commons/delay/Delay.tsx 0 7 0.0%
src/pages/fileSystem/FileSystemProvider.tsx 0 8 0.0%
Files with Coverage Reduction New Missed Lines %
src/commons/sideContent/SideContentHelper.ts 1 11.54%
src/commons/sideContent/SideContent.tsx 1 1.89%
src/pages/githubAssessments/GitHubAssessmentWorkspace.tsx 1 0.24%
src/commons/mobileWorkspace/mobileSideContent/MobileSideContent.tsx 4 1.72%
src/pages/playground/Playground.tsx 81 3.64%
Totals Coverage Status
Change from base Build 3191096515: -0.6%
Covered Lines: 4312
Relevant Lines: 12193

💛 - Coveralls

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.

3 participants