Skip to content

Conversation

leo91000
Copy link
Contributor

@leo91000 leo91000 commented May 20, 2025

Summary

  • Added a toggle button in the editor panel to enable toggling the select dropdown's state during editing
  • Removed the 'Force open in editor' option as it's no longer needed with the toggle button
  • Made the required config changes to support the new toggle functionality

@leo91000 leo91000 force-pushed the feature/WW-3773-add-toggle-button branch from 5c5e7f5 to b42207e Compare May 20, 2025 18:15
@leo91000 leo91000 changed the base branch from main to WW-3574-ai-md May 20, 2025 18:15
@leo91000 leo91000 force-pushed the feature/WW-3773-add-toggle-button branch 6 times, most recently from 5685edd to 57e4bc4 Compare May 21, 2025 10:52
@leo91000 leo91000 force-pushed the feature/WW-3773-add-toggle-button branch from 57e4bc4 to affa35c Compare May 21, 2025 10:53
@leo91000 leo91000 requested a review from Copilot May 21, 2025 12:00
Copy link
Contributor

@Copilot 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

This PR introduces a new toggle button functionality in the editor panel by replacing the deprecated “Force open in editor” option with a toggle mechanism.

  • Replaces 'forceOpenInEditor' with 'toggleSelect' in configuration
  • Refactors the state management in wwElement_Select.vue from a computed property to a ref
  • Adjusts button actions and labels to support the toggle functionality

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
ww-config.js Updated settings order and property definitions for the new toggle option
src/wwElement_Select.vue Replaced computed property with a ref and added toggle method implementation
Comments suppressed due to low confidence (1)

ww-config.js:238

  • [nitpick] The property 'toggleSelect' is configured with an action 'toggleForceOpenInEditor' and a simple 'Toggle' label, which might be ambiguous. Consider renaming the property or aligning the action name and label to clearly indicate its functionality.
        toggleSelect: {

this.resetLastTriggerComponentAction();
this.resetSearch();
},
toggleForceOpenInEditor() {
Copy link
Preview

Copilot AI May 21, 2025

Choose a reason for hiding this comment

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

Switching from a computed property to a ref for 'forceOpenInEditor' necessitates proper reactive handling. Since refs require using '.value' to update their state, ensure that this ref is correctly integrated (for example, by either returning it via setup or declaring it in data) so that toggling works as intended.

Copilot uses AI. Check for mistakes.

Base automatically changed from WW-3574-ai-md to main May 22, 2025 07:08
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