mirror of
https://github.com/sourcegraph/sourcegraph.git
synced 2026-02-06 20:31:48 +00:00
This adds snippets back to the search sidebar, which got missed when it was redesigned. This includes some refactoring of the Svelte version to account for filter types that do not match 1:1 with the backend types. We initially tried to tie them tightly with the backend types so the backend is the source of truth, but I think we want to have the ability to introduce client-side-only filters, which we already sorta hackily do with the `type:` filters. And it's even more hacky with the `count:` filter in the React webapp (which doesn't look like it was ever implemented in the Svelte version). In the React app, I made the minimum changes to get this working (no associated refactoring). |
||
|---|---|---|
| .. | ||
| dev | ||
| src | ||
| .bazelignore | ||
| .eslintignore | ||
| .stylelintrc.json | ||
| BUILD.bazel | ||
| NOTICE | ||
| package.json | ||
| README.md | ||
| tsconfig.json | ||
| vitest.config.ts | ||
Shared
This folder contains common TypeScript/React/SCSS client code shared between the browser extension and the web app.
Everything in this folder is code-host agnostic and cannot make assumptions about whether it is running inside the Sourcegraph web app, in the browser extension on GitHub, Gitlab, Phabricator, Bitbucket Server, etc. In particular, components cannot make use of global CSS classes but must accept CSS classes as props and/or have their own code host agnostic SCSS stylesheets. For more details, see Styling UI in the handbook.
Code that is only used in branded contexts (web app, options menu of the browser extension, ...) should go into ../branded instead.