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

initial code to add the search functionnality onto the a small viewport #6966

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

Conversation

Kampouse
Copy link
Contributor

What is it?

  • Feature / enhancement
  • Bug
  • Docs / tests / types / typos
  • Infra

Description

I was able to achieve decent behavior by utilizing the QwikUI modal component. The current implementation resulted in the component being partially hidden (off-screen) above pictue. Additionally, the implementation is missing a proper search button icon
I'm sharing this here to gather feedback on my progress so far.
image

Related issue: #6949

Please feel free to review and provide any suggestions or improvements.

Checklist:

  • My code follows the developer guidelines of this project
  • I have performed a self-review of my own code
  • I have ran pnpm change and documented my changes
  • I have made corresponding changes to the Qwik docs
  • Added new tests to cover the fix / functionality

Copy link

changeset-bot bot commented Oct 11, 2024

⚠️ No Changeset found

Latest commit: c109ea1

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link
Contributor

github-actions bot commented Oct 11, 2024

built with Refined Cloudflare Pages Action

⚡ Cloudflare Pages Deployment

Name Status Preview Last Commit
qwik-docs ✅ Ready (View Log) Visit Preview c109ea1

@maiieul maiieul marked this pull request as ready for review October 11, 2024 07:13
@maiieul maiieul requested a review from a team as a code owner October 11, 2024 07:13
@maiieul maiieul marked this pull request as draft October 11, 2024 08:02
Copy link
Member

@wmertens wmertens left a comment

Choose a reason for hiding this comment

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

Nice start. Can't you reuse the search icon from the desktop view?

packages/docs/src/components/docsearch/doc-search.tsx Outdated Show resolved Hide resolved
Search
</Modal.Trigger>
<Modal.Panel class="w-full h-full">
{state.isOpen && (
Copy link
Member

Choose a reason for hiding this comment

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

Actually if you feel up to it, it would be cool to change the docsearchmodal so it uses sync$ instead of all those noSerialize things and then the search box will be instantly available

Copy link
Contributor Author

Choose a reason for hiding this comment

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

the noSerialize scope over some variables (state) and from what I read that a no good? i am missing something 👀

@Kampouse
Copy link
Contributor Author

Added the icon back and made it possible to control the Modal from An external controller
The Current search button that is internal to the Component. The normal behaviour to closing and opening work fine the internal controller had some extra wiring that unsure what is for but the base behaviour work

@Kampouse Kampouse marked this pull request as ready for review October 12, 2024 00:14
@Kampouse Kampouse requested a review from a team as a code owner October 12, 2024 00: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.

2 participants