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: add directives page #740

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

userquin
Copy link
Member

@userquin userquin commented Sep 27, 2024

πŸ”— Linked issue

❓ Type of change

  • πŸ“– Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality)
  • ✨ New feature (a non-breaking change that adds functionality)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

Check the title: nuxt/nuxt#29203

This PR includes:

  • filter out directive imports in imports.vue page: Nuxt will use import.ts module to auto import and generate the dts
  • filter directive imports in directives.vue page
  • updated NSectionBlock.vue to allow add the directives when there are no directives (added expandable prop and the logic for mouse and expand icon)
  • add directives.md to the docs: will require a review

This PR can be merged, we only need to confirm that Nuxt will use the import.ts module, otherwise we will need to redo some logic here.

Some screenshots

GYg7Tc1WgAA1e5s
toolbar_

GYg7e2JXQAAugEt
directives page

@antfu
Copy link
Member

antfu commented Sep 28, 2024

Can we have it in the imports tab (as a badge or filter) instead? Would that be easier to maintain?

@userquin
Copy link
Member Author

Something like this?

imagen

@userquin
Copy link
Member Author

userquin commented Sep 28, 2024

We need to:

  • make new filter responsive
  • change User composables to User directives and the icon when directives filter is checked.
  • use v-<kebab-case> in copy button
  • review used/unused directives: looks like we need to change how we collect the info for the directives (right now directives always shown as not-used): found the problem, we're using 2 different unimport context in Nuxt (I'm going to check required changes in Nuxt PR)

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.

2 participants