ICRAR / EAGLE

Editor for the Astronomical Graph Language Environment
GNU Lesser General Public License v3.0
0 stars 1 forks source link

Eagle 1324 #767

Closed M-Wicenec closed 1 week ago

M-Wicenec commented 1 week ago

keyboard shortcuts for opening the various tables (t, alt t, and shift t) now use a new function to toggle the bottom window mode if the requested table is already open.

ive changed the shortcuts for the left, right, bottom and toggle all windows to use the arrow keys rather than l, r and b.

updated some function names and comments away from being 'modal' related, they are no longer modals. But there are a few remaining places where that tern is used.

Summary by Sourcery

Update keyboard shortcuts and refactor modal functions to table functions for improved UI interaction.

Enhancements:

sourcery-ai[bot] commented 1 week ago

Reviewer's Guide by Sourcery

This PR updates keyboard shortcuts and window management functionality, primarily focusing on replacing modal-based UI elements with a more modern bottom window approach. The changes include new toggle functionality for tables and updated keyboard shortcuts using arrow keys for window management.

Updated class diagram for ParameterTable

classDiagram
    class ParameterTable {
        +toggleTable(mode: Eagle.BottomWindowMode, selectType: ParameterTable.SelectType)
        +openTable(mode: Eagle.BottomWindowMode, selectType: ParameterTable.SelectType)
        +openTableAndSelectField(node: Node, field: Field)
    }
    note for ParameterTable "Replaced openModal with openTable and toggleTable methods"

Updated class diagram for GraphConfigurationsTable

classDiagram
    class GraphConfigurationsTable {
        +toggleTable()
        +openTable()
    }
    note for GraphConfigurationsTable "Replaced openModal with openTable and toggleTable methods"

File-Level Changes

Change Details Files
Replaced modal-based UI elements with bottom window functionality
  • Renamed openModal functions to openTable to reflect the new implementation
  • Added new toggleTable functions that check if the requested table is already open
  • Updated function calls throughout the codebase to use the new table functions
  • Removed legacy modal-related code and comments
src/ParameterTable.ts
src/GraphConfigurationsTable.ts
templates/base.html
templates/navbar.html
templates/inspector.html
Updated keyboard shortcuts for window management
  • Changed window toggle shortcuts to use arrow keys instead of l, r, and b
  • Added new shortcut for bottom window toggle using ArrowDown
  • Updated toggle all windows shortcut to use ArrowUp
  • Modified table shortcuts to use toggle functionality when the table is already open
src/KeyboardShortcut.ts
src/Eagle.ts

Tips and commands #### Interacting with Sourcery - **Trigger a new review:** Comment `@sourcery-ai review` on the pull request. - **Continue discussions:** Reply directly to Sourcery's review comments. - **Generate a GitHub issue from a review comment:** Ask Sourcery to create an issue from a review comment by replying to it. - **Generate a pull request title:** Write `@sourcery-ai` anywhere in the pull request title to generate a title at any time. - **Generate a pull request summary:** Write `@sourcery-ai summary` anywhere in the pull request body to generate a PR summary at any time. You can also use this command to specify where the summary should be inserted. #### Customizing Your Experience Access your [dashboard](https://app.sourcery.ai) to: - Enable or disable review features such as the Sourcery-generated pull request summary, the reviewer's guide, and others. - Change the review language. - Add, remove or edit custom review instructions. - Adjust other review settings. #### Getting Help - [Contact our support team](mailto:support@sourcery.ai) for questions or feedback. - Visit our [documentation](https://docs.sourcery.ai) for detailed guides and information. - Keep in touch with the Sourcery team by following us on [X/Twitter](https://x.com/SourceryAI), [LinkedIn](https://www.linkedin.com/company/sourcery-ai/) or [GitHub](https://github.com/sourcery-ai).