Skip to content

docs(components): [notification] correct type count and include primary - #24878

Merged
rzzf merged 2 commits into
element-plus:devfrom
ixyzorg:doc/notification
Sep 18, 2026
Merged

rzzf merged 2 commits into
element-plus:devfrom
ixyzorg:doc/notification

Conversation

@ixyzorg

@ixyzorg ixyzorg commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

Please make sure these boxes are checked before submitting your PR, thank you!

  • Make sure you follow contributing guide English | (中文 | Español | Français).
  • Make sure you are merging your commits to dev branch.
  • Add some descriptions and refer to relative issues for your PR.

DESC
update doc

Summary by CodeRabbit

  • Documentation
    • Updated Notification documentation to accurately list all five available notification types: primary, success, warning, info, and error.
    • Updated the notification type example to demonstrate the info and error convenience methods.

@github-actions

github-actions Bot commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

@coderabbitai

coderabbitai Bot commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: b952845c-643e-46d0-b8c3-2824f006e252

📥 Commits

Reviewing files that changed from the base of the PR and between a0470b5 and b6546ab.

📒 Files selected for processing (1)
  • docs/examples/notification/different-types.vue

Included review availability: Your plan provides up to 10 included reviews per hour; 8 remain after this review.


📝 Walkthrough

Walkthrough

The Notification documentation now lists five types. The notification example uses typed convenience methods for info and error.

Changes

Notification type documentation and example

Layer / File(s) Summary
Update notification types and examples
docs/en-US/component/notification.md, docs/examples/notification/different-types.vue
The documentation adds primary to the type list. The example uses ElNotification.info and ElNotification.error for the corresponding handlers.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~2 minutes

Change: Other

Merge Risk: ⚪ Minimal · up to b6546

The documentation updates align with the supported Notification API and introduce no identified production risk.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the Notification documentation changes: correcting the type count and including the primary type.
Description check ✅ Passed The description includes the required checklist and identifies the documentation update. It does not provide a detailed description or a related issue reference, but the description is still on topic …
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Warning

Some tools did not complete. Review the errors below.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

docs/examples/notification/different-types.vue

Oops! Something went wrong! :(

ESLint: 10.10.0

TypeError [ERR_IMPORT_ATTRIBUTE_MISSING]: Module "file:///docs/examples/.eslintrc.json?mtime=1789638748417" needs an import attribute of "type: json"
at validateAttributes (node:internal/modules/esm/assert:88:15)
at defaultLoadSync (node:internal/modules/esm/load:164:3)
at #loadAndMaybeBlockOnLoaderThread (node:internal/modules/esm/loader:776:12)
at #loadSync (node:internal/modules/esm/loader:796:49)
at ModuleLoader.load (node:internal/modules/esm/loader:762:26)
at ModuleLoader.loadAndTranslate (node:internal/modules/esm/loader:504:31)
at #getOrCreateModuleJobAfterResolve (node:internal/modules/esm/loader:555:36)
at afterResolve (node:internal/modules/esm/loader:603:52)
at ModuleLoader.getOrCreateModuleJob (node:internal/modules/esm/loader:609:12)
at node:internal/modules/esm/loader:628:32


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

Comment @coderabbitai help to get the list of available commands.

@pkg-pr-new

pkg-pr-new Bot commented Sep 17, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

pnpm add https://pkg.pr.new/element-plus@24878
npm i https://pkg.pr.new/element-plus@24878
yarn add https://pkg.pr.new/element-plus@24878.tgz

commit: b6546ab

@github-actions

Copy link
Copy Markdown
Contributor

Size Change: 0 B

Total Size: 1.46 MB

ℹ️ View Unchanged
Filename Size
dist/element-plus/dist/index.css 47.7 kB
dist/element-plus/dist/index.full.js 420 kB
dist/element-plus/dist/index.full.min.js 293 kB
dist/element-plus/dist/index.full.min.mjs 286 kB
dist/element-plus/dist/index.full.mjs 410 kB

compressed-size-action

@github-actions

github-actions Bot commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

🧪 Playground Preview: https://element-plus.run/?pr=24878
Please comment the example via this playground if needed.

🔖 Commit: b6546ab

@patienry patienry left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thank you!

@rzzf
rzzf merged commit d9606e8 into element-plus:dev Sep 18, 2026
17 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

@ixyzorg Thanks for your contribution! ❤️

@ixyzorg
ixyzorg deleted the doc/notification branch September 18, 2026 09:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants