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

fix(ui): allow dynamic names in QEditorSlots type #16069

Conversation

yusufkandemir
Copy link
Member

What kind of change does this PR introduce?

  • Bugfix
  • Documentation

Does this PR introduce a breaking change?

  • 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)

Other information:
Resolves #16067. This also documents the dynamic slots more clearly as they will now be listed in the API card.

@github-actions
Copy link

Build Results

JSON API

📜 Changes detected:

diff --git a/./current-build/api/QEditor.json b/./pr-build/api/QEditor.json
index 3db2c60..946fa1f 100644
--- a/./current-build/api/QEditor.json
+++ b/./pr-build/api/QEditor.json
@@ -340,6 +340,11 @@
       "category": "content"
     }
   },
+  "slots": {
+    "[command]": {
+      "desc": "Content for the given command in the toolbar"
+    }
+  },
   "events": {
     "fullscreen": {
       "desc": "Emitted when fullscreen state changes",

Types

📜 Changes detected:

diff --git a/./current-build/types/index.d.ts b/./pr-build/types/index.d.ts
index a62a907..a0217cd 100644
--- a/./current-build/types/index.d.ts
+++ b/./pr-build/types/index.d.ts
@@ -3497,7 +3497,12 @@ export interface QEditorProps {
   onLinkHide?: () => void;
 }
 
-export interface QEditorSlots {}
+export interface QEditorSlots {
+  /**
+   * Content for the given command in the toolbar
+   */
+  [key: `${string}`]: () => VNode[];
+}
 
 export interface QEditor extends ComponentPublicInstance<QEditorProps> {
   /**

@yusufkandemir yusufkandemir merged commit 0302bb3 into quasarframework:dev Jul 13, 2023
1 check passed
@yusufkandemir yusufkandemir deleted the fix-allow-dynamic-names-in-qeditor-slots-type branch July 13, 2023 13:14
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

1 participant