Automattic / Automattic/jetpack

Jetpack Search: Add option to make search box position "fixed"

Open
#18,638 0 comments 0 reactions 0 assignees View on GitHub
[Feature] Search New Feature
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

#### Is your feature request related to a problem? Please describe.

Jetpack search is a paid feature, and users paying for it will often want to make this search box more prominent. Some of the newer themes (Seedlet and Varia, among others) do not have a sidebar widget area, which will prevent us from adding the search box in a sufficiently prominent place.

#### Describe the solution you'd like

I would propose adding a checkbox to add `position:fixed` to the search widget. This would increase the visibility of the searchbox. The [Cookies & Consents Banner](https://en.support.wordpress.com/cookie-widget/) widget already shows this way.

#### Describe alternatives you've considered

Making a widget sticky might not always work 100% out of the box on any give themes, so we might want to offer a few additional options such as:

- Stick to top or bottom
- Deactivate on mobile
- Set a custom z-index vaule

#### Additional context

Here is a mockup of what it could look like on mobile:

![Kapture 2021-01-31 at 22 11 54](https://user-images.githubusercontent.com/4452464/106398130-5ea49c80-6411-11eb-9a2c-ceab43486ece.gif)

And here is what the feature could look like, on its minimalistic approach.

![Screen Shot on 2021-01-31 at 22:01:14](https://user-images.githubusercontent.com/4452464/106398011-ba225a80-6410-11eb-9d51-ef130dbd3420.png)

Contributor guide

Open the contributing guide

Research direction

The issue names Jetpack Search's search widget and points to the Cookies & Consents Banner widget as a comparison; begin by locating those widget implementations. Confirm the intended scope for fixed positioning, including the proposed top/bottom, mobile, and z-index options. Done means the selected positioning behavior works as shown in the supplied mockups.

Written by the indexing model from the issue text.

Assessment

Tech stack
php, wordpress
Domain
frontend, search
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.