8000 Gd 564 implement player info panel move to up by Bryukh · Pull Request #7952 · codecombat/codecombat · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Gd 564 implement player info panel move to up #7952

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

Bryukh
Copy link
Collaborator
@Bryukh Bryukh commented Mar 29, 2025

Summary by CodeRabbit

  • New Features

    • Enhanced campaign interactivity with new controls for AI League promotions and portal campaign selections.
    • Introduced a tailored Catalyst experience with dynamic campaign displays and improved user grouping.
  • Style

    • Updated anonymous player text for clarity.
    • Added scalable star icon visuals for achievements.
    • Refined campaign view layout, tooltips, and responsive design for a more cohesive interface.

Bryukh added 5 commits March 28, 2025 11:22
- Adjusted z-index values in the SASS file to ensure proper stacking order of elements in the campaign view.
- Standardized z-index values for buttons and overlays, enhancing visual hierarchy and user interaction clarity.
- Introduced a new user status section in the Pug template for Catalyst users, enhancing visibility of player information.
- Updated SASS styles to style the user status elements, including player level, gems, and hero icons, improving overall aesthetics.
- Ensured conditional rendering of user status based on user type, maintaining clarity for both Catalyst and non-Catalyst users.
- Simplified the display of anonymous player names in the Pug template for Catalyst users, enhancing clarity.
- Added new SASS styles for star icons and language buttons, improving visual consistency and user interaction.
- Adjusted margins and padding in the campaign view styles to enhance layout and responsiveness.
- Introduced a new utility controls section in the Pug template, enhancing the layout for volume and language selection buttons.
- Added SASS styles for utility controls, including button hover and active states, improving user interaction feedback.
- Removed deprecated button elements to streamline the template and improve clarity.
- Changed margin-top to a fixed value of 50px and set margin-bottom to -60px for better spacing in the campaign view.
- Adjusted margin-top for the campaign element to -30px, enhancing the overall layout and visual consistency.
Copy link
Contributor
coderabbitai bot commented Mar 29, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

This pull request updates several parts of the application. In the localization file, it shortens the anonymous player's name. The experiment logic in the user model has been refined to distinguish Catalyst experiment activation. Multiple SASS files have been enhanced with new classes, variables, and layout improvements for campaign and achievement features. The Pug template and CampaignView controller now include new structures and event handling to support a Catalyst view with specialized interactions and display logic.

Changes

File(s) Change Summary
app/locale/en.js Changed the anonymous property in the play section from "Anonymous Player" to "Anonymous".
app/models/User.js Updated Catalyst experiment logic: now explicitly checks for the beta probability and assigns the user to "control" (if not defined) or "beta" group accordingly.
app/styles/common/common.sass Added a new .star class for achievement icons with a transparent 8000 background image and four modifier classes (.star-20, .star-30, .star-40, .star-50) for different sizes.
app/styles/play/campaign-view.sass Introduced new layout variables (e.g., $campaignPortalWidth, $campaignHoverScale), modified .game-controls, and added several Catalyst-specific classes (.game-controls-catalyst, .other-products-catalyst, .user-status-catalyst, .portal-catalyst) and a tooltip class for UI enhancements.
app/templates/play/campaign-view.pug Added a conditional block for the Catalyst view that renders a new structure including .portal-catalyst, campaign rows for specific campaign slugs, and tailored game controls and user status sections.
app/views/play/CampaignView.js Added new event listeners (e.g., onAILeagueIconClick) and updated click/mouse event handlers to accommodate Catalyst campaigns. Also, introduced an isCatalyst flag in the constructor to alter control flow for user interactions.

Sequence Diagram(s)

sequenceDiagram
  participant U as User
  participant CV as CampaignView
  participant M as Modal

  U->>CV: Click on AI League icon
  CV->>CV: Trigger onAILeagueIconClick
  CV->>M: Open AI League modal
  M-->>CV: Confirm modal open

  U->>CV: Click on Portal Campaign element
  CV->>CV: Invoke onClickPortalCampaign
  CV->>CV: Check isCatalyst flag
  alt Catalyst Experiment
    CV->>CV: Process Catalyst-specific campaign logic
  else Standard Flow
    CV->>CV: Execute standard portal campaign handling
  end
Loading

Possibly related PRs

Suggested reviewers

  • adamkecskes
  • smallst

Poem

In a meadow of code so green,
A rabbit hops, delighted and keen.
Changes bloom in JS and SASS,
With Catalyst views, the code shall pass.
Hop along, dear devs, with joy and cheer!
🐇✨

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ast-grep (0.31.1)
app/locale/en.js

📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 68007cd and e98243c.

⛔ Files ignored due to path filters (3)
  • app/assets/images/pages/hackstack/Code-Combat-AI-Hack-Stack-Full-Colour-Small.png is excluded by !**/*.png
  • app/assets/images/pages/league/Code-Combat-AI-League-Small.png is excluded by !**/*.png
  • app/assets/images/pages/roblox/Code-Combat-Worlds-Small.png is excluded by !**/*.png
📒 Files selected for processing (6)
  • app/locale/en.js (1 hunks)
  • app/models/User.js (1 hunks)
  • app/styles/common/common.sass (1 hunks)
  • app/styles/play/campaign-view.sass (12 hunks)
  • app/templates/play/campaign-view.pug (2 hunks)
  • app/views/play/CampaignView.js (8 hunks)
✨ Finishing Touches
  • 📝 Generate Docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai plan to trigger planning for file edits and PR creation.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@Bryukh Bryukh changed the base branch from master to vertical-global-map March 29, 2025 10:17
@Bryukh Bryukh merged commit 6ba020f into vertical-global-map Mar 29, 2025
2 of 3 checks passed
@Bryukh Bryukh deleted the gd-564-implement-player-info-panel-move-to-up branch March 29, 2025 10:17
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.

1 participant
0