summaryrefslogtreecommitdiff
path: root/ext/bg/js/search-query-parser.js
Commit message (Collapse)AuthorAge
* Frontend initialization refactor (#610)toasted-nutbread2020-06-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Create member functions for ignoreElements and ignorePoint * Create addFullscreenChangeEventListener utility * Move popup creation management into Frontend * Move getUrl implementation * Remove old setup * Remove try/catch block * Error wrap * Add prepare call to TextScanner * Update depth when popup changes * Refactor how Frontend gets PopupFactory and frameId * Update popup preview to work * Update popup preview frame to use the frontend's popup * Update how nested popups are set up * Error wrap * Update how popups are set up on the search page * Error wrap * Error unwrap * Add missing prepare * Remove use of frontendInitializationData * Catch and log errors
* Use DOMTextScanner (#536)toasted-nutbread2020-06-21
| | | | | | | | | | | | | | | | | * Use DOMTextScanner instead of TextSourceRange.seek* * Move getNodesInRange to dom.js * Move anyNodeMatchesSelector to dom.js * Remove unused functions * Update tests * Add layoutAwareScan option * Use layoutAwareScan for source and sentence scanning * Remove unused IGNORE_TEXT_PATTERN
* API refactor (#532)toasted-nutbread2020-05-24
| | | | | | | | | | | | | * Convert api.js into a class instance * Use new api.* functions * Fix missing binds * Group functions with progress callbacks together * Change style * Fix API override not working
* Text scanner refactor (#517)toasted-nutbread2020-05-08
| | | | | | | | | | | | | | | * Fix return type * Pass search function as a constructor argument * Pass constructor as a details object For consistency with other complex constructors and improved semantics. * Convert _ignorePoints to a single optional function * Organize functions * Rename ignorePoints to ignorePoint
* Query parser refactor (#514)toasted-nutbread2020-05-07
| | | | | | | * Make functions private * Make fields private * Organize
* Remove search query parser inheritance (#509)toasted-nutbread2020-05-06
| | | | | | | | | * Remove getMouseEventListeners override * Use this._options instead of this.options * Make QueryParser use composition instead of inheritance for TextScanner * Remove repeat call to document.querySelector('#query-parser-content')
* Add apiModifySettings (#501)toasted-nutbread2020-05-06
| | | | | | | | | | | | | | | | | * Update getProfile/getProfileFromContext to store this.options in a variable * Add useSchema parameter to options getter functions * Add apiModifySettings * Use apiModifySettings instead of apiOptionsSet * Remove apiOptionsSet * Fix incorrect deleteCount check * Require explicit scope for options * Throw on invalid scope
* Extract textSource text inside TextScanner (#500)siikamiika2020-05-05
| | | | | * extract text inside TextScanner * clone textSource before text extraction
* Remove Frontend inheritance (#486)toasted-nutbread2020-05-02
| | | | | | | | | | | | | | | * Make Frontend use composition instead of inheritance for TextScanner * Use push instead of concat * Update setOptions and setEnabled APIs * Update how onWindowMessage event listener is added/removed * Rename options to _options * Use bind instead of arrow function * Fix selection being cleared due to settings changes
* Frontend refactor (part 1) (#484)toasted-nutbread2020-04-27
| | | | | | | | | | | | | | | | | | | * Remove _getVisualViewportScale * Use super's mouse event listener definitions * Remove redundant override * Remove getTouchEventListeners override * Rename Display.onSearchClear to onEscape * Change onSearchClear to clearSelection and use an event * Update how text is marked for selection and deselection * Replace onError with yomichan.logError * Update setEnabled to refresh all event listeners
* Error logging refactoring (#454)toasted-nutbread2020-04-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Create new logging methods on yomichan object * Use new yomichan.logError instead of global logError * Remove old logError * Handle unhandledrejection events * Add addEventListener stub * Update log function * Update error conversion to support more types * Add log event * Add API log function * Log errors to the backend * Make error/warning logs update the badge * Clear log error indicator on extension button click * Log correct URL on the background page * Fix incorrect error conversion * Remove unhandledrejection handling Firefox doesn't support it properly. * Remove unused argument type from log function * Improve function name * Change console.warn to yomichan.logWarning * Move log forwarding initialization into main scripts
* Merge pull request #456 from siikamiika/parse-text-refactorsiikamiika2020-04-17
|\ | | | | Parse text refactor
| * assume and propagate strings for text parsingsiikamiika2020-04-13
| |
| * move QueryParser.parseText to Backendsiikamiika2020-04-13
| |
* | fix ignoreElements in QueryParsersiikamiika2020-04-11
|/
* Update license author field to broader to explicitly reflect thatAlex Yatskov2020-04-10
| | | | | Yomichan is an ongoing community project. It really does take a village, and everyone who contributes code owns a part of it :)
* remove stubssiikamiika2020-03-21
|
* use dependency injection in QueryParsersiikamiika2020-03-21
| | | | | Also fix an issue with settings update triggering a lookup on unprepared QueryParser.
* apply all options on profile changesiikamiika2020-03-21
|
* Update global declarationstoasted-nutbread2020-03-10
|
* fix options object locationsiikamiika2020-03-07
|
* use docSentenceExtract in QueryParsersiikamiika2020-03-07
|
* Changed type returned by apiTextParseMecab to avoid using for intoasted-nutbread2020-02-25
|
* Don't use innerHTMLtoasted-nutbread2020-02-23
|
* Simplify ternarytoasted-nutbread2020-02-22
|
* Remove unusedtoasted-nutbread2020-02-11
|
* Define more globalstoasted-nutbread2020-02-11
|
* Change no-undef from off to errortoasted-nutbread2020-02-11
|
* fix async issuessiikamiika2020-02-10
|
* query parser html templatessiikamiika2020-02-10
|
* query parser: add toggle for term spacingsiikamiika2020-01-25
|
* use TextScanner in QueryParsersiikamiika2020-01-16
|
* Update license info URLtoasted-nutbread2020-01-01
|
* Update copyrighttoasted-nutbread2020-01-01
|
* Use string.split instead of Array.fromtoasted-nutbread2019-12-08
|
* Use substring instead of slicetoasted-nutbread2019-12-08
|
* fix query parsersiikamiika2019-12-05
|
* fix clicking on query parsersiikamiika2019-11-28
|
* Update arrow-parens to alwaystoasted-nutbread2019-11-26
|
* Remove trailing commastoasted-nutbread2019-11-26
|
* Use const rather than let where possibletoasted-nutbread2019-11-26
|
* Move additional utility functions to DOMtoasted-nutbread2019-11-26
|
* refactor selected parser refreshingsiikamiika2019-11-23
|
* remove asyncsiikamiika2019-11-23
|
* store local copy of selected parsersiikamiika2019-11-23
| | | | Options don't update early enough even after awaiting
* add parser selectionsiikamiika2019-11-23
|
* explicit checks in while and ifsiikamiika2019-11-23
|
* promise improvementssiikamiika2019-11-23
|
* use constsiikamiika2019-11-23
|
* remove dead codesiikamiika2019-11-23
|