fix: disabled status of action buttons & improve load times of frontend#83
Conversation
🦋 Changeset detectedLatest commit: 2ce189f The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
There was a problem hiding this comment.
Summary of Changes
Hello @Col0ring, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
This pull request focuses on enhancing the user experience by fixing the disabled state of action buttons and significantly improving frontend performance through the lazy loading of the KaTeX math rendering library. It also incorporates a substantial set of dependency updates to keep the project's libraries current and includes various layout and styling refinements for specific UI components, alongside expanded syntax highlighting for code within Markdown.
Highlights
- Fix: Action Button Disabled State: I've addressed an issue in
frontend/pro/chatbot/chatbot-footer.tsxto ensure that action buttons, especially those utilizing Ant Design'sPopconfirmcomponent, correctly reflect their disabled status. This involved refactoring how thedisabledprop is passed and handled. - Performance: Lazy Loading KaTeX: To significantly improve frontend load times, I've implemented lazy loading for the KaTeX math rendering library in
frontend/globals/components/markdown/index.tsx. KaTeX CSS and JavaScript resources are now dynamically imported only when Markdown content containing math syntax is detected, reducing the initial bundle size and speeding up page rendering. A new type declaration infrontend/fixtures.d.tssupports this dynamic import. - Maintenance: Dependency Updates: This PR includes a comprehensive update of various frontend and development dependencies across multiple
package.jsonfiles (e.g.,frontend/package.json,config/lint-config/package.json,package.json). Key updates include Ant Design components, Babel, ESLint, Prettier, Marked, Mermaid, and Vite, ensuring the project leverages more recent and stable versions of these libraries. - UI/UX: Coder Artifacts Layout Improvements: I've made several CSS and component style adjustments in
docs/layout_templates/coder_artifacts/demos/app.pyto resolve layout issues and improve the display of output containers and tabs within the Coder Artifacts demo. This includes better height management and a correction of an element ID. - Feature: Enhanced Markdown Syntax Highlighting: I've expanded the syntax highlighting capabilities of the Markdown component by adding support for JSX, TypeScript, and TSX code blocks in
frontend/globals/components/markdown/utils.ts, providing better code readability. - Backend: Gradio Event Listener: A
scrollevent listener has been added to theAntdXBubbleListcomponent inbackend/modelscope_studio/components/antdx/bubble/list/__init__.py, potentially laying groundwork for new scroll-related interactive features.
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments or fill out our survey to provide feedback.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
No description provided.