siikamiika
1df59d57b5
limit popup depth live
2020-04-11 21:01:27 +03:00
siikamiika
61a96e327a
prevent injecting frontend multiple times
2020-04-11 21:01:27 +03:00
siikamiika
9adbc80a70
listen to optionsUpdated in popup-nested.js
2020-04-11 21:01:27 +03:00
siikamiika
8c9389e07d
listen to optionsUpdated in search-frontend.js
2020-04-11 21:01:27 +03:00
toasted-nutbread
82f8397000
Merge pull request #438 from toasted-nutbread/display-generator-refactoring
...
Display generator refactoring
2020-04-11 11:37:03 -04:00
toasted-nutbread
a864cf094f
Merge pull request #437 from toasted-nutbread/backend-api-handler-changes
...
Backend api handler changes
2020-04-11 11:32:52 -04:00
toasted-nutbread
a296c758b9
apiBroadcast => apiBroadcastTab
2020-04-10 20:00:18 -04:00
toasted-nutbread
d164fc6f62
Remove unused globals
2020-04-10 18:45:23 -04:00
toasted-nutbread
2c5bf0ed6b
Fix getSelection not working in QueryParser
2020-04-10 17:11:41 -04:00
4e5029f7ec
Update license author field to broader to explicitly reflect that
...
Yomichan is an ongoing community project. It really does take a village,
and everyone who contributes code owns a part of it :)
2020-04-10 11:10:21 -07:00
281023095a
Version bump
2020-04-10 09:36:34 -07:00
toasted-nutbread
0b7791c103
Fix source map for characters collapsed at the start of a string
2020-04-10 12:25:24 -04:00
toasted-nutbread
42a2917bf7
Add support for collapsing emphatic character sequences
2020-04-10 11:56:18 -04:00
toasted-nutbread
025b1f398b
Simplify access to details fields in createTermEntry
2020-04-09 22:40:25 -04:00
toasted-nutbread
06183ec124
Update how termTags is passed to _createTermExpression
2020-04-09 22:40:25 -04:00
toasted-nutbread
bb37b74288
Rename "only" to "disambiguation" to match naming convention used for pitch accents
2020-04-09 22:40:25 -04:00
toasted-nutbread
6788bb31d2
Update _appendMultiple to not use a fallback
2020-04-09 22:40:25 -04:00
toasted-nutbread
f9bdf2c66f
Organize
2020-04-09 22:40:25 -04:00
toasted-nutbread
9bbe35da68
Mark functions as private
2020-04-09 22:40:25 -04:00
toasted-nutbread
d7e4ff067e
Remove statics
2020-04-09 22:40:25 -04:00
toasted-nutbread
75c5c7aabc
Remove data-multi assignments
2020-04-09 22:40:25 -04:00
toasted-nutbread
99f58b49f6
Use data-expression-multi instead of data-multi
2020-04-09 22:40:22 -04:00
toasted-nutbread
c88ec43ad1
Fix yomichanCoreReady waiting for a response
2020-04-07 19:59:10 -04:00
toasted-nutbread
a2b66dc6cc
Rename apiForward to apiBroadcast
2020-04-07 19:51:39 -04:00
toasted-nutbread
96566b8581
Update forward to be synchronous and ignore the reply
2020-04-07 19:49:54 -04:00
toasted-nutbread
038e43d19d
Update some API handlers to be synchronous
2020-04-07 19:47:46 -04:00
toasted-nutbread
82462edce0
Add support for API handlers to be optionally asynchronous
2020-04-07 19:41:02 -04:00
toasted-nutbread
f177e3699a
Merge pull request #434 from toasted-nutbread/error-fixes
...
Error fixes
2020-04-07 19:28:07 -04:00
toasted-nutbread
ac1ecb35ee
Merge pull request #433 from toasted-nutbread/extra-dictionary-information
...
Extra dictionary information
2020-04-07 19:27:58 -04:00
toasted-nutbread
a6773e0240
Fix field name
2020-04-07 19:04:47 -04:00
toasted-nutbread
8a419dfa67
Pass AudioSystem instance to AnkiNoteBuilder constructor
2020-04-07 19:04:47 -04:00
toasted-nutbread
716ab99fc0
Remove inconsistent/unused return value
2020-04-07 19:04:47 -04:00
toasted-nutbread
97b7b521dd
Create _containsMarker to reduce redundant code
2020-04-07 19:04:47 -04:00
toasted-nutbread
a49e061545
Move _dateToString into a new function
2020-04-07 19:04:47 -04:00
toasted-nutbread
efcdff72a3
Move media injection functions into AnkiNoteBuilder
2020-04-07 19:04:47 -04:00
toasted-nutbread
29cf8d2f79
Fix not awaiting this._getNoteContext
2020-04-06 18:55:45 -04:00
toasted-nutbread
696897f6fa
Add support for getting the document title
2020-04-06 18:55:36 -04:00
toasted-nutbread
199b926f23
Add overridable getDocumentTitle
2020-04-06 18:20:04 -04:00
toasted-nutbread
1d7c86ded0
Add document-title tag to settings options
2020-04-06 18:20:04 -04:00
toasted-nutbread
4011a091b6
Add support for {document-title}
2020-04-06 18:20:04 -04:00
toasted-nutbread
059db280bb
Add custom context object for note creation
2020-04-06 18:20:04 -04:00
toasted-nutbread
8b07a23de9
Rename context to details
2020-04-06 18:20:04 -04:00
toasted-nutbread
9dfe531dfd
Use logError instead of console.log
2020-04-05 18:27:53 -04:00
toasted-nutbread
7449ffd4dc
Fix error reporting during dictionary import
2020-04-05 18:26:38 -04:00
toasted-nutbread
dd9d50bfc1
Update settings page to display additional information
2020-04-05 14:46:45 -04:00
toasted-nutbread
1b97629cd8
Store new dictionary data
2020-04-05 14:46:45 -04:00
toasted-nutbread
cd831d88cc
Update schema to include additional fields
2020-04-05 14:46:45 -04:00
siikamiika
22a97d916f
fix NOT (a OR B) to NOT (a AND b)
2020-04-05 20:42:23 +03:00
siikamiika
5596a8f6f7
strict object property type check
2020-04-05 20:03:45 +03:00
siikamiika
aea7c590d1
refactor _updateFrameOffset
2020-04-05 20:03:45 +03:00
siikamiika
abd056e563
reduce code duplication
2020-04-05 20:03:45 +03:00
siikamiika
31a326fe63
add option for iframe popups
2020-04-05 20:03:42 +03:00
siikamiika
0d76cef434
give a name to a timeout
2020-04-05 19:57:37 +03:00
siikamiika
e4fc53480f
move broadcastRootPopupInformation to Frontend
2020-04-05 19:57:37 +03:00
siikamiika
867902523f
simplify promise
2020-04-05 19:57:37 +03:00
siikamiika
123e725049
use duck typing for event listener
2020-04-05 19:57:37 +03:00
siikamiika
067c26982e
setTimeout refactoring
2020-04-05 19:57:37 +03:00
siikamiika
559033f0a6
default to [0, 0] when sourceFrame is not found
2020-04-05 19:57:37 +03:00
siikamiika
c171503d77
use getTemporaryListenerResult in other places
2020-04-05 19:57:37 +03:00
siikamiika
7928c5d713
error handling
2020-04-05 19:57:37 +03:00
siikamiika
9f9ea1d5fb
throttle frame offset getting
2020-04-05 19:57:37 +03:00
siikamiika
fa65ab3512
refactor getTemporaryListenerResult timeout
2020-04-05 19:57:37 +03:00
siikamiika
d88635cbb2
temporary listener abstraction
2020-04-05 19:57:37 +03:00
siikamiika
9fe1e38afb
refactor
2020-04-05 19:57:37 +03:00
siikamiika
d20ece9f07
move frame offset forwarding code to a class
2020-04-05 19:57:37 +03:00
siikamiika
09151a1a86
simplify popup proxy prepare
2020-04-05 19:57:37 +03:00
siikamiika
b996d0b1e0
fix and simplify
2020-04-05 19:57:37 +03:00
siikamiika
4814db8df1
adjust iframe popup position to root page
2020-04-05 19:57:37 +03:00
siikamiika
b6c4914b79
simplify popup prepare
2020-04-05 19:57:37 +03:00
siikamiika
6806e7055f
show iframe popups in root frame
2020-04-05 19:57:37 +03:00
toasted-nutbread
3684a479c5
Merge pull request #424 from toasted-nutbread/dictionary-importer
...
Dictionary importer
2020-04-05 12:52:07 -04:00
toasted-nutbread
058f626efd
Merge pull request #423 from toasted-nutbread/text-source-map
...
Text source map
2020-04-05 12:51:56 -04:00
toasted-nutbread
9052ab8ebd
Move dictionary import functionality into a new class
2020-03-30 20:51:20 -04:00
toasted-nutbread
02f7763f00
Add importDictionary function to Backend
2020-03-30 20:45:36 -04:00
toasted-nutbread
c193a703cc
Move database creation into Backend
2020-03-30 20:39:04 -04:00
toasted-nutbread
8095d9138c
Add isPrepared
2020-03-30 20:28:44 -04:00
toasted-nutbread
1a8bbf32d5
Make dictionaryExists public
2020-03-30 20:28:41 -04:00
toasted-nutbread
a6fedae9c7
Update bulkAdd implementation
2020-03-30 20:19:39 -04:00
toasted-nutbread
938b696468
Hide reading disambiguation if the downstep notation is visible
2020-03-29 11:27:35 -04:00
toasted-nutbread
1f84280ea0
Include readings in disambiguations
2020-03-29 11:27:13 -04:00
toasted-nutbread
a7da4416d7
Change names
2020-03-29 11:19:43 -04:00
toasted-nutbread
ae84d13757
Create simplified source map class
2020-03-28 18:17:00 -04:00
toasted-nutbread
aa2a0c09f4
Update how pitch accent expressions are disambiguated
2020-03-28 14:52:44 -04:00
toasted-nutbread
a339bf69d3
Move set functions into core.js
2020-03-28 14:50:10 -04:00
toasted-nutbread
2c4983da46
Update styles
2020-03-28 12:31:41 -04:00
toasted-nutbread
431473d55c
Fix layering issue
2020-03-28 12:01:55 -04:00
toasted-nutbread
0d80fcdf86
Move Japanese utility functions out of display-generator.js
2020-03-28 10:47:02 -04:00
toasted-nutbread
cbc7e2646d
Add options
2020-03-28 10:25:57 -04:00
toasted-nutbread
803a464fb9
Add support for accent graph
2020-03-28 10:25:57 -04:00
toasted-nutbread
97a520cc15
Add support for displaying pitch accents
2020-03-28 10:25:57 -04:00
toasted-nutbread
2d7214ce60
Add metadata for unique expression count
2020-03-28 10:25:57 -04:00
toasted-nutbread
047efaa3db
Add support for returning pitch data from the database
2020-03-28 10:25:57 -04:00
toasted-nutbread
9e8a22b08a
Add support for different sections for term content
2020-03-28 10:25:57 -04:00
toasted-nutbread
168bd72d0a
Update _appendMultiple to support general iterables
2020-03-28 10:25:57 -04:00
toasted-nutbread
93f7278586
Update dictionary schema to support pitch accent data
2020-03-28 10:25:11 -04:00
toasted-nutbread
a0c4ce779d
Merge pull request #413 from toasted-nutbread/japanese-utility
...
Convert Japanese utilities to a module-like style
2020-03-27 22:53:45 -04:00
siikamiika
b616bac66e
remove targetPopupId 'all'
...
Make unset targetPopupId mean the same thing instead
2020-03-21 22:13:07 +02:00
siikamiika
17934cce4b
use random ID as popup ID
2020-03-21 22:13:07 +02:00
siikamiika
2c4fd648db
remove stubs
2020-03-21 22:13:07 +02:00
siikamiika
46c6ad98f3
use dependency injection in QueryParser
...
Also fix an issue with settings update triggering a lookup on unprepared
QueryParser.
2020-03-21 22:13:07 +02:00
siikamiika
962c2a381f
apply all options on profile change
2020-03-21 22:13:07 +02:00
toasted-nutbread
70284c62ee
Replace DisplayGenerator._isCharacterKanji with jp.isCodePointKanji
2020-03-21 13:22:14 -04:00
toasted-nutbread
77a2cc60e9
Move basic string/character testing functions into a mixed/js/japanese.js
2020-03-21 13:18:34 -04:00
toasted-nutbread
a50b76fd21
Remove unnecessary sourceMapping population in convertAlphabeticToKana
2020-03-15 22:24:30 -04:00
toasted-nutbread
248a18dd72
Fix case issue
2020-03-15 22:24:30 -04:00
toasted-nutbread
264820f208
Add more unicode code point ranges
2020-03-15 22:24:30 -04:00
toasted-nutbread
0f15cca2df
Convert Japanese utilities to a module-like style
2020-03-15 22:24:30 -04:00
toasted-nutbread
7c5b64f9a4
Merge pull request #406 from toasted-nutbread/object-property-accessor
...
Object property accessor
2020-03-15 22:23:32 -04:00
toasted-nutbread
4b699a6b46
Change integer state IDs to strings
2020-03-15 12:26:38 -04:00
98afe7adae
Bump version
2020-03-14 13:12:08 -07:00
toasted-nutbread
174a942e07
Fix misuse of getPathString
2020-03-14 13:51:06 -04:00
toasted-nutbread
6865fc0b52
Add ObjectPropertyAccessor
2020-03-14 13:50:36 -04:00
toasted-nutbread
64fc0349a1
Update global declarations
2020-03-10 22:40:35 -04:00
toasted-nutbread
f7bbcb6df4
Merge pull request #408 from toasted-nutbread/use-code-point
...
Replace charCodeAt and fromCharCode with codePointAt and fromCodePoint
2020-03-10 19:24:24 -04:00
toasted-nutbread
36c55f0b17
Merge pull request #401 from toasted-nutbread/audio-refactor
...
Audio refactor
2020-03-10 19:20:34 -04:00
toasted-nutbread
72219ba353
Replace charCodeAt and fromCharCode with codePointAt and fromCodePoint
2020-03-09 21:58:06 -04:00
toasted-nutbread
0cbf427ab5
Update argument order
2020-03-09 21:00:57 -04:00
siikamiika
7541517d80
Merge pull request #405 from siikamiika/fix-popup-depth-search-page
...
start popup depth from 1 on search page
2020-03-09 12:16:01 +02:00
siikamiika
2ca88b9b9f
strict check if popup depth has been set
2020-03-09 11:56:06 +02:00
siikamiika
0112dbab33
fix searchQueryUpdate
2020-03-09 04:06:31 +02:00
siikamiika
e2bf22831a
start popup depth from 1 on search page
2020-03-09 02:10:28 +02:00
toasted-nutbread
9cd4a52b9e
Rename audio.js to audio-uri-builder.js
2020-03-07 21:57:26 -05:00
toasted-nutbread
aad4ab5ecc
Rename audio functions using "url" to use "uri"
2020-03-07 21:57:26 -05:00
toasted-nutbread
391f3dd29a
Update how audio URIs are built
2020-03-07 21:57:26 -05:00
toasted-nutbread
21d194d145
Make _audioInject internal to Backend
2020-03-07 21:56:15 -05:00
toasted-nutbread
426c1534e7
Remove marker restrictions
2020-03-07 21:51:56 -05:00
toasted-nutbread
79eb4bdc16
Remove bg/js/api.js
2020-03-07 21:49:04 -05:00
toasted-nutbread
8f9b6534c6
Move stringReplaceAsync
...
It is only used in AnkiNoteBuilder and it was originally created
for this purpose.
2020-03-07 21:47:48 -05:00
toasted-nutbread
7ac1c843a9
Use dependency injection for apiTemplateRender
2020-03-07 21:47:48 -05:00
toasted-nutbread
69cce49b0d
Move Anki note generation functionality into a new class
2020-03-07 21:46:59 -05:00
toasted-nutbread
dceaa85309
Rename audio.js to audio-system.js
2020-03-07 21:43:51 -05:00
toasted-nutbread
6adf2cf63f
Rename function
2020-03-07 21:43:51 -05:00
toasted-nutbread
a8eb50d96f
Use dependency injection for getAudioUri implementation
2020-03-07 21:43:51 -05:00
toasted-nutbread
75eac153d6
Remove old APIs
2020-03-07 21:42:19 -05:00
toasted-nutbread
d8e2e69ca5
Use AudioSystem on the audio settings page
2020-03-07 21:42:18 -05:00
toasted-nutbread
cadcd72fad
Use AudioSystem in Backend
2020-03-07 21:42:18 -05:00
toasted-nutbread
e048a1efce
Use AudioSystem in Display
2020-03-07 21:42:18 -05:00
toasted-nutbread
110e561eae
Create new AudioSystem class
2020-03-07 21:42:18 -05:00
toasted-nutbread
b8eb5e6016
Merge pull request #397 from toasted-nutbread/clipboard-monitor-refactor2
...
Clipboard monitor refactor
2020-03-07 21:41:45 -05:00
siikamiika
4b0dfa92aa
Merge pull request #393 from siikamiika/reconnect-frontend-api-sender
...
reconnect FrontendApiSender after disconnecting
2020-03-08 00:50:24 +02:00
toasted-nutbread
eea9dc68b9
Fix runtime.lastError error on startup in Firefox
2020-03-07 17:41:57 -05:00
toasted-nutbread
ba64f34df1
Mark fields as private
2020-03-07 10:48:56 -05:00
toasted-nutbread
93aa275d82
Use explicit dependency injection for ClipboardMonitor
2020-03-07 10:47:30 -05:00
toasted-nutbread
7822230b7f
Use events for ClipboardMonitor
2020-03-07 10:41:31 -05:00
siikamiika
24d9001b14
fix options object location
2020-03-07 14:27:44 +02:00
siikamiika
387e93dbbc
use docSentenceExtract in QueryParser
2020-03-07 14:20:08 +02:00
siikamiika
9fef0751f3
replace spread with destructuring
2020-03-07 04:11:18 +02:00
siikamiika
86be737508
fix popup containsPoint offset
2020-03-07 03:52:36 +02:00
siikamiika
8b76761744
reconnect FrontendApiSender after disconnecting
2020-03-07 00:32:45 +02:00
siikamiika
de8d9e6bf1
fix return type
2020-03-04 05:28:22 +02:00
siikamiika
9ceb663f29
add missing runtime message for backendPrepared
2020-03-03 00:05:01 +02:00
siikamiika
e6347a94e7
prepare Backend for browser_action
2020-03-02 23:26:55 +02:00
siikamiika
a05a05c4f4
fix content script entry point Yomichan prepare
...
Covers Popup stuff in addition to Frontend
2020-03-02 12:01:53 +02:00
siikamiika
56b2f2c853
trigger yomichanCoreReady only when preparing
2020-03-02 11:31:09 +02:00
siikamiika
e0edb30efd
fix Backend prepare issues in settings
2020-03-02 11:18:09 +02:00
siikamiika
bd48d2f919
fix Yomichan core message issues
2020-03-02 10:35:46 +02:00
siikamiika
967e99b7f6
ensure Backend prepare in other places
2020-03-02 04:51:45 +02:00
siikamiika
e6e5f23cf8
fix API calls when Backend isn't ready yet
2020-03-02 00:39:15 +02:00
siikamiika
2abf46b6fa
simplify backend prepare
2020-03-01 23:06:37 +02:00
toasted-nutbread
46fee07d36
Fix audio buttons not being hidden properly
2020-03-01 14:51:39 -05:00
siikamiika
b3994acbac
Merge pull request #384 from siikamiika/fix-non-primary-dictionary-format
...
compatibility transform non-primary definitions
2020-03-01 21:43:36 +02:00
toasted-nutbread
a4b0a556d4
Merge pull request #380 from toasted-nutbread/anki-templates-file
...
Load default Anki field templates from a file
2020-03-01 14:41:48 -05:00
siikamiika
9af8f999f4
compatibility transform non-primary definitions
2020-03-01 21:26:45 +02:00
siikamiika
314c567a47
fix hotkeys in popup
2020-03-01 19:02:43 +02:00
toasted-nutbread
a46a84ee15
Increase z-index for navigation-header
2020-03-01 11:31:19 -05:00
toasted-nutbread
52d8d658a2
Fix empty keys definitions and add Shift/Alt checks
2020-02-29 10:00:28 -05:00
toasted-nutbread
8e29da0c6b
Load default Anki field templates from a file
2020-02-27 20:33:13 -05:00
toasted-nutbread
fdfc2d33bb
Simplify event to use bind
2020-02-26 21:19:22 -05:00
toasted-nutbread
2d109c3e56
Use functions directly rather than wrapping in () => {} when args are same
2020-02-26 21:17:01 -05:00
toasted-nutbread
8bc1a40914
Use .bind instead of () => {}
2020-02-26 21:01:40 -05:00
toasted-nutbread
fc08cd74fe
Use .bind instead of () => {}
2020-02-26 20:35:37 -05:00
toasted-nutbread
78dc501d02
Move event handler definitions
2020-02-26 20:07:14 -05:00
toasted-nutbread
03ba1b633e
Move event handler definitions
2020-02-26 20:03:21 -05:00
toasted-nutbread
d08ac02c6a
Move event handler definitions
2020-02-26 19:52:12 -05:00
toasted-nutbread
d17af2cbab
Move event handler definitions
2020-02-26 19:48:53 -05:00
toasted-nutbread
359eabb26e
Move event handler definitions
2020-02-26 19:48:30 -05:00
toasted-nutbread
13874e962b
Refactor DisplaySearch.onKeyDownIgnoreKeys
2020-02-26 19:34:25 -05:00
toasted-nutbread
8d5d034516
Move event handler definitions
2020-02-26 19:22:32 -05:00
toasted-nutbread
007789ffa0
Organize, remove unnecessary null checks
2020-02-26 19:08:35 -05:00
toasted-nutbread
0c1b250b4f
Move event handler function bodies
2020-02-26 19:04:21 -05:00
toasted-nutbread
fa385aafa4
Fix noteUsesScreenshot not checking mode
2020-02-25 22:24:22 -05:00
toasted-nutbread
0b5a26e64a
Update dictEnabledSet and dictConfigured to use for of
2020-02-25 22:15:49 -05:00
toasted-nutbread
b391704f3d
Use for of
2020-02-25 22:13:06 -05:00
toasted-nutbread
7b97138ad1
Changed type returned by apiTextParseMecab to avoid using for in
2020-02-25 22:13:03 -05:00
toasted-nutbread
6bd714fec0
Use Map to avoid using for in
2020-02-25 22:12:00 -05:00
toasted-nutbread
798517cdf1
Use for of
2020-02-25 22:11:58 -05:00
toasted-nutbread
2e0b3a6ccc
Refactor dictNoteFormat
2020-02-25 20:38:18 -05:00
toasted-nutbread
3795af6cb5
Use Object.entries rather than for in
2020-02-25 19:54:59 -05:00
toasted-nutbread
13a94d06ea
Update styles
2020-02-25 19:38:52 -05:00
siikamiika
a0d5d9a821
fix opening options in new tab
2020-02-26 01:54:40 +02:00
706c3edcff
version bump
2020-02-24 21:30:37 -08:00
siikamiika
ffad78f7d4
temporarily disable navigation header mouse wheel
...
Unblock release #355 , #376
2020-02-24 08:57:48 +02:00
toasted-nutbread
15f79bc78b
Fix popupScalingFactor being limited to integer values
2020-02-23 21:12:43 -05:00
toasted-nutbread
d6454bc999
Remove unused
2020-02-23 16:21:52 -05:00
toasted-nutbread
a0b2e11c10
Use TemplateHandler for DisplayGenerator
2020-02-23 16:18:13 -05:00
toasted-nutbread
0c4aa2eeb9
Fix trailing newlines not actually generating a new line in the imposter
...
This was causing vertical scroll offset issues
2020-02-23 13:04:55 -05:00
toasted-nutbread
7697643966
Reject with a consistent error
2020-02-23 11:59:57 -05:00
toasted-nutbread
5a5c18371c
Use textContent instead of innerText
2020-02-23 11:58:17 -05:00
toasted-nutbread
53220af68e
Don't use innerHTML
2020-02-23 11:49:52 -05:00
toasted-nutbread
c0d91bffc4
Add no-shadow
2020-02-22 14:53:02 -05:00
toasted-nutbread
0c8f567e6d
Fix indentation
2020-02-22 14:52:09 -05:00
toasted-nutbread
56567903a5
Fix unnamed functions
2020-02-22 14:52:09 -05:00
toasted-nutbread
c3e7280365
Simplify ternary
2020-02-22 14:52:09 -05:00
toasted-nutbread
aa76113e75
Fix block padding
2020-02-22 14:52:09 -05:00
toasted-nutbread
6d75637ace
Fix brace style issues
2020-02-22 14:52:08 -05:00
toasted-nutbread
1944f7a215
Fix indent
2020-02-22 14:52:08 -05:00
toasted-nutbread
54bb702b84
Updates for PR feedback
2020-02-22 14:43:06 -05:00
toasted-nutbread
f143632f28
Simplify only assignment
2020-02-22 14:43:06 -05:00
toasted-nutbread
19fb7dacb4
Assign result properties to variables to reduce number of lookups
2020-02-22 14:43:06 -05:00
toasted-nutbread
69b5007842
Reduce number of redundant Map.get calls in dictTermsMergeByGloss
2020-02-22 14:43:06 -05:00
toasted-nutbread
45c685d00a
Add variables for expression and reading
2020-02-22 14:43:06 -05:00
toasted-nutbread
50a171bc75
Simplify update of mergedIndices
2020-02-22 14:43:06 -05:00
toasted-nutbread
89af73b61b
Use Map
2020-02-22 14:43:06 -05:00
toasted-nutbread
5e8b408a23
Change secondarySearchTitles to secondarySearchDictionaries
2020-02-22 14:43:06 -05:00
toasted-nutbread
b6718dc4a4
Use findTerms instead of findTermsInternal
2020-02-22 14:43:06 -05:00
toasted-nutbread
1c828d205c
Remove unused dictRowsSort
2020-02-22 14:43:06 -05:00
toasted-nutbread
cc2e21cd86
Use Map for dictEnabledSet
2020-02-22 14:43:05 -05:00
toasted-nutbread
b0c566417f
Replace getIndexOfTouch with getTouch
2020-02-22 14:37:10 -05:00
toasted-nutbread
7afc23427e
Use URLSearchParams
2020-02-22 14:37:10 -05:00
toasted-nutbread
163211ade3
Use Map
2020-02-22 14:37:10 -05:00
toasted-nutbread
a4bdffbd9d
Use Map
2020-02-22 14:37:10 -05:00
toasted-nutbread
5587116bae
Simplify spread
2020-02-22 14:37:10 -05:00
toasted-nutbread
bc94970a46
Use Map
2020-02-22 14:37:10 -05:00
toasted-nutbread
cae8ed2767
Use Array.isArray instead of hasOwn
2020-02-22 14:37:10 -05:00
toasted-nutbread
1f62dfa572
Use Set
2020-02-22 14:37:10 -05:00
toasted-nutbread
886278b19d
Use Set
2020-02-22 14:36:07 -05:00
toasted-nutbread
452eec8a88
Use Map
2020-02-22 14:36:07 -05:00
toasted-nutbread
77a3dadd0b
Make schema errors have more information
2020-02-22 13:25:28 -05:00
toasted-nutbread
d76ab91f83
Update validate function name in close
2020-02-22 12:45:50 -05:00
toasted-nutbread
86d0fb6643
Require format to be 1, 2, or 3
2020-02-22 12:09:34 -05:00
toasted-nutbread
62d4f68412
Define old tagMeta format in index file
2020-02-22 12:09:34 -05:00
toasted-nutbread
086fefc921
Validate data before importing
2020-02-22 12:09:34 -05:00
toasted-nutbread
d620f40448
Remove old dictionary import functions
2020-02-22 12:09:34 -05:00
toasted-nutbread
177bca4865
Create new dictionary import function
2020-02-22 12:09:33 -05:00
toasted-nutbread
212e5428e8
Mark private functions in database.js
2020-02-22 12:09:33 -05:00
toasted-nutbread
a8b1e40a1e
Close to prevent hangs
2020-02-19 19:59:24 -05:00
toasted-nutbread
0f46e3a093
Use a token to ensure that messages are coming from Yomichan
2020-02-17 11:02:21 -05:00
toasted-nutbread
aee16c4431
Check origin on window messages
2020-02-16 23:41:17 -05:00
toasted-nutbread
ae4ee9ddee
Fix error handling on style injection
2020-02-16 21:49:28 -05:00
toasted-nutbread
e173a71ba6
Fix CSS injection on about:blank pages
2020-02-16 21:46:13 -05:00
toasted-nutbread
3d27e80ae6
Delay CSS injection until a popup is created
2020-02-16 21:46:13 -05:00
toasted-nutbread
9fd6ee382d
Create more generic function for injecting stylesheets
2020-02-16 21:46:13 -05:00
toasted-nutbread
d3aefdc4e3
Override setCustomOuterCss instead of Popup.injectOuterStylesheet
2020-02-16 21:45:30 -05:00
toasted-nutbread
b6a50e234c
Change parameter name
2020-02-16 21:44:45 -05:00
toasted-nutbread
2c3f510010
Allow apiInjectStylesheet to inject a URL
2020-02-16 21:43:35 -05:00
toasted-nutbread
1c6ed1d286
Set URL before adding to the document
2020-02-16 21:41:31 -05:00
toasted-nutbread
c6efa65626
Fix missing argument
2020-02-16 19:09:33 -05:00
toasted-nutbread
dcd243c9e9
Update how popups are created
2020-02-16 18:59:08 -05:00
toasted-nutbread
5d3c13ee98
Tweak how fullscreen changes are observed
2020-02-16 18:52:04 -05:00
toasted-nutbread
070ae70f7c
Create EventListenerCollection class
2020-02-16 18:47:57 -05:00
toasted-nutbread
36605f74c3
Undo "Obscure the iframe's URL from the host page"
...
There are some additional issues which cause the frame to be reset to
about:blank on certain occasions which must be fixed before this can be
used.
2020-02-16 18:47:46 -05:00
toasted-nutbread
cc989f4411
Add "match_about_blank": true to manifest
2020-02-16 14:22:19 -05:00
toasted-nutbread
6df5220e02
Prevent multiple prepare calls
2020-02-16 12:23:40 -05:00
toasted-nutbread
b5d32c73e6
Simplify process to wait for iframe prepare completion
2020-02-16 12:23:20 -05:00
toasted-nutbread
42f1c2463c
Move generateId function
2020-02-16 12:00:56 -05:00
toasted-nutbread
912d59d3df
Obscure the iframe's URL from the host page
2020-02-15 22:39:09 -05:00
toasted-nutbread
10ec165f14
Check type of other for equals functions
...
Fixes #361
2020-02-15 20:52:21 -05:00
toasted-nutbread
217bd36abc
Use consistent timeout for both setContentTerms and setContentKanji
2020-02-15 20:36:46 -05:00
toasted-nutbread
c5cbf99e89
Use promiseTimeout instead of delay
2020-02-15 20:35:51 -05:00
toasted-nutbread
496d2599ea
Move error handling for apiDefinitionsAddable
2020-02-15 20:33:20 -05:00
toasted-nutbread
faf15c08aa
Rename optionsUpdate event to optionsUpdated
...
Past tense better indicates that the options were changed, but no data
is being included as part of the event. It is also more consistent with
the other event names the yomichan object currently provides.
2020-02-14 22:34:44 -05:00
toasted-nutbread
89cb98e4d1
Add global apiForward
2020-02-14 21:50:17 -05:00
toasted-nutbread
853faaf48c
Merge pull request #358 from toasted-nutbread/general-refactoring
...
General refactoring
2020-02-14 21:25:25 -05:00
toasted-nutbread
4dd4926672
Remove unused apiGetDisplayTemplatesHtml and apiGetQueryParserTemplatesHtml
2020-02-14 20:51:10 -05:00
toasted-nutbread
61c6a753ce
Add apiTemplateRender back to mixed api.js
2020-02-14 20:11:40 -05:00
siikamiika
548c67ef1c
remove extra setContentToken check from Display
2020-02-14 23:17:21 +02:00
siikamiika
c09a3ded1d
Merge pull request #357 from siikamiika/simplify-display-prepare
...
Simplify display prepare
2020-02-14 11:00:36 +02:00
toasted-nutbread
6194f9f585
Comma
2020-02-13 20:50:31 -05:00
toasted-nutbread
483f7401b7
Validate bounds of Display.definitions before using
2020-02-13 20:50:31 -05:00
toasted-nutbread
db1da33321
Use Array.from in toIterable
2020-02-13 20:50:31 -05:00
toasted-nutbread
75fbb1565c
Use Map for audioGetFromSources's cache parameter
2020-02-13 20:50:30 -05:00
toasted-nutbread
0e6b75438a
Use Map for Translator.tagCache
2020-02-13 20:50:30 -05:00
toasted-nutbread
e3c871bc00
Remove unused handlebarsRenderStatic
2020-02-13 20:50:30 -05:00
siikamiika
810a7e7d92
use sendMessage to notify about initialization
2020-02-14 02:33:54 +02:00
siikamiika
e645296b1b
fix Map set in Translator.buildTermFrequencies
2020-02-14 01:12:28 +02:00
siikamiika
d7e1ef01d8
use Promise.all to await dependencies
2020-02-13 16:26:45 +02:00
siikamiika
38a6433a46
remove isInjected checks from Popup
2020-02-13 15:04:10 +02:00
siikamiika
8abab28c4d
remove isPrepared check
2020-02-13 14:36:32 +02:00
siikamiika
c0225f1f84
notify popup about initialization
2020-02-13 13:18:54 +02:00
siikamiika
df37acd17f
rename display initialize methods to prepare
2020-02-13 01:59:26 +02:00
siikamiika
93eaee9765
simplify DisplayGenerator initialization
2020-02-13 01:43:01 +02:00
toasted-nutbread
c8e7a1543e
Remove unused
2020-02-11 22:25:48 -05:00
toasted-nutbread
e2ac478cb7
Define more globals
2020-02-11 22:22:16 -05:00
toasted-nutbread
ab9d2b38e0
Remove redundant declaration
2020-02-11 22:22:16 -05:00
toasted-nutbread
4629fb3639
Change no-undef from off to error
2020-02-11 22:22:16 -05:00
toasted-nutbread
65dfb855fb
Fix undefined id
2020-02-11 22:21:55 -05:00
toasted-nutbread
9c5ad3ea67
Merge pull request #346 from toasted-nutbread/dictionary-schemas
...
Dictionary schemas
2020-02-11 21:21:37 -05:00
siikamiika
9ffd0cb441
Merge pull request #350 from siikamiika/query-parser-html-templates
...
query parser html templates
2020-02-11 11:07:05 +02:00
toasted-nutbread
17181eb97e
Improve style of some tags
2020-02-10 21:38:11 -05:00
toasted-nutbread
bbb74d0a48
Assign _isInitialized
2020-02-10 20:38:20 -05:00
siikamiika
9c98c631af
fix async issues
2020-02-10 22:09:23 +02:00
siikamiika
4f1ed14f07
simplify TemplateHandler
2020-02-10 21:56:48 +02:00
siikamiika
b7f347ff4f
remove newline from template
2020-02-10 21:19:18 +02:00
siikamiika
6c63a17d66
query parser html templates
2020-02-10 21:19:18 +02:00
siikamiika
14b9f4a827
preserve search page mode on manual search
2020-02-10 01:31:47 +02:00
siikamiika
460d306f60
update popup search with chrome.tabs.sendMessage
2020-02-10 01:16:06 +02:00
siikamiika
89729d8c20
reuse existing popup window
2020-02-10 00:39:05 +02:00
siikamiika
56f1f8384d
use parseUrl in Backend
2020-02-10 00:09:29 +02:00
siikamiika
4508efb9a6
stop clipboard monitor before starting it again
2020-02-09 22:41:20 +02:00
siikamiika
d4e74a0572
fix existing tab focus
2020-02-09 22:16:52 +02:00
siikamiika
21bad6c6e3
simplify setQuery kana conversion
2020-02-09 21:51:33 +02:00
siikamiika
4e59c2d556
hide native popup option for firefox mobile
2020-02-09 21:51:33 +02:00
siikamiika
1797edc7d8
check chrome.windows support before using
2020-02-09 21:51:33 +02:00
siikamiika
9fbd47e4ea
rename sameTab --> existingOrNewTab
2020-02-09 21:51:33 +02:00
siikamiika
722a2a4bce
disable internal clipboard monitor in native popup
2020-02-09 21:51:33 +02:00
siikamiika
8a295c4bb0
fix constant usage from wrong scope
2020-02-09 21:51:33 +02:00
siikamiika
c16c38638b
hide search input in native popups
2020-02-09 21:51:33 +02:00
siikamiika
8d56d6ffcb
handle closing already closed popup
2020-02-09 21:51:33 +02:00
siikamiika
d7f0369281
use Promise
2020-02-09 21:51:33 +02:00
siikamiika
91682dd633
add permission check to formRead
2020-02-09 21:51:33 +02:00
siikamiika
90a5d79570
use ClipboardMonitor in Backend
2020-02-09 21:51:33 +02:00
siikamiika
c685fd0e5f
extract ClipboardMonitor from DisplaySearch
2020-02-09 21:51:33 +02:00
siikamiika
37a922adc0
fix settings page checkbox
2020-02-09 21:51:33 +02:00
siikamiika
222f869c84
fix search page hotkey
2020-02-09 21:51:33 +02:00
siikamiika
939ad42dac
add global clipboard monitor that spawns popups
...
TODO: refactor the search page clipboard monitor and popup clipboard
monitor to use a common ClipboardMonitor class
2020-02-09 21:51:33 +02:00
siikamiika
f29abfc511
use correct optionsContext
2020-02-09 21:51:33 +02:00
siikamiika
679e42c21c
move apiClipboardGet Firefox handling to Backend
2020-02-09 21:51:33 +02:00
siikamiika
ddc7c71e4f
add support for native popup windows
2020-02-09 21:51:33 +02:00
toasted-nutbread
d5708de4ee
Fix undefined reject
2020-02-08 20:49:01 -05:00
toasted-nutbread
f85f92c665
Remove trailing comma
2020-02-08 20:48:47 -05:00
toasted-nutbread
165959ef06
Move japanese.js into bg
2020-02-08 20:45:30 -05:00
toasted-nutbread
4b17e79cb8
Add schemas for dictionary data
2020-02-08 12:28:46 -05:00
toasted-nutbread
4e2b317d54
Merge pull request #345 from toasted-nutbread/json-schema-improvements
...
JSON schema improvements
2020-02-08 12:28:06 -05:00
siikamiika
8eac191c97
prevent unwanted wheel events on history bar
2020-02-05 14:19:48 +02:00
toasted-nutbread
e8701cb950
Hide anki-invalid-response-error when there is no error
2020-02-02 14:53:32 -05:00
toasted-nutbread
3c28c7dd7c
Fix init
2020-02-02 11:22:22 -05:00
toasted-nutbread
fff1e67a5e
Improve schema path when using getPropertySchema
2020-02-02 11:18:13 -05:00
toasted-nutbread
b1fc9c024a
Update how property schemas are returned
2020-02-02 11:13:26 -05:00
toasted-nutbread
ea808024d7
Fix missing else
2020-02-02 11:04:38 -05:00
toasted-nutbread
3bef380e3b
Add improved error information when validation fails
2020-02-02 10:51:48 -05:00
toasted-nutbread
fca5c75151
Fix ifSchema
2020-02-02 10:35:41 -05:00
toasted-nutbread
7c9fe2c6cf
Fix conditional logic
2020-02-02 10:17:16 -05:00
toasted-nutbread
964db74108
Update schema validation to throw errors
2020-02-02 10:12:01 -05:00
toasted-nutbread
36e641e001
getSchemaOrValueType return null
2020-02-02 10:12:01 -05:00
toasted-nutbread
0171d86b28
Fix maxLength check
2020-02-02 10:12:01 -05:00
toasted-nutbread
52b623b5cd
Improve getPropertySchema's type detection
2020-02-02 10:12:01 -05:00
toasted-nutbread
31dbeab67c
Add validate on JsonSchema
2020-02-02 10:12:01 -05:00
toasted-nutbread
980a1ddf74
Improve support for array schemas
2020-02-02 10:12:01 -05:00
toasted-nutbread
a844698f15
Return unconstrained schema when additionalProperties is true/undefined
2020-02-02 10:12:01 -05:00
toasted-nutbread
203216986e
Add support for conditionals
2020-02-02 10:12:01 -05:00
toasted-nutbread
6595715f7c
Add support for allOf, anyOf, oneOf, and not
2020-02-02 10:12:01 -05:00
toasted-nutbread
0b474751b5
Add simplified isObject test
2020-02-02 10:12:01 -05:00
toasted-nutbread
f23e0c9c95
Validate Deinflector.ruleTypes
2020-02-02 10:09:19 -05:00
siikamiika
b8326138a3
add scannable tags for expression and reading
2020-02-02 13:57:30 +02:00
siikamiika
24690ceb7c
fix glossary item selector
2020-02-02 13:44:08 +02:00
toasted-nutbread
d5c0155a82
Update main dictionary value when changing modifying profile
2020-02-01 21:00:43 -05:00
toasted-nutbread
8eaa0334ac
Remove option for dictionaries that aren't installed after changing values
2020-02-01 21:00:43 -05:00
toasted-nutbread
55047def9d
Separate the functionality of updateMainDictionarySelect
...
One function now updates the options, and another handles updating the value.
The options are no longer mutated due to updating this <select>'s available options.
2020-02-01 21:00:43 -05:00
toasted-nutbread
748cd27ad0
Remove argument from onDictionaryOptionsChanged
2020-02-01 21:00:43 -05:00
toasted-nutbread
566012f228
Use await
2020-02-01 21:00:43 -05:00
toasted-nutbread
5541aae201
Assign valid score during construction
2020-02-01 21:00:27 -05:00
toasted-nutbread
daf0385448
Add declaration
2020-02-01 21:00:27 -05:00
toasted-nutbread
6b9116ee49
Fix term tags not always being displayed
2020-02-01 21:00:27 -05:00
toasted-nutbread
1d9332cb69
Simplify getSequencedDefinitions and dictTermsMergeBySequence
2020-02-01 21:00:27 -05:00
toasted-nutbread
09a1214f49
More fixes for Firefox
2020-02-01 21:00:07 -05:00
toasted-nutbread
0762f13a6d
Workaround Firefox text selection bug
2020-02-01 21:00:07 -05:00
toasted-nutbread
db247a2837
Fix double clicking reason and glossary text
2020-02-01 21:00:07 -05:00
toasted-nutbread
dd700af0be
Fix tag double click
2020-02-01 21:00:07 -05:00
siikamiika
05bb4aef71
partially revert be77544d77ba1f07955d76ebba1ab36286f0e52f
2020-01-28 02:34:05 +02:00
siikamiika
02e0e24153
change jpod101 kana check to detect katakana
2020-01-27 23:28:01 +02:00
siikamiika
dd019ecf68
fix audio index in resultOutputMode = 'merge'
2020-01-27 23:24:34 +02:00
toasted-nutbread
2dbb24ea04
Improve error messages when Interface server is invalid
2020-01-26 21:01:19 -05:00
0cf1cf3aa0
Version bump
2020-01-26 11:27:31 -08:00
toasted-nutbread
1f3ff6fad0
Fix equals function on TextSourceRange when imposter elements are used
2020-01-26 10:31:17 -05:00
toasted-nutbread
54a48a7a9b
Ensure textSource is cleaned up if it isn't used
2020-01-26 10:31:17 -05:00
siikamiika
e70638e8ea
fix term spacing value display in settings
2020-01-26 00:56:52 +02:00
siikamiika
d2430783fd
fix scanning parser
2020-01-26 00:46:23 +02:00
siikamiika
7a2dbb6f73
add default value for termSpacing
2020-01-25 18:29:52 +02:00
toasted-nutbread
a5fc79a754
Create buildKanjiMeta for parity with buildTermMeta
2020-01-24 22:27:25 -05:00
toasted-nutbread
8233119eb7
Update how frequency data is set up
2020-01-24 22:24:05 -05:00
toasted-nutbread
ee41e0e42e
Rename buildTermFrequencies to buildTermMeta
2020-01-24 22:23:25 -05:00
toasted-nutbread
00bbcff8a2
Fix findTermMetaBulk and findKanjiMetaBulk not returning expression/character
2020-01-24 22:22:40 -05:00
toasted-nutbread
d7ce829107
Use Map for Mecab.listeners
2020-01-24 22:02:53 -05:00
toasted-nutbread
632765a3b5
Change termsUniqueMap to use a real map
2020-01-24 21:57:01 -05:00
toasted-nutbread
c75d04ccb7
Change uniqueDeinflectionsMap to use a real Map
2020-01-24 21:51:58 -05:00
siikamiika
7357eaf07a
Merge pull request #330 from siikamiika/query-parser-helper-disabling
...
Query parser helper disabling
2020-01-25 03:29:55 +02:00
toasted-nutbread
be645c2c98
Add support for dashes
2020-01-24 20:15:25 -05:00
toasted-nutbread
46e3d72641
Move where 'a' character offset is applied
2020-01-24 20:15:25 -05:00
toasted-nutbread
0c3b7d0fbc
Add description of translation options
2020-01-24 20:15:25 -05:00
toasted-nutbread
67759b7aa3
Add convertHiraganaToKatakana option
2020-01-24 20:15:25 -05:00
toasted-nutbread
538d83c5a6
Reorganized variants to better reflect usage order
2020-01-24 20:15:25 -05:00
toasted-nutbread
317bf35bc0
Replace and remove old character/string testing functions
2020-01-24 20:15:25 -05:00
toasted-nutbread
1fa8a59626
Create new character/string testing functions
2020-01-24 20:15:25 -05:00
toasted-nutbread
9b509d50a9
Add character range definitions
2020-01-24 20:15:25 -05:00
toasted-nutbread
3c17388ff8
Update constant naming convention
2020-01-24 20:15:25 -05:00
toasted-nutbread
9c5f1d4e59
Update options schema
2020-01-24 20:15:25 -05:00
toasted-nutbread
b5015264f2
Include half width and full width characters as Japanese characters
2020-01-24 20:15:25 -05:00
toasted-nutbread
86d96a9036
Update detection of Japanese characters
2020-01-24 20:15:25 -05:00
toasted-nutbread
be2e6e0d93
Optimize jpIsKanji and jpIsKana
2020-01-24 20:15:25 -05:00
toasted-nutbread
fb6e56b3b7
Remove redundant alphanumeric parameter from findTermsInternal
2020-01-24 20:15:25 -05:00
toasted-nutbread
73cc64fb5c
Implement new translation options
2020-01-24 20:15:25 -05:00
toasted-nutbread
4415a71ae2
Add translation options
2020-01-24 20:15:25 -05:00
toasted-nutbread
9ae87f186a
Update how deinflections are generated
2020-01-24 20:15:25 -05:00
siikamiika
fa4004437d
query parser: add toggle for term spacing
2020-01-25 02:57:57 +02:00
siikamiika
aa5a044dad
query parser: add reading mode 'none'
2020-01-25 02:56:14 +02:00
toasted-nutbread
04727a8cd7
Fix viewport issues when popupScaleRelativeToVisualViewport is disabled
2020-01-22 20:38:21 -05:00
toasted-nutbread
2f994a7e5d
Fix font size issue with action-button
2020-01-22 20:38:21 -05:00
toasted-nutbread
8e15c20311
Remove window.onscroll handler since it causes a warning
2020-01-22 20:38:21 -05:00
toasted-nutbread
5afad35c4e
Fix _onApiGetZoom when chrome.tabs.getZoom is not available
2020-01-22 20:38:21 -05:00
toasted-nutbread
74d9b0e857
Update full-width popup to stay on screen
2020-01-22 20:38:21 -05:00
toasted-nutbread
d59f2022b9
Allow viewport to be used for constraining popup position
2020-01-22 20:38:21 -05:00
toasted-nutbread
21dbb19565
Update popup position on scroll
2020-01-22 20:38:21 -05:00
toasted-nutbread
e73e4c032c
Implement scale relative to visual viewport
2020-01-22 20:38:21 -05:00
toasted-nutbread
5d366b722f
Add option for changing poup scale relative to visual viewport
2020-01-22 20:38:21 -05:00
toasted-nutbread
48d93f3fa5
Fix default value for popupScaleRelativeToPageZoom
2020-01-22 20:38:21 -05:00
toasted-nutbread
14c1f379ec
Update options schema
2020-01-22 20:38:21 -05:00
toasted-nutbread
4d85a36091
Fix popup size changing when zooming
2020-01-22 20:38:21 -05:00
toasted-nutbread
351598a182
Add settings to control popup content scale
2020-01-22 20:38:21 -05:00
toasted-nutbread
e740965d4f
Scale popup based on current page zoom factor
2020-01-22 20:38:21 -05:00
toasted-nutbread
22afab2f47
Remove _isInitialized
2020-01-22 20:38:21 -05:00
toasted-nutbread
e51fd8ea71
Add _isInjectedAndLoaded property
2020-01-22 20:38:21 -05:00
toasted-nutbread
f725549330
Remove redundant window resize handler
2020-01-22 20:38:21 -05:00
toasted-nutbread
14e48cf854
Create single function for how the frontend shows popup content
2020-01-22 20:38:21 -05:00
toasted-nutbread
8ef57936d7
Add functionality for getting and observing zoom factor
2020-01-22 20:38:21 -05:00
toasted-nutbread
f662137481
Move body font settings to root
2020-01-22 20:38:21 -05:00
toasted-nutbread
26ea278c29
Improve debug logging
2020-01-21 19:08:56 -05:00
siikamiika
1fd568ab8e
fix term reason selector
2020-01-19 03:04:45 +02:00
toasted-nutbread
d8b0d5267b
Catch exception on range.setStart
...
Fixes #328
2020-01-17 20:47:51 -05:00
toasted-nutbread
4c3321612b
Add space to end of term list
2020-01-16 22:39:26 -05:00
toasted-nutbread
c8fd33ecf4
Remove redundant definition
2020-01-16 22:39:26 -05:00
toasted-nutbread
9abfd7acde
Always show actions when there is only a single term result
2020-01-16 22:39:26 -05:00
toasted-nutbread
6c344b2740
Fix incorrect selector
2020-01-16 22:39:26 -05:00
toasted-nutbread
f969b5b8a9
Update popup scan ignore selectors
2020-01-16 22:39:26 -05:00
toasted-nutbread
62da7ec5cc
Update expression-scan-toggle to term-expression-text
2020-01-16 22:39:26 -05:00
toasted-nutbread
d4296a34cc
Fix scroll position when header is visible
2020-01-16 22:39:26 -05:00
toasted-nutbread
0b1bee8c00
Fix invalid variables
2020-01-16 22:39:26 -05:00
toasted-nutbread
dccc60562a
Update navigation header style on search page
2020-01-16 22:39:26 -05:00
toasted-nutbread
7686e56c00
Move display templates into a single file
2020-01-16 22:39:26 -05:00
toasted-nutbread
d512c111f6
Update how content display is changed
2020-01-16 22:39:26 -05:00
toasted-nutbread
97f7df3302
Don't use document fragment
2020-01-16 22:39:26 -05:00
toasted-nutbread
7a6f85879e
Update content assignment to use unique token
2020-01-16 22:39:26 -05:00
toasted-nutbread
dbbcfa5739
Only use Display.setContent
2020-01-16 22:39:26 -05:00
toasted-nutbread
c53947a94a
Only instantiate the first child
2020-01-16 22:39:26 -05:00
toasted-nutbread
6c58cbcf51
Remove kanji.html and terms.html
2020-01-16 22:39:26 -05:00
toasted-nutbread
24832be636
Update how spinner visibility is controlled
2020-01-16 22:39:26 -05:00
toasted-nutbread
a50e2fb0f1
Fix furigana segmentation
2020-01-16 22:39:26 -05:00
toasted-nutbread
56ee7f8df4
Update display content generation to use HTML templates
2020-01-16 22:39:26 -05:00
siikamiika
8292be92d8
use TextScanner in QueryParser
2020-01-16 23:22:38 +02:00
9b4ec5a094
Version bump
2020-01-12 19:32:48 -08:00
toasted-nutbread
fe5e05f8aa
Fix incorrect result ordering
2020-01-12 21:31:04 -05:00
f1f6a21732
Remove leading zeroes from version number to make Mozilla happy.
2020-01-11 18:19:45 -08:00
174b923665
New version for a new year
2020-01-04 11:53:05 -08:00
toasted-nutbread
0d7ccf25b8
Update license info URL
2020-01-01 12:00:31 -05:00
toasted-nutbread
899ef167d1
Update copyright
2020-01-01 12:00:00 -05:00
toasted-nutbread
bbace4c93b
Fix schema defaults not applying to arrays
2019-12-29 18:57:29 -05:00
toasted-nutbread
e2a4a46e60
Implement settings reset
2019-12-29 12:33:28 -05:00
toasted-nutbread
f17b55239e
Implement settings import
2019-12-29 12:33:28 -05:00
toasted-nutbread
5045a9a3a0
Implement settings export
2019-12-29 12:33:28 -05:00
toasted-nutbread
d2da4f7e62
Add apiOptionsSchemaGet
2019-12-29 12:33:15 -05:00
toasted-nutbread
50e0fbbb66
Use schema to validate options
2019-12-29 12:33:15 -05:00
toasted-nutbread
b770944b12
Create proxy system for json schema validation
2019-12-29 12:33:15 -05:00
toasted-nutbread
277e13f22f
Add schema file for options
2019-12-29 12:33:15 -05:00
toasted-nutbread
ca2aca19c5
Upgrade default fieldTemplates to null
2019-12-29 12:33:03 -05:00
toasted-nutbread
d2ae7364bb
Update anki-templates.js to control the value of fieldTemplates
...
Also assigns a value of null when using the default value
2019-12-29 12:33:03 -05:00
toasted-nutbread
3033fea31e
Treat null templates as the default value
2019-12-29 12:33:03 -05:00
toasted-nutbread
024f969bfd
Update comment on getClipboardText
2019-12-22 20:35:26 -05:00
toasted-nutbread
dec7f6cabb
Add comment describing what token is used for
2019-12-22 20:35:26 -05:00
toasted-nutbread
8b89e99eff
Remove contenteditable="true" from textarea
2019-12-22 20:35:26 -05:00
toasted-nutbread
11b94d5a82
Make apiClipboardGet use plaintext
...
Also clear the value before returning
2019-12-22 20:35:26 -05:00
toasted-nutbread
bf93d9f5f9
Improve performance of DisplaySearch's clipboard monitor
2019-12-22 20:35:26 -05:00
toasted-nutbread
362e317a5d
Change FrontendApiSender.callbacks to be a map
2019-12-21 14:30:13 -05:00
toasted-nutbread
a2175f2c29
Move PopupProxyHost initialization
2019-12-21 13:27:32 -05:00
toasted-nutbread
7ae0584077
Update initialization
2019-12-21 13:19:31 -05:00
toasted-nutbread
35216332bf
Replace window.yomichan_backend with window.yomichanBackend
2019-12-20 23:21:29 -05:00
toasted-nutbread
f8365b8092
Replace window.yomichan_search with DisplaySearch.instance
2019-12-20 23:20:56 -05:00
toasted-nutbread
b2cc694d95
Replace window.yomichan_display with DisplayFloat.instance
2019-12-20 23:20:42 -05:00
toasted-nutbread
8c236cca44
Remove unused yomichan_frontend
2019-12-20 23:20:22 -05:00
toasted-nutbread
7b9731e616
Fix apiOptionsGet being used on the background page
2019-12-20 22:54:28 -05:00
toasted-nutbread
ec8b805e8f
Fix missing API functions being used on the background page
2019-12-20 22:46:20 -05:00
toasted-nutbread
d7bf128333
Update handlebars cache
2019-12-20 21:51:34 -05:00
toasted-nutbread
2519f99f54
Update how orphan state is observed
2019-12-20 13:44:33 -05:00
toasted-nutbread
2a95f1420f
Move optionsUpdate message handler into Yomichan class
2019-12-20 13:36:54 -05:00
toasted-nutbread
e14bd75a4f
Change how getUrl message is handled
2019-12-20 13:15:26 -05:00
toasted-nutbread
cab2a39981
Simplify options passed to docRangeFromPoint
2019-12-17 20:56:32 -05:00
toasted-nutbread
4b5138b96e
Override pointer-events with important
2019-12-17 20:54:57 -05:00
toasted-nutbread
ff1f256ffa
Only return unique elements from docElementsFromPoint
...
This fixes #294
2019-12-17 20:53:12 -05:00
toasted-nutbread
9557d8048b
Fix undefined reference
2019-12-16 19:54:41 -05:00
toasted-nutbread
68a0293867
Make PopupProxy functions async enabled status match Popup
2019-12-16 19:54:41 -05:00
toasted-nutbread
d6c64643b1
Don't return promises for frontend message handlers
2019-12-16 19:54:41 -05:00
toasted-nutbread
0fb2357ec7
isVisibleAsync => isVisible
2019-12-16 19:54:41 -05:00
toasted-nutbread
29734ea6e9
isVisible => isVisibleSync
2019-12-16 19:54:41 -05:00
toasted-nutbread
72ab6f1f45
Remove unused child getter
2019-12-16 19:54:41 -05:00
toasted-nutbread
801df8000f
Mark private members
2019-12-16 19:54:41 -05:00
toasted-nutbread
7c68490d2e
Add setParent to popup
2019-12-16 19:54:41 -05:00
toasted-nutbread
30e13354b3
Add Popup.isProxy
2019-12-16 19:54:41 -05:00
toasted-nutbread
289a1849c4
Add _createPopupInternal to return both popup and new ID
2019-12-16 19:54:41 -05:00
toasted-nutbread
41fadfd0a9
Add setChildrenSupported to popup
2019-12-16 19:54:41 -05:00
toasted-nutbread
7140a19100
Remove unused property assignment
2019-12-16 19:54:41 -05:00
toasted-nutbread
c4719cb7f4
Add getContainer to popup
2019-12-16 19:54:41 -05:00
toasted-nutbread
4ba93b0770
Add getContainerRect to popup
2019-12-16 19:54:41 -05:00
toasted-nutbread
37da5fef59
Move container definition
2019-12-16 19:54:41 -05:00
toasted-nutbread
c3ea952844
Mark private functions
2019-12-16 19:54:41 -05:00
toasted-nutbread
44bde5c676
Reorganize popup-only public functions
2019-12-16 19:54:41 -05:00
toasted-nutbread
4014bbab42
Reorganize popup public functions to match popup proxy
2019-12-16 19:54:41 -05:00
toasted-nutbread
8164ccfbfc
Group poup static functions together
2019-12-16 19:54:41 -05:00
toasted-nutbread
fab0d70358
Move popup public properties
2019-12-16 19:54:41 -05:00
toasted-nutbread
2c3a145866
Mark private members
2019-12-16 19:54:41 -05:00
toasted-nutbread
8a127e07f3
Mark private message handlers
2019-12-16 19:54:41 -05:00
toasted-nutbread
525a3a50d1
Mark private functions
2019-12-16 19:54:41 -05:00
toasted-nutbread
2c8c6866ef
jsonRectToDOMRect => convertJsonRectToDOMRect
...
Also make static
2019-12-16 19:54:41 -05:00
toasted-nutbread
3f8cc83c25
Group nested message handlers together
2019-12-16 19:54:41 -05:00
toasted-nutbread
88ac8f4ead
Update PopupProxyHost.popups to use a Map
2019-12-16 19:54:41 -05:00
toasted-nutbread
8efbf9bd0d
Flag members as private
2019-12-16 19:54:41 -05:00
toasted-nutbread
bf02eb2ea1
Mark PopupProxy internal functions as private
2019-12-16 19:54:41 -05:00
toasted-nutbread
db7e179626
Clear files after getting the value
2019-12-15 15:51:30 -05:00
toasted-nutbread
8c9416d70d
Move conditions-ui into settings folder
2019-12-14 12:08:07 -05:00
toasted-nutbread
0bbba8fcc7
Isolate values returned across window contexts
2019-12-14 11:12:39 -05:00
toasted-nutbread
ddaf44ba7b
Isolate functions passed across window contexts
2019-12-14 11:12:39 -05:00
toasted-nutbread
87ece13647
Isolate arguments passed across window contexts
2019-12-14 11:12:39 -05:00
toasted-nutbread
300282e3b4
Read file in the current window context before passing to backend
2019-12-14 11:12:39 -05:00
toasted-nutbread
e417a3fda3
Fix incorrect function
2019-12-13 23:11:56 -05:00
toasted-nutbread
69556533e1
Fix command handling
2019-12-13 23:11:56 -05:00
toasted-nutbread
b1f72905cf
Add functions for modifying mutable options
2019-12-13 23:11:56 -05:00
toasted-nutbread
17277a6450
Remove getOptionsArray
2019-12-13 23:11:56 -05:00
toasted-nutbread
ce51fe7eca
Use a single api.js
2019-12-13 23:11:56 -05:00
toasted-nutbread
11b300ab76
Move apiClipboardGet implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
2fef2bf5a8
Move apiGetEnvironmentInfo implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
f786713466
Move apiInjectStylesheet implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
01a3432627
Move apiFrameInformationGet implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
daff44a010
Move apiForward implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
d8b21606ba
Move apiScreenshotGet implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
1202ad261e
Move apiAudioGetUrl implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
f63220b6c5
Move apiCommandExec implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
f07207c9bf
Move apiTemplateRender implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
5a74350552
Move apiNoteView implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
233ed4d0fb
Move apiDefinitionsAddable implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
c9cd29889d
Move apiDefinitionAdd implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
7091c8c5c0
Move apiTextParseMecab implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
ddad034aa6
Move apiTextParse implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
73ce2fe3d3
Move apiTermsFind implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
5cceba15e2
Move apiKanjiFind implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
8dff73679e
Move apiOptionsSave implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
6a1cfbaad6
Move apiOptionsSet implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
d6fe5c3e46
Move apiOptionsGetFull implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
4922d3433d
Move apiOptionsGet implementation into Backend
2019-12-13 23:11:56 -05:00
toasted-nutbread
832405c74a
Mark functions as private
2019-12-13 23:11:56 -05:00
toasted-nutbread
7addf5a2dd
Add API calls for optionsGetFull and optionsSave
2019-12-13 23:11:56 -05:00
toasted-nutbread
4177b63726
Remove redundant getUrl handlers
2019-12-13 23:11:56 -05:00
toasted-nutbread
573f83b65a
Update frontend API receiver handlers
2019-12-13 23:11:56 -05:00
toasted-nutbread
b7144ed879
Update display float key handlers
2019-12-13 23:11:56 -05:00
toasted-nutbread
a9c4ce724c
Update display key handlers
2019-12-13 23:11:56 -05:00
toasted-nutbread
7837e9f0e3
Update popup preview frame message handlers
2019-12-13 23:11:56 -05:00
toasted-nutbread
5588643988
Update float message handlers
2019-12-13 23:11:56 -05:00
toasted-nutbread
a2263e5729
Update display message handlers
2019-12-13 23:11:56 -05:00
toasted-nutbread
863e36e829
Update frontend message handlers
2019-12-13 23:11:56 -05:00
toasted-nutbread
e2c5c16da6
Update backend message handlers
2019-12-13 23:11:56 -05:00
toasted-nutbread
f287d68624
Add showContentCompleted for improved semantic clarity
2019-12-11 21:31:21 -05:00
toasted-nutbread
99867ebdd8
Fix text source issue
2019-12-11 21:27:42 -05:00
toasted-nutbread
7446c99f98
Fix Text-to-speech voice dropdown being reset
2019-12-11 21:15:51 -05:00
toasted-nutbread
47feb95842
Add timer class for debugging
2019-12-10 19:40:40 -05:00
siikamiika
2a19d8c59f
remove one more /fg/js/util.js
2019-12-09 19:43:35 +02:00
toasted-nutbread
2dad7f888b
Update how errors are reported when importing a dictionary
2019-12-08 16:01:29 -05:00
toasted-nutbread
0156869a3d
Optimize utilIsolate
2019-12-08 16:01:29 -05:00
toasted-nutbread
dbd9a54149
Use string.split instead of Array.from
2019-12-08 16:01:29 -05:00
toasted-nutbread
bb334acab6
Use substring instead of slice
2019-12-08 16:01:29 -05:00
toasted-nutbread
8ca44d722c
Prevent scripts from being injected multiple times
2019-12-08 16:01:29 -05:00
siikamiika
3c749f8705
hide inactive history buttons instead of fading
2019-12-08 22:59:36 +02:00
siikamiika
f23771d923
move term navigation to top right
2019-12-08 12:00:24 +02:00
siikamiika
b8fddd96c8
fix popup preview
...
resolves #302
2019-12-08 11:10:19 +02:00
toasted-nutbread
b862035fbc
Show info about whether a dictionary supports wildcard searches
2019-12-07 14:34:35 -05:00
toasted-nutbread
1a0a345ae7
Make reverse reading/expressions optional during database import
2019-12-07 14:34:35 -05:00
toasted-nutbread
1659340898
Add support for prefix wildcards
2019-12-07 14:34:35 -05:00
toasted-nutbread
7401408c39
Update input number attributes
2019-12-07 14:01:55 -05:00
toasted-nutbread
20679255b0
Add class for dispatching custom events
2019-12-07 13:59:47 -05:00
siikamiika
e99c8c40a1
navigate history with wheel only over buttons
2019-12-07 17:41:14 +02:00
siikamiika
df06251cb0
Merge pull request #299 from siikamiika/frontend-extract-text-scanner
...
Extract text scanner from Frontend
2019-12-07 15:20:28 +02:00
siikamiika
f6d0503604
simplify with inheritance
2019-12-06 21:39:29 +02:00
siikamiika
d1950bc5f1
use substring over slice for strings
2019-12-06 14:58:42 +02:00
siikamiika
a5a6351cce
revert search page title on empty query
2019-12-06 14:56:36 +02:00
toasted-nutbread
b418760a52
Simplify audio settings UI
2019-12-05 22:36:59 -05:00
63f3e94bb1
version bump
2019-12-05 18:24:54 -08:00
siikamiika
14c5857dfe
set title text on search page
2019-12-06 00:40:41 +02:00
siikamiika
595636c40b
move text selection to TextScanner
2019-12-05 22:48:05 +02:00
siikamiika
1bdef2e7c3
fix query parser
2019-12-05 22:19:40 +02:00
siikamiika
e5be42d3de
scan decoupling
2019-12-05 22:12:43 +02:00
siikamiika
02a34bb4bc
initial text scanner extract
2019-12-05 03:58:35 +02:00
siikamiika
248b0f15eb
remove references to /fg/js/util.js
...
It doesn't exist
2019-12-04 23:20:03 +02:00
siikamiika
d8935b6aa9
fix serialization errors on Chrome
2019-12-04 21:49:51 +02:00
3975aabf4d
version bump
2019-12-03 18:29:44 -08:00
Alex Yatskov
a24146538c
Merge pull request #291 from toasted-nutbread/cloze-fixes
...
Cloze fixes
2019-12-03 14:19:33 -08:00
toasted-nutbread
774db569eb
Simplify ankiGetFieldMarkersHtml
2019-12-02 22:19:55 -05:00
toasted-nutbread
5339381c30
Update how anki data is updated
2019-12-02 22:17:45 -05:00
toasted-nutbread
f89806e05d
Simplify how anki errors are shown
2019-12-01 22:26:23 -05:00
toasted-nutbread
093fa3a437
Group public/private functions together
2019-12-01 22:21:10 -05:00
toasted-nutbread
4f7fa8474d
Mark functions as private
2019-12-01 22:19:45 -05:00
toasted-nutbread
b4cdbf0263
Update how anki settings are updated
2019-12-01 22:16:58 -05:00
toasted-nutbread
3e1b080cd3
Simplify how anki templates are reset
2019-12-01 21:08:46 -05:00
toasted-nutbread
767a480a84
Organize main settings script
2019-12-01 17:02:01 -05:00
toasted-nutbread
a4de2d425a
Move popup preview settings into new script
2019-12-01 17:02:01 -05:00
toasted-nutbread
65e9d47743
Move storage settings into new script
2019-12-01 17:02:01 -05:00
toasted-nutbread
69ba665a4f
Move anki template settings into new script
2019-12-01 17:02:01 -05:00
toasted-nutbread
67990f4cb9
Move anki settings into new script
2019-12-01 16:19:15 -05:00
toasted-nutbread
3a517f0574
Move audio settings into new script
2019-12-01 16:19:15 -05:00
toasted-nutbread
ae94f84ffd
Move settings scripts
2019-12-01 16:19:12 -05:00
toasted-nutbread
a7e4901f72
Move PageExitPrevention to its own file
2019-12-01 15:19:21 -05:00
siikamiika
403b86675d
fix entry scroll index 0 bug
...
Introduced in 4e7d08ff2c
because the
range-limited index value isn't kept in the same scope.
2019-12-01 15:03:37 +02:00
siikamiika
a40f3b1c9f
add missing disableHistory
2019-12-01 06:32:17 +02:00
siikamiika
abe70e3b8c
always update current position on term lookup
2019-12-01 06:08:05 +02:00
siikamiika
5929018fac
move Display context to a new class
2019-12-01 05:38:23 +02:00
siikamiika
be23ad7213
remove dead code
2019-11-30 04:59:36 +02:00
siikamiika
ff9510356e
rewrite history as a doubly linked list
2019-11-30 04:49:37 +02:00
siikamiika
e3d96eb67d
fix yomichan menu on Firefox Android
2019-11-29 02:58:17 +02:00
siikamiika
8a94d186c3
fix context type inconsistencies
2019-11-29 01:36:14 +02:00
siikamiika
71a117c267
clear Display history on search page lookup
2019-11-28 23:52:15 +02:00
siikamiika
1dd88763de
clear Display history on new lookup
2019-11-28 18:24:24 +02:00
siikamiika
1f2734863f
Display history navigation buttons fixed position
2019-11-28 18:06:24 +02:00
siikamiika
2e04f752a5
fix clicking on query parser
2019-11-28 16:08:19 +02:00
siikamiika
f1ecb4cd39
correct X scroll direction for history navigation
2019-11-28 15:54:55 +02:00
siikamiika
86ff831600
preventDefault correctly
2019-11-28 15:24:00 +02:00
siikamiika
beea89a421
store popped context history in Display
2019-11-28 15:20:18 +02:00
siikamiika
4e7d08ff2c
set current entry even when disableScroll is true
2019-11-28 13:22:47 +02:00
siikamiika
e37ffb6cf5
fix scroll issues in Display.entryScrollIntoView
...
- Save scroll context before scrolling to top
- Explicit null check for scroll param to handle scrolling to y=0
correctly
2019-11-28 12:38:25 +02:00
toasted-nutbread
5a1046bc90
Update arrow-parens to always
2019-11-26 22:06:27 -05:00
toasted-nutbread
63a775ebca
Add missing semicolon
2019-11-26 22:06:27 -05:00
toasted-nutbread
df9e697fca
Remove trailing commas
2019-11-26 22:06:27 -05:00
toasted-nutbread
acb70f126c
Update unused arguments
2019-11-26 22:06:27 -05:00
toasted-nutbread
ef833d2bea
Use const rather than let where possible
2019-11-26 22:06:27 -05:00
toasted-nutbread
527595f79b
Remove unnecessary escapes from regex literals
2019-11-26 22:06:27 -05:00
toasted-nutbread
1daed12290
Comment empty blocks
2019-11-26 22:06:27 -05:00
toasted-nutbread
943350a1f6
Use single quotes
2019-11-26 22:06:27 -05:00
toasted-nutbread
0aed27b66d
Replace hasOwnProperty with simplified hasOwn function
2019-11-26 22:06:27 -05:00
toasted-nutbread
4110a848f5
Move additional utility functions to DOM
2019-11-26 18:59:52 -05:00
toasted-nutbread
96aad50340
Create DOM utility file
2019-11-26 18:59:52 -05:00
siikamiika
c2ff25b0ec
use fallback for ambiguous furigana
...
fixes #281 , fixes #94
2019-11-27 01:20:04 +02:00
toasted-nutbread
50604b25e6
Organize core.js
2019-11-26 17:38:05 -05:00
toasted-nutbread
099847729c
utilIsObject => isObject, move to core.js
2019-11-26 17:33:09 -05:00
toasted-nutbread
7e94fca7c7
Rename extension.js to core.js to better reflect its use
2019-11-26 17:29:52 -05:00
toasted-nutbread
a14b820a19
Move utilInvoke into api.js, rename to _apiInvoke
2019-11-26 17:23:55 -05:00
toasted-nutbread
d71bd056e8
Use consistent event handler notation
2019-11-26 17:18:17 -05:00
toasted-nutbread
7f9a73135d
Remove utilAsync
2019-11-26 17:18:17 -05:00
toasted-nutbread
0ebf676305
Update WanaKana to v4.0.2
...
Resolves #290
2019-11-26 12:46:41 -05:00
toasted-nutbread
3a7ef6c560
Simplify clozeBuild
2019-11-26 12:35:17 -05:00
toasted-nutbread
afddec66eb
Update cloze.body to use original sentence text
2019-11-26 12:35:17 -05:00
toasted-nutbread
befee9ceca
Pass kanji character to clozeBuild
2019-11-26 12:35:17 -05:00
toasted-nutbread
cb9f9b585a
Update how source terms are navigated
2019-11-26 12:31:20 -05:00
toasted-nutbread
c7cb1b3d9e
Require context for setContentTerms and setContentKanji
2019-11-26 12:31:17 -05:00
toasted-nutbread
cfa16ce675
Include sentence in context on search page
2019-11-26 11:34:06 -05:00
siikamiika
3423ed7d67
Merge pull request #279 from siikamiika/query-parser-1
...
Search page query parser
2019-11-26 18:31:35 +02:00
toasted-nutbread
820beb7c93
Fix incorrect opacity check
2019-11-25 21:04:34 -05:00
toasted-nutbread
9dc03f6d47
Remove wanakana reference from float.html
2019-11-25 13:34:56 -05:00
toasted-nutbread
91c54e1853
Remove JQuery from the context popup window
2019-11-24 11:46:29 -05:00
toasted-nutbread
10b33dbd20
Optimize toggle on the context popup window
...
Remove bootstrap-toggle dependency
2019-11-24 11:42:27 -05:00
toasted-nutbread
cf18e3b42e
Replace string.substr and string.slice with string.substring
...
Improves semantic clarity, and it's recommended to not use substr.
2019-11-24 11:02:52 -05:00
toasted-nutbread
eef05f6a64
Add accept type for dictionary import
2019-11-24 10:47:07 -05:00
siikamiika
89c6ef54b0
always return a promise from Mecab.invoke
2019-11-24 02:34:16 +02:00
siikamiika
43fad608fb
remove popup from background page
...
Not supported on all browsers
2019-11-23 19:25:11 +02:00
siikamiika
7bf2c8048d
add mecab version check
2019-11-23 19:18:29 +02:00
siikamiika
2577d4054e
fix scanning parser
2019-11-23 18:08:22 +02:00
siikamiika
cc8221c6ea
add reading modes
2019-11-23 17:50:46 +02:00
siikamiika
f625321650
refactor selected parser refreshing
2019-11-23 17:50:46 +02:00
siikamiika
933fd77957
remove async
2019-11-23 17:50:46 +02:00
siikamiika
707b039927
store local copy of selected parser
...
Options don't update early enough even after awaiting
2019-11-23 17:50:46 +02:00
siikamiika
0d6e0edc31
remove height hack and use overflow-y: scroll
2019-11-23 17:50:46 +02:00
siikamiika
f6f19dc9de
typo
2019-11-23 17:50:46 +02:00
siikamiika
9dff658640
add parser selection
2019-11-23 17:50:46 +02:00
siikamiika
84f30113e4
give names to complex slices
2019-11-23 17:50:46 +02:00
siikamiika
b02a30a2fd
explicit checks in while and if
2019-11-23 17:50:46 +02:00
siikamiika
1f2eee449e
mecab refactoring and bugfix
2019-11-23 17:50:46 +02:00
siikamiika
f97877a209
promise improvements
2019-11-23 17:50:46 +02:00
siikamiika
b336ab3a9a
use const
2019-11-23 17:49:25 +02:00
siikamiika
8d9a635d5c
remove dead code
2019-11-23 17:48:03 +02:00
siikamiika
c1d24208d3
start mecab only after enabling the setting
2019-11-23 17:45:44 +02:00
siikamiika
955e131f96
add parser selection options
2019-11-23 17:45:44 +02:00
siikamiika
1700318988
remove unneeded feature
...
Unidic actually has a field for the base form of the input
2019-11-23 17:45:44 +02:00
siikamiika
1bf48d24ef
change mecab path
...
https://github.com/siikamiika/yomichan-mecab-installer
2019-11-23 17:45:44 +02:00
siikamiika
515345ba0a
remove code duplication
2019-11-23 17:45:44 +02:00
siikamiika
b0c924d4bd
fix mecab variable
2019-11-23 17:45:44 +02:00
siikamiika
bc66f254ea
click & text selection improvements on search page
2019-11-23 17:45:44 +02:00
siikamiika
c78ca36f3d
switch to mousemove events in query parser
2019-11-23 17:45:44 +02:00
siikamiika
8825c481b5
respect text selection option in query parser
2019-11-23 17:45:44 +02:00
siikamiika
5a3e8c819c
optimize mouseover scanning in query parser
2019-11-23 17:45:44 +02:00
siikamiika
41020289ab
add mecab support
2019-11-23 17:45:44 +02:00
siikamiika
3881457e4e
use handlebars templates for query parser
2019-11-23 17:45:44 +02:00
siikamiika
e6a1b78164
use correct source text
2019-11-23 17:44:31 +02:00
siikamiika
408aa73cce
fix default params for term clicking
2019-11-23 17:43:30 +02:00
siikamiika
627e16d44b
improve text preview
2019-11-23 17:43:30 +02:00
siikamiika
530b95895b
remove unused css
2019-11-23 17:40:52 +02:00
siikamiika
d19f447b80
fix stem length checking
...
Starting from the end and stopping at first match doesn't guarantee
correctness. Starting from the beginning does.
2019-11-23 17:40:52 +02:00
siikamiika
c35a05cd62
add kana to text
2019-11-23 17:40:52 +02:00
toasted-nutbread
b4c6fa2d37
Improve usability of domain profile condition
2019-11-23 10:28:37 -05:00
siikamiika
f63e8e4be0
add simple query parser
2019-11-23 16:56:10 +02:00
toasted-nutbread
baf0325f62
Fix missing details
2019-11-18 21:55:06 -05:00
Alex Yatskov
b1659522b3
Merge pull request #274 from toasted-nutbread/lookup-wildcards
...
Lookup wildcards
2019-11-13 18:51:50 -08:00
siikamiika
7d9d45ae10
close popups on search page when query changes
2019-11-13 21:19:01 +02:00
siikamiika
29c38b06b2
only paste Japanese text from clipboard
2019-11-13 13:51:47 +02:00
toasted-nutbread
db4a303365
Fix dictionary settings not using the current profile
2019-11-12 20:13:25 -05:00
toasted-nutbread
72e7a42c8d
Fix settings not being saved correctly
2019-11-12 20:01:55 -05:00
toasted-nutbread
7333873244
Add support for wildcards
2019-11-10 14:02:43 -05:00
toasted-nutbread
3a225c3f91
Add details field to apiTermsFind
2019-11-10 14:02:43 -05:00
toasted-nutbread
7093d8f06e
Simplify how definition count is limited
2019-11-10 14:02:43 -05:00
toasted-nutbread
58c0997999
Give findKanji the same API as findTerms
2019-11-10 14:02:43 -05:00
toasted-nutbread
af1662acad
Update how apiTermsFind works
2019-11-10 14:02:43 -05:00
toasted-nutbread
ae10bb7096
Simplify dictTermsSort
2019-11-10 14:02:43 -05:00
toasted-nutbread
fe82913991
Rename function
2019-11-10 14:02:43 -05:00
toasted-nutbread
a9ab774a3f
Move function
2019-11-10 14:02:43 -05:00
toasted-nutbread
d9b4404075
Create functions for the cases of isMouseButton
...
jshint was showing a warning that there was no break statement
after the first case, which there doesn't need to be.
The most straightforward way to fix this without using the unclear
// jshint ignore:line
is to just have two functions.
This change also updates invocations of isMouseButton to use
the exact case function, as this will remove the need to check
the case of mosueEvent.type. This was done because onMouseMove
is invoked at a high frequency.
2019-11-10 14:00:44 -05:00
toasted-nutbread
dad685dba4
Fix overwriting const value
2019-11-10 13:56:06 -05:00
toasted-nutbread
d6cdd693c8
Fix several warnings about name conflicts
2019-11-10 13:55:37 -05:00
toasted-nutbread
157e6f7c75
Optimize DisplaySearch.onKeyDown
2019-11-10 13:40:48 -05:00
toasted-nutbread
120f97be26
Refactor apiOptionsSet
2019-11-10 13:36:35 -05:00
toasted-nutbread
aa92855b37
Fixes for Edge
2019-11-10 13:01:39 -05:00
toasted-nutbread
75883ed885
Remove dexie
2019-11-10 13:01:39 -05:00
toasted-nutbread
e48bfb8f1a
Use native indexedDB pointer
2019-11-10 13:01:39 -05:00
toasted-nutbread
183ec6b381
Use native IndexedDB to delete the database
2019-11-10 13:01:39 -05:00
toasted-nutbread
3a1e3392ed
Use native IndexedDB to create database and object stores
2019-11-10 13:01:39 -05:00
toasted-nutbread
6c023789d9
Use native IndexedDB for bulkAdd operations
2019-11-10 13:01:39 -05:00
toasted-nutbread
750439ebf0
Use native IndexedDB for database additions
2019-11-10 13:01:39 -05:00
toasted-nutbread
6f53030469
Use for of loop instead of forEach
2019-11-10 12:25:28 -05:00
sabs
fd17a0fccd
Remove Download check when resolving Audio data
...
There is a bug (seemingly unreported) in Yomichan where an Anki card
will not contain any audio if the JapanesePod101 audio source trumps
a secondary audio source (e.g. JapanesePod101-alternate) where
the jpod101 source can't find the word requested.
For example, そして has an audio entry in the alternate source but not
the standard source.
(Alternatively, there may be a bug in the jpod101 audioUrlBuilder,
because I've only noticed this problem with hiragana-only expressions.
JPod101 may not host those on the same url scheme any more. I'm not
sure how to fix that, though, and the bug I'm addressing here does
still persist).
The reason this happens is that audioGetFromUrl uses downloaded audio
to effectively check for a 404 (by examining the audio duration), but
that check doesn't happen when an Anki card is being created (i.e.
"download" is set, which I've changed to "willDownload" here).
This change removes that check, but retains the will-download intent
information to prevent attempts to download tts data, which AnkiConnect
cannot do. I've also added a short explanation as to why the download
check happens where it does.
I think the unused audio object will get garbage collected since it's
not referenced again, but I've explicitly unset it as well.
2019-11-09 20:58:09 -05:00
toasted-nutbread
3e864c44c3
Fixes for Edge
2019-11-09 20:52:16 -05:00
siikamiika
4ac4128388
search page checkbox styling
...
Change checkboxes to color-inverting icons
2019-11-10 03:15:55 +02:00
toasted-nutbread
184cc4cf28
Allow templates to be tested on the settings page
2019-11-09 16:34:39 -05:00
toasted-nutbread
085881d342
Use HTML templates for anki fields
2019-11-09 14:31:13 -05:00
siikamiika
40c8268fd6
always disable scanning IME checkbox label
2019-11-09 13:01:21 +02:00
siikamiika
cf0bb0a9e2
enable custom CSS on search page
2019-11-09 12:43:22 +02:00
siikamiika
177fad56b5
use scan toggling for stroke order diagram too
2019-11-09 12:28:12 +02:00
siikamiika
25af532ab7
enable expression scan toggling on search page
2019-11-09 12:27:09 +02:00
toasted-nutbread
b59a5b8cdb
Add support for some regex functions in handlebars templates
2019-11-08 22:57:20 -05:00
toasted-nutbread
4d7940e8e4
Optimize dictFieldFormat
2019-11-08 22:25:03 -05:00
toasted-nutbread
fa963722a7
Fix seekForward and seekBackward not handling length=0 case correctly
2019-11-08 19:24:33 -05:00
toasted-nutbread
b059609670
Add outdated warning
2019-11-07 20:30:55 -05:00
toasted-nutbread
cad0648cbe
Remove unused function
2019-11-07 20:30:55 -05:00
toasted-nutbread
f7700789fe
Update dictionary order based on priority
2019-11-07 20:30:55 -05:00
toasted-nutbread
fcb922400a
Prevent page exit while database operations are in progress
2019-11-07 20:30:55 -05:00
toasted-nutbread
e5dcb41824
Add support for importing multiple dictionaries at once
2019-11-07 20:30:55 -05:00
toasted-nutbread
e091c7ebe2
Add support for deleting individual dictionaries
2019-11-07 20:30:55 -05:00
toasted-nutbread
e355b83914
Update how nodes are hidden
2019-11-07 20:30:55 -05:00
toasted-nutbread
3d78d5400d
Add button and confirmation dialog for database purge
2019-11-07 20:30:55 -05:00
toasted-nutbread
2ab871e7ee
Update how dictionaries are displayed on the settings page
2019-11-07 20:30:55 -05:00
toasted-nutbread
79069d5908
Add functions for getting dictionary information
2019-11-07 20:30:55 -05:00
toasted-nutbread
44638b7ceb
Simplify how option visibility is changed
2019-11-07 20:30:55 -05:00
91c01e0a7e
Update version
2019-11-05 19:03:23 -08:00
toasted-nutbread
a85ec440d6
Fix overlapping popup timers
2019-11-05 19:48:08 -05:00
siikamiika
83460bcdad
refactoring and optimization
2019-11-04 02:15:33 +02:00
siikamiika
f4a987912a
prevent accidental lookup on glossary text select
2019-11-03 18:56:22 +02:00
toasted-nutbread
75ff05148d
Fix autoHideResults not working
2019-11-03 11:06:31 -05:00
toasted-nutbread
7de24dd355
Add favicons
2019-11-02 10:10:03 -04:00
toasted-nutbread
bcffe80a1e
Group similar functions together
2019-10-28 17:03:42 -04:00
toasted-nutbread
6d85dae68d
Fix some issues with the context menu
2019-10-28 17:03:42 -04:00
toasted-nutbread
d2644c0776
Style update
2019-10-28 17:03:42 -04:00
toasted-nutbread
c365101ec2
Reset preventions earlier
2019-10-28 17:03:42 -04:00
toasted-nutbread
e542f38110
Check pendingLookup earlier
2019-10-28 17:03:42 -04:00
toasted-nutbread
9703e123bf
Remove setPrimaryTouch
2019-10-28 17:03:42 -04:00
toasted-nutbread
80eb357527
Simplify touch event implementation
2019-10-28 17:03:42 -04:00
toasted-nutbread
131dc8397d
Make selectionContainsPoint static
2019-10-28 17:03:42 -04:00
toasted-nutbread
a648e05091
Improve naming
2019-10-28 17:03:42 -04:00
toasted-nutbread
9178636613
Remove setters
2019-10-28 17:03:42 -04:00
toasted-nutbread
c74c466c36
Remove unused variable
2019-10-28 17:03:42 -04:00
toasted-nutbread
f2dec4ca20
Remove searchFromTouch
2019-10-28 17:03:42 -04:00
toasted-nutbread
8c5240d7a6
Simplify how touch events use onAfterSearch
2019-10-28 17:03:42 -04:00
toasted-nutbread
e91bcf5f55
Rename textSourceLast to textSourceCurrent
2019-10-28 17:03:42 -04:00
toasted-nutbread
be27781c15
Update how definitions are searched for
2019-10-28 17:03:42 -04:00
toasted-nutbread
f927f806ba
Move check
2019-10-28 17:03:42 -04:00
toasted-nutbread
1f0a434e96
Remove unused vars
2019-10-28 17:03:42 -04:00
toasted-nutbread
dcb6f68826
Don't pass null textSource into searchSource
2019-10-28 17:03:42 -04:00
toasted-nutbread
185963899b
Use promiseTimeout
2019-10-28 17:03:42 -04:00
toasted-nutbread
d608657495
Move onError catch into searchAt
2019-10-28 17:03:42 -04:00
toasted-nutbread
1039536cfb
Create promise version of setTimeout
2019-10-28 17:03:42 -04:00
siikamiika
f6d3f739a8
improve search page checkbox usability
...
Disable text selection and make the entire area clickable, including
whitespace
2019-10-28 01:13:05 +02:00
siikamiika
a31ee0a0e9
refactoring
2019-10-28 00:09:36 +02:00
siikamiika
d62d04f806
fix wanakana toggle on empty input
2019-10-27 23:52:16 +02:00
siikamiika
68179607b3
use apiOptionsGet to modify the correct profile
2019-10-27 23:34:50 +02:00
siikamiika
9641747ba1
Revert "modify correct profile apiOptionsSet"
...
This reverts commit 51c35c9f30
.
2019-10-27 23:02:41 +02:00
siikamiika
51c35c9f30
modify correct profile apiOptionsSet
2019-10-27 22:43:20 +02:00
siikamiika
70418202cf
make search page checkbox options persist
2019-10-27 20:11:23 +02:00
siikamiika
48776145d6
add workaround to Chrome clipboard.readText
...
For some reason this doesn't work on Firefox, so keep using the new API
for Firefox
2019-10-27 15:46:27 +02:00
siikamiika
d3f51690f8
make clipboardRead an optional permission
2019-10-27 01:51:18 +03:00
siikamiika
7ee87265cd
refactor and tune wanakana toggling
2019-10-27 01:26:17 +03:00
siikamiika
01ffb052e6
simplify search history state handling
2019-10-26 19:32:41 +03:00
siikamiika
bbbd23c842
add button to enable/disable wanakana IME
2019-10-26 19:12:13 +03:00
siikamiika
303205dc12
keep url query in history
2019-10-26 18:42:57 +03:00
siikamiika
704864b7b2
add clipboard monitor to search page
...
Related to issue #262 about APIs
2019-10-26 18:15:28 +03:00
siikamiika
bebd70b4e2
remember search history
2019-10-26 16:39:43 +03:00
siikamiika
50769feea7
ignore more keys on search page
2019-10-26 15:15:12 +03:00
siikamiika
9132814ccf
focus and scroll to input only when it's needed
2019-10-26 14:30:36 +03:00
siikamiika
fe8eb76928
tweak ignored keys on search page
2019-10-26 03:39:08 +03:00
siikamiika
3a70346eb3
fix various unwanted focus issues on search page
...
Don't focus input if a modifier or specific keys are pressed
2019-10-26 03:26:24 +03:00
siikamiika
a716a52cab
make non-hotkey keys focus input on search page
...
The issue was that scanning on search page introduced a way to lose
focus of the query input, and the new feature that the search page
hotkey focuses an existing search page instead of opening a new one made
it more obvious.
Now every key that isn't a hotkey focuses the query input, and typing
text into the box scrolls it into view in case it wasn't there when
searching.
There is an accessibility issue that this can cause, because now tab
also focuses the query input before it focuses the next element. I
didn't implement a workaround for that because it would have been more
complicated than this simple fix.
Fixes #263
2019-10-26 01:26:56 +03:00
Danny
aeac7bf2a8
Proper spacing for Anki in {furigana-plain}
...
This should fix #264
Note it does not address broken segmentation, just representation
within Anki itself to work properly.
2019-10-23 07:46:43 -04:00
toasted-nutbread
7a3315d75d
Use chrome.runtime.getURL instead of chrome.extension.getURL
2019-10-22 20:23:03 -04:00
d32fd1381b
increment version for testing
2019-10-20 11:22:50 -07:00
Alex Yatskov
d8f9c2e1d4
Merge pull request #261 from toasted-nutbread/search-button-reuse-tab
...
Reuse open search tab when clicking search button
2019-10-20 11:06:23 -07:00
Alex Yatskov
6592323855
Merge pull request #259 from toasted-nutbread/database-optimizations2
...
Database optimizations part 2
2019-10-20 11:04:17 -07:00
toasted-nutbread
362a1ed9e4
Catch exception thrown on Edge
2019-10-20 10:58:22 -04:00
toasted-nutbread
d7dc8ac9cd
Add tooltip about middle click behaviour
2019-10-20 10:30:44 -04:00
toasted-nutbread
ce92591b63
Fix window focus not always working
2019-10-19 22:55:32 -04:00
toasted-nutbread
7abc7fd0e7
Use links instead of buttons on context page
2019-10-19 22:54:58 -04:00
toasted-nutbread
205498ef3b
Validate chrome.windows exists before usage
2019-10-19 22:45:29 -04:00
toasted-nutbread
ffb6ff9325
Allow multiple options pages to be opened on middle click
2019-10-19 22:34:47 -04:00
toasted-nutbread
d9ae34821c
Add support for middle clicks opening new tabs on the context buttons
2019-10-19 22:30:16 -04:00
toasted-nutbread
dbec4bffda
Make the search button reuse an open search tab if it exists
2019-10-19 22:28:23 -04:00
Alex Yatskov
03c72e9429
Merge pull request #256 from toasted-nutbread/unlimited-storage
...
Add unlimited storage permission
2019-10-19 12:01:54 -07:00
toasted-nutbread
eea95eb130
Simplify score to term frequency conversion
2019-10-19 14:18:57 -04:00
toasted-nutbread
96e4bf1735
Use native IndexedDB APIs for findTagForTitle
2019-10-19 13:41:18 -04:00
toasted-nutbread
610c2b9cca
Move tagCache out of Database and into Translator
2019-10-19 13:32:05 -04:00
toasted-nutbread
6f5fa6771b
Remove unused database functions
2019-10-19 12:44:23 -04:00
toasted-nutbread
97de7883a3
Update getMergedSecondarySearchResults to use findTermsExactBulk
2019-10-19 12:42:26 -04:00
toasted-nutbread
4446cbeabb
Create getMergedSecondarySearchResults
2019-10-19 12:28:33 -04:00
toasted-nutbread
96f37fd9dc
Create function for body of findTermsMerged's sequencedDefinitions loop
2019-10-19 12:16:38 -04:00
toasted-nutbread
a08cbebeb3
Use findTermsBySequenceBulk instead of findTermsBySequence
2019-10-19 11:34:12 -04:00