Skip to content

Add layout option and style #146

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

Merged
merged 2 commits into from
Jun 2, 2021
Merged

Conversation

mdubus
Copy link
Member

@mdubus mdubus commented Jun 1, 2021

What's wrong ?

Problem 1:

docs-searchbar provides an option to choose between 2 layouts : "simple" and "columns".
But the plugin vuepress-plugin-meilisearch doesn't provide access to this existing option.

Problem 2:

After making this option available, the design looks horrific:
before simple layout

What's inside this PR

This PR makes the layout option available.
It also adapts the style to match the existing one in docs-searchbar.

Style in docs-searchbar (simple layout):
reference docs searchbar

Style in vuepress-plugin-meilisearch after this PR (simple layout):
after simple layout

How to test

Go to the file playground/.vuepress/config.js and add "layout": "simple" in the options:
Capture d’écran 2021-06-01 à 16 55 06

Note that you might need to restart your server.

Please make sure to test that it doesn't break the "columns" layout 🙏

Copy link
Member

@curquiza curquiza left a comment

Choose a reason for hiding this comment

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

LGTM except for one small change :)

@curquiza curquiza requested a review from bidoubiwa June 1, 2021 16:27
Co-authored-by: Clémentine Urquizar <[email protected]>
@bidoubiwa
Copy link
Contributor

bors merge

bors bot added a commit that referenced this pull request Jun 2, 2021
146: Add layout option and style r=bidoubiwa a=mdubus

## What's wrong ?

**Problem 1:** 

[docs-searchbar](https://github.com/meilisearch/docs-searchbar.js) provides an option to choose between 2 layouts : "simple" and "columns".
But the plugin `vuepress-plugin-meilisearch` doesn't provide access to this existing option.

**Problem 2:** 

After making this option available, the design looks horrific: 
![before simple layout](https://user-images.githubusercontent.com/30866152/120343835-54c87280-c2f9-11eb-8cb8-0748c3c1c4ff.png)


## What's inside this PR

This PR makes the `layout` option available.
It also adapts the style to match the existing one in docs-searchbar.

Style in `docs-searchbar` (simple layout): 
![reference docs searchbar](https://user-images.githubusercontent.com/30866152/120344347-caccd980-c2f9-11eb-8412-4837569338f7.png)


Style in `vuepress-plugin-meilisearch` after this PR (simple layout): 
![after simple layout](https://user-images.githubusercontent.com/30866152/120345811-1af86b80-c2fb-11eb-8119-c12529a2248f.png)



## How to test

Go to the file `playground/.vuepress/config.js` and add `"layout": "simple"` in the options:
![Capture d’écran 2021-06-01 à 16 55 06](https://user-images.githubusercontent.com/30866152/120344750-28f9bc80-c2fa-11eb-9d65-7b1e8c8ff62c.png)

Note that you might need to restart your server.

Please make sure to test that it doesn't break the "columns" layout 🙏


Co-authored-by: Morgane Dubus <[email protected]>
Co-authored-by: Morgane Dubus <[email protected]>
@bidoubiwa
Copy link
Contributor

bors merge

bors bot added a commit that referenced this pull request Jun 2, 2021
146: Add layout option and style r=bidoubiwa a=mdubus

## What's wrong ?

**Problem 1:** 

[docs-searchbar](https://github.com/meilisearch/docs-searchbar.js) provides an option to choose between 2 layouts : "simple" and "columns".
But the plugin `vuepress-plugin-meilisearch` doesn't provide access to this existing option.

**Problem 2:** 

After making this option available, the design looks horrific: 
![before simple layout](https://user-images.githubusercontent.com/30866152/120343835-54c87280-c2f9-11eb-8cb8-0748c3c1c4ff.png)


## What's inside this PR

This PR makes the `layout` option available.
It also adapts the style to match the existing one in docs-searchbar.

Style in `docs-searchbar` (simple layout): 
![reference docs searchbar](https://user-images.githubusercontent.com/30866152/120344347-caccd980-c2f9-11eb-8412-4837569338f7.png)


Style in `vuepress-plugin-meilisearch` after this PR (simple layout): 
![after simple layout](https://user-images.githubusercontent.com/30866152/120345811-1af86b80-c2fb-11eb-8119-c12529a2248f.png)



## How to test

Go to the file `playground/.vuepress/config.js` and add `"layout": "simple"` in the options:
![Capture d’écran 2021-06-01 à 16 55 06](https://user-images.githubusercontent.com/30866152/120344750-28f9bc80-c2fa-11eb-9d65-7b1e8c8ff62c.png)

Note that you might need to restart your server.

Please make sure to test that it doesn't break the "columns" layout 🙏


Co-authored-by: Morgane Dubus <[email protected]>
Co-authored-by: Morgane Dubus <[email protected]>
@bidoubiwa bidoubiwa requested a review from curquiza June 2, 2021 12:38
@bidoubiwa
Copy link
Contributor

bors merge

@bors
Copy link
Contributor

bors bot commented Jun 2, 2021

Build succeeded:

@bors bors bot merged commit a94bde1 into meilisearch:main Jun 2, 2021
@mdubus mdubus deleted the add_layout_option branch June 2, 2021 13:38
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.

3 participants