Skip to content
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

Add keep-color prop to QTree #15732

Open
wants to merge 2 commits into
base: dev
Choose a base branch
from
Open

Add keep-color prop to QTree #15732

wants to merge 2 commits into from

Conversation

duffyg
Copy link

@duffyg duffyg commented Apr 19, 2023

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Documentation
  • Code style update
  • Refactor
  • Build-related changes
  • Other, please describe:

Does this PR introduce a breaking change?

  • Yes
  • No

The PR fulfills these requirements:

  • It's submitted to the dev branch (or v[X] branch)
  • When resolving a specific issue, it's referenced in the PR's title (e.g. fix: #xxx[,#xxx], where "xxx" is the issue number)
  • It's been tested on a Cordova (iOS, Android) app
  • It's been tested on an Electron app
  • Any necessary documentation has been added or updated in the docs or explained in the PR's description.

If adding a new feature, the PR's description includes:

  • A convincing reason for adding this feature (to avoid wasting your time, it's best to start a new feature discussion first and wait for approval before working on it)

Other information:
The checkboxes in the QTree component do not keep color when using the default color. See here: https://quasar.dev/vue-components/tree#example--syncing-node-properties (the "Pleasing decor" leaf is unticked and has a grey color)

However, when selecting a different color using the control-color prop, then keep-color is automatically applied.

This is inconsistent. Also, users may wish to switch off the keep-color prop the same way they can for the QCheckbox component.

This PR adds a new keep-color Boolean prop to Qtree, defaulting to true to avoid affecting existing QTree instances. This new prop is applied to the keep-color prop of all checkboxes in the QTree.

ui/src/components/tree/QTree.js Outdated Show resolved Hide resolved
Co-authored-by: Nurlan Suyundukov <14142638+suyundukov@users.noreply.github.com>
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.

None yet

2 participants