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

docs: write "what is autocomplete" #392

Closed
wants to merge 659 commits into from

Conversation

Meschreiber
Copy link
Contributor

This PR writes the first introduction page, "What is autocomplete".

It describes:

  1. what an autocomplete experience is, in general,
  2. what this library does and doesn't provide.

I feel like the second part is still a bit weak and could use some more technical details, so please suggest any you see missing. Thanks!

francoischalifour and others added 30 commits September 17, 2020 15:00
* feat: add recent-searches plugin

* WIP

* fix rollup error (peerDeps)

* chore: exclude website from codesandbox ci builds

* expose getRecentSearches

* add getSources back

* build only esm for codesandbox ci

* add getSuggestions

* remove peerDependency

* renames

* rename methods

* resolve getSources from plugins too

* call onSubmit and onSelect for plugins

* update ci

* Apply suggestions from code review

Co-authored-by: François Chalifour <[email protected]>

* add key to distinguish multiple stores of recent searches

* early return

* named export

* apply feedbacks

* wrap plugin specific methods with data

* run onSubmit for plugins at getDefaultProps

* Update packages/autocomplete-plugin-recent-searches/src/createRecentSearchesPlugin.ts

Co-authored-by: François Chalifour <[email protected]>

* add TData to plugins

* forward onSelect plugin calls in getDefaultProps

* Update packages/autocomplete-core/src/getDefaultProps.ts

Co-authored-by: François Chalifour <[email protected]>

* rename payload to params

* add to store only when data exists

* use query as a fallback for queryID

* get input value from source

* fix type errors

Co-authored-by: François Chalifour <[email protected]>
* feat(recentSearches): add remove button

* pass refresh to getSources

* update styles

* rename delete to remove and add title

* remove return null

* extract icon

* update styles

* bump the version

* remove unecessary typing

* wrap with a sub-container

* export style
* test(js): use local version in assertion

I think I needed this before lerna ran, but in either case, I think it makes more sense to assert the lcoal version is used than the one from @algolia/autocomplete-core

* fix lint
* chore(ts): add MaybePromise wrapper to make APIs shorter to read

* Update packages/autocomplete-js/src/types/index.ts
francoischalifour and others added 27 commits December 10, 2020 12:14
This introduces a brand new Autocomplete experience on touch devices (mobiles, tablets, etc.). This new experience is available via a media query so that it matches when it's triggered given your website requirements.
Line 102 - removed the block wrapper to fix an "Unexpected block statement surrounding arrow body; move the returned value immediately after the `=>`" error.
Line 102 - removed reference to index to fix the "'index' is already declared in the upper scope" and "'index' is defined but never used" errors.
* Fix special char escaping for highlighted recent searches
…m InstantSearch.js (#388)

* Implement sibling strategy from InstantSearch.js

* Increase bundle size

* Rename `getHighlightFromSiblings` to `isPartHighlighted`
This can error if users return `undefined` instead of an empty string.
@codesandbox-ci
Copy link

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 27c8fdf:

Sandbox Source
@algolia/js-example Configuration
@algolia/react-renderer-example Configuration

@Meschreiber
Copy link
Contributor Author

Oops, this was a duplicate of #393.

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.

5 participants