aboutsummaryrefslogtreecommitdiff
path: root/ext/js/templates
Commit message (Collapse)AuthorAge
* Dictionary deinflections (#503)StefanVukovic992024-01-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * wip * wip * fix v3 * wip * fix tests * fix maxitems * hide deinflection definitions * fix anki template * undo unnecessary change * delete console.log * refactor * add set false to handlebars * lint * fix tests * fix comments * fix * use Map in areArraysEqualIgnoreOrder * move inflection source icons to css * lint * improve naming * fix tests * add test * typescript * use for of * wip * comments * anki template upgrade * update descriptions
* type updates (#500)Cashew2024-01-13
| | | | | | | | | * type updates * remove comments * fix comment * remove types
* add phonetic transcriptions term meta type (#434)StefanVukovic992023-12-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * move dictionary files to dictionary folder * wip * move dictionary files to dictionary folder * add ipa term meta * wip * fixing comments wip * fixing comments wip * fixing comments wip * fixing comments wip * fixing comments wip * fixing comments wip * fix comments * fix comments * update test data * fix gitignore * engines * add tests * update database test * fix test
* Style updates (#447)Cashew2023-12-25
| | | | | | | | | | | | | * style updates * style updates * style updates * revert changes to dev/lib/handlebars * revert changes to dev/lib/handlebars * revert changes to dev/lib/handlebars
* Template helper function improvements (#439)toasted-nutbread2023-12-25
| | | | | * Flag fn and inverse as optional * Properly handle different modalities of helper functions
* move dictionary files to dictionary folder (#429)StefanVukovic992023-12-23
|
* Type safety for TemplateRendererProxy (#428)toasted-nutbread2023-12-23
| | | | | * Type safety for TemplateRendererProxy * Simplify
* rename variables (#409)Cashew2023-12-20
| | | | | | | | | | | * rename variables * add comment to ambiguous variable * rename variables * add comments * rename functions
* Simplify message handlers (#396)toasted-nutbread2023-12-20
|
* Make JSON.parse usage safer (#373)toasted-nutbread2023-12-19
| | | | | | | | | | | | | | | * Make JSON.parse usage safer * Fix any type * Add readResponseJson * Use readResponseJson * Additional updates * Rename files * Add types
* IIFE updates (#384)toasted-nutbread2023-12-19
| | | | | | | * Remove most IIFEs * Move IIFEs into functions * Don't await background-main
* Mock updates (#370)toasted-nutbread2023-12-18
| | | | | | | | | * Move DictionaryImporterMediaLoader mock * Move TemplateRendererProxy mock * Simplify mock * Remove ignore rule because it seems unused
* Update eslint spacing rules (#366)toasted-nutbread2023-12-17
| | | | | | | | | * Add space-infix-ops rule * Add no-multi-spaces --------- Co-authored-by: Darius Jahandarie <djahandarie@gmail.com>
* Fix bugtoasted-nutbread2023-11-29
|
* Update library typestoasted-nutbread2023-11-27
|
* Revert "Use import map"toasted-nutbread2023-11-27
|
* Use import maptoasted-nutbread2023-11-27
|
* Updatestoasted-nutbread2023-11-27
|
* Add extension error importstoasted-nutbread2023-11-27
|
* Remove unneeded referencestoasted-nutbread2023-11-27
|
* Add JSDoc type annotations to project (rebased)toasted-nutbread2023-11-27
|
* Fix hb import for media providerjbukl2023-11-09
|
* Switch to vitest for ESM support; other fixesDarius Jahandarie2023-11-08
|
* Modernize codebaseDarius Jahandarie2023-11-04
| | | | | | - Use ES modules - Remove vendored libs and build them from npm using esbuild - Switch from JSZip to zip.js
* remove kanjiLinks and sanitizeCssClasspraschke2023-10-17
|
* fix: regexReplace and regexMatchpraschke2023-10-17
| | | | | joining the args together without cutting out the options arg can add an '[object Object]' into the result.
* fix: formatGlossarypraschke2023-10-17
|
* fix: furigana and furiganaPlainpraschke2023-10-17
|
* fix: dumpObjectpraschke2023-10-17
|
* Fix lintAustin Siew2023-06-09
|
* Fix Handlebars not working on Firefox due to evalAustin Siew2023-06-09
|
* fixed eslint, changed header to only use 2 spaces, added missing headers to testAustin Siew2023-03-22
|
* Updated LICENSE to full license, added Yomitan 2023 to all license headersAustin Siew2023-03-21
|
* ESlint JSdoc (#2148)toasted-nutbread2022-05-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Install eslint-plugin-jsdoc * Initial rules setup * Update lists * Use @returns rather than @return * Remove error throwing code which is never executed * Fix issues relating to @throws * General error fixes * Update Display type documentation * Various doc fixes * Fix invalid tuple syntax * Doc updates * Remove unused * Doc updates * Enable jsdoc/require-returns * Update rules * Update remaining rules
* Structured content auto language (#2131)toasted-nutbread2022-05-14
| | | | | | | | | | | | | | | | | | | | | | * Pass JapaneseUtil instance to StructuredContentGenerator * Move body of createStructuredContent to an internal function * Create _createStructuredContentGenericElement * Wrap structured content in a <span> * Change _createStructuredContent to _appendStructuredContent * Add public appendStructuredContent function * Add missing return * Remove unused _createDocumentFragment * Automatically assign lang=ja for content with Japanese characters without an explicit language * Add test
* Structured content links (#2089)toasted-nutbread2022-03-17
| | | | | | | | | | | | | | | | | * Update CSS to JSON converter to generalize the remove-property comment * Fix navigation not being updated when _clearContent is run * Add structured content schema for link tags * Add test links * Add external-link icon * Pass Display instance to DisplayContentManager * Update structured content generation * Update link styles
* AnkiTemplateRendererContentManager (#2088)toasted-nutbread2022-03-14
| | | | | | | | | * Make function private * Update comments * Refactor the content manager that is provided to StructuredContentGenerator in AnkiTemplateRenderer * Update function to not be async, for API parity
* Update copyright date (#2062)toasted-nutbread2022-02-02
| | | | | | | * Update eslint settings * Update 2021 files * Update other files
* Katakana to hiragana conversion options (#1965)toasted-nutbread2021-09-27
| | | | | | | | | | | | | * Refactor convertKatakanaToHiragana * Add keepProlongedSoundMarks option * Test keepProlongedSoundMarks option * Refactor * Add keepProlongedSoundMarks option to hiragana handlebars helper * Update documentation
* Fix regexMatch and regexReplace handlebars helper functions (#1958)toasted-nutbread2021-09-26
|
* Anki template regex helper updates (#1934)toasted-nutbread2021-09-05
| | | | | * Update regexReplace and regexMatch to support content arguments * Update documentation
* Structured content data (#1930)toasted-nutbread2021-09-04
| | | | | | | | | | | * Add support for structured-content data attributes * Assign dataset properties * Don't remove data-sc attributes * Use helper functions * Update test data
* Hiragana & katakana helpers (#1908)toasted-nutbread2021-08-25
| | | | | | | * Add hiragana and katakana template helpers * Update documentation * Fix documentation
* Update de/serializeError functions to only serialize data if present (#1849)toasted-nutbread2021-07-25
|
* Pronunciation template helper (#1840)toasted-nutbread2021-07-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Rename field * Set up pronunication components * Fix documentation * Rename function * Update test dependencies * Fix constructor * Log errors * Add pronunciation helper * Add styleApplier argument to _getHtml/_normalizeHtml * Use getAttribute for 'class' to support namespaced elements (e.g. svg) * Update format name * Add optional tag * Update docs
* Anki template renderer abstraction (#1839)toasted-nutbread2021-07-18
| | | | | | | * Add AnkiTemplateRenderer abstraction * Move Anki-specific template functionality into AnkiTemplateRenderer * Add documentation comments
* Sandbox script folders (#1837)toasted-nutbread2021-07-17
| | | | | | | | | * Move scripts * Update paths * Fix ordering * Simplify eslint rules
* Fix case where "ready" message is received before frame "load" event (#1822)toasted-nutbread2021-07-10
|
* Simplify get media structure (#1817)toasted-nutbread2021-07-09
| | | | | * Remove format argument of getMedia * Implement escaping
* Anki text furigana parsing and {sentence-furigana} marker (#1814)toasted-nutbread2021-07-09
| | | | | | | | | | | | | * Add support for textFurigana media * Add readingMode parameter * Implement readingMode * Add {sentence-furigana} marker * Fallback to sentence if furigana isn't available * Update test data