- 24 Jul, 2017 6 commits
-
-
Robert Knight authored
This was undocumented and untested, and it is very unlikely that anyone actually uses it. It has also fundamentally been broken for a long time in the client because filtering was applied _before_ sorting when building the thread structure, so it was arbitrary (from the user's point of view) which annotations would be kept by a `result` limit.
-
Robert Knight authored
Codecov tells me that we are missing tests for these fields. In the case of the "since" filter, this found an issue where `new Date(<ann.updated value>)` was failing in PhantomJS because value normalization lower-cased the 'T' and 'Z' chars in the ISO date string and this caused parsing to fail. Fix this by making the `value` function return a `Date` object which won't get normalized.
-
Robert Knight authored
A difference between the existing test cases for the viewFilter service and the actual inputs that are created by `searchFilter#generateFacetedFilter` is that the actual input filter object has empty term lists for fields that do not appear in the query. Fix handling of this and add a test.
-
Robert Knight authored
Babel inserts helper code before the first non-comment statement from the original source, breaking the `@ngInject` annotation.
-
Robert Knight authored
Rewrite the view filter service to make it easier to verify and fix a bug in the handling of "any" queries: The input filter object representing the parsed search query is translated into a tree of filter primitives, where each primitive is either a TermFilter that tests whether an annotation matches a single (field, term) or a BinaryOpFilter that combines other filters using AND or OR operators. The list of annotations are then matched against the tree's root filter. This system allows a nicer representation of "any" field queries by expanding a query such as "foo bar" into: (quote:foo OR text:foo OR ...) AND (quote:bar OR text:bar OR ...) In the process a mistake was uncovered in a test case for the "any" filter which incorrectly allowed the previous broken implementation to pass.
-
Robert Knight authored
This is an initial translation of the existing viewFilter code to JS using decaffeinate plus some manual fixups.
-
- 20 Jul, 2017 2 commits
-
-
Robert Knight authored
-
Robert Knight authored
-
- 19 Jul, 2017 2 commits
-
-
Robert Knight authored
Use a URN derived from DC meta tags for creating equivalent doc links
-
Juan Corona authored
“dc.relation.ispartof” is now used instead of “dc.source” The goal of this is to identify a resource that’s part of another resource, therefore the more specific term fits better.
-
- 18 Jul, 2017 1 commit
-
-
Juan Corona authored
Use a URN derived from DublinCore meta tags for creating equivalent links across documents that provide ‘dc:source’ and ‘dc:identifier’ tags This link is now the documentIdentifier for non-PDF cases for the document metadata. This metadata is shared with the sidebar, making this link appear in the list of links for the Search API calls
-
- 17 Jul, 2017 4 commits
-
-
Robert Knight authored
-
Robert Knight authored
-
Robert Knight authored
Adding support for onLayoutChange notifier configuration
-
Robert Knight authored
- Add a doc comment to the _notifyOfLayoutChange function to clarify the purpose of the optional param. - Add a comment inside the function to describe the high-level structure of the sidebar and how expanding/collapsing it is achieved. - Correct a typo with "frameVisbileWidth"
-
- 14 Jul, 2017 9 commits
-
-
Sean Roberts authored
-
Robert Knight authored
-
Robert Knight authored
-
Robert Knight authored
Capture the client url to be used in subframes
-
Robert Knight authored
When the client served by the browser extension injects itself into child iframes on the current page, it needs to include the "assetRoot" config setting in order for the client in the iframes to be loaded from the extension rather than the default CDN URL.
-
Sean Roberts authored
-
Sean Roberts authored
-
Robert Knight authored
-
Robert Knight authored
-
- 13 Jul, 2017 6 commits
-
-
Sean Hammond authored
Persist access and refresh tokens to localStorage.
-
Robert Knight authored
Frame validity checks
-
Sean Roberts authored
-
Robert Knight authored
As noted in PR feedback, the OAuth token key should be based on the annotation service rather than just authority. The annotation service is currently identified by (API domain, authority) but in future we'll likely integrate the authority into the API URL for 3rd-party accounts (eg. "https://publisher.hypothes.is/api").
-
Robert Knight authored
Rename for consistency with `saveToken`.
-
Sean Hammond authored
Convert search query parser to JS and add tests
-
- 12 Jul, 2017 2 commits
-
-
Robert Knight authored
Removing flags for multiple iframe support
-
Sean Roberts authored
-
- 11 Jul, 2017 8 commits
-
-
Robert Knight authored
For code in newly created JS files, arrow functions should be favored.
-
Robert Knight authored
In the process fix an inconsistency where the "since" term was returned as a number for hours, days, weeks, months and years but as a string for seconds.
-
Robert Knight authored
-
Robert Knight authored
Convert the SearchFilter class to JS using decaffeinate and convert methods which do not depend on any external state, which is all of them, into plain functions.
-
Robert Knight authored
Persist access and refresh tokens to localStorage, under the key: hypothesis.oauth.<authority>.token Where `<authority>` is the domain of the annotation service and the structure is the JSON-encoded object: { accessToken: <token>, refreshToken: <token>, expiresAt: <UNIX timestamp in ms> } When an API token is requested for the first time during startup, the existing token for the current authority is loaded from storage, validated locally and then used if possible.
-
Robert Knight authored
We should review whether or not to include this file in the source tree, given that we use Yarn primarily for package management, but since it is here, keep it up to date.
-
Robert Knight authored
-
Robert Knight authored
-