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

feat(QDrawer): add prop to disable mini animation #15670

Merged

Conversation

Evertvdw
Copy link
Contributor

@Evertvdw Evertvdw commented Apr 3, 2023

Currently the QDrawer animates when switching from mini mode to non mini mode. This behaviour is not (reasonably simple) tweakable using css. This PR makes it possible to disable this animation.

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:

@github-actions
Copy link

github-actions bot commented Apr 3, 2023

Build Results

JSON API

📜 Changes detected:

diff --git a/./current-build/api/QDrawer.json b/./pr-build/api/QDrawer.json
index 70ef03d..e017f55 100644
--- a/./current-build/api/QDrawer.json
+++ b/./pr-build/api/QDrawer.json
@@ -117,6 +117,12 @@
       "type": "Boolean",
       "desc": "Disables the default behavior where drawer backdrop can be swiped",
       "category": "behavior"
+    },
+    "disable-mini-animation": {
+      "type": "Boolean",
+      "desc": "Disables animation of the drawer when toggling mini mode",
+      "category": "behavior",
+      "addedIn": "v2.11.11"
     }
   },
   "slots": {

Types

📜 Changes detected:

diff --git a/./current-build/types/index.d.ts b/./pr-build/types/index.d.ts
index 3a5a2d9..f6305e7 100644
--- a/./current-build/types/index.d.ts
+++ b/./pr-build/types/index.d.ts
@@ -3258,6 +3258,10 @@ export interface QDrawerProps {
    * Disables the default behavior where drawer backdrop can be swiped
    */
   noSwipeBackdrop?: boolean | undefined;
+  /**
+   * Disables animation of the drawer when toggling mini mode
+   */
+  disableMiniAnimation?: boolean | undefined;
   /**
    * Emitted when showing/hidden state changes; Is also used by v-model
    * @param value New state (showing/hidden)

@rstoenescu rstoenescu merged commit 0858ff5 into quasarframework:dev Apr 27, 2023
2 of 4 checks passed
@rstoenescu
Copy link
Member

Thanks for contributing!
Will rename to "no-mini-animation" to match the other props.

rstoenescu pushed a commit that referenced this pull request Apr 27, 2023
Co-authored-by: Evert van der Weit <evert@mett.nl>
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

3 participants