thzxx
16464af0ae
docs: rewrite README.md and site/ for v0.2.0
...
- README.md: full API reference, syntax table, plugin/theme/i18n docs
- site/index.html: v0.2.0 hero, live demo, feature cards, API overview
- site/docs.html: sidebar nav, full config, instance API tables, parser reference
- site/demo.html: all-syntax demo with TS code samples
2026-07-24 22:42:42 +08:00
thzxx
e83fc211dc
feat: v0.2.0 — TypeScript full rewrite, 95%+ core coverage
...
BREAKING CHANGE: All source files converted from JavaScript to TypeScript.
- 12 .ts source files with strict types, full EditorOptions/Plugin/Token interfaces
- 7 .ts test files, 610 total tests (27 new), 7 suites all passing
- tsc --noEmit: 0 errors
- rollup-plugin-typescript build: 5 artifacts (UMD/ESM/CJS/Min/DTS)
- @babel/preset-typescript for jest
- New tsconfig.json, updated babel/jest/rollup configs
- Coverage: parser 99.5%, utils 95.7%, themes 96.2%, core 88.8%, plugins 89.5%
- Removed types/ folder (types now inline in .ts + auto-generated .d.ts)
- Desktop-only, no backward compatibility
2026-07-24 22:28:38 +08:00
thzxx
d7cae48073
feat(parser): v0.1.15 — parser short+medium term improvements
...
Short-term fixes:
- Fix ***bold italic*** / ___bold italic___ triple emphasis
- Fix link text inline formatting (recursive renderInline on [**bold**](url))
- Fix backtick inline code nesting (CommonMark-compliant extractInlineCodes)
- Fix tab indentation stripping in indented code blocks
Medium-term improvements:
- parseTokens() / renderTokens() separation API for token-level transform
- registerBlockHandler() table-driven block handler registry
- Backslash escape support (\* \_ \)
Also:
- Add 48 new test cases (583 total, 7 suites, all passing)
- Parser coverage: 95.43% stmts / 91.38% branches / 100% funcs / 98.25% lines
- Update README.md, site/, package.json to v0.1.15
2026-07-24 21:39:11 +08:00
thzxx
a70bfbf0cd
feat(site): add emoji favicon to demo, docs, index pages
...
- demo.html: 📝
- docs.html: 📖
- index.html: 🚀
2026-07-24 10:55:08 +08:00
thzxx
45ed8d5351
release: v0.1.6 — plugin v2, i18n instance isolation, shortcuts, toolbar, toast
...
feat(plugins): plugin system v2
- depends: declarative plugin dependencies with topological sort (Kahn algorithm)
- async plugins: install() returning Promise auto-await
- editor.unuse(name): uninstall individual plugins
- pluginUtils.validateConfig(schema, config): configuration validation
- plugin priority field controls install order within same dependency level
feat(i18n): instance-level locale isolation, pluralization, dynamic loading
- createInstanceI18n(): per-editor independent locale contexts
- editor.setLocale()/getLocale()/t() instance methods
- Plural rules: t('items', { count: 5 }) auto-selects one/other/few/many
- i18nUtils.loadRemote(url, locale): fetch translation packs from remote
- editor.on('localeChange') event
feat(core): toolbar & shortcut customization, context menu, toast
- editor.registerShortcut(combo, handler): custom keyboard shortcuts
- editor.configureToolbar(tools): dynamic toolbar rebuild
- editor.removeToolbarButton(action): remove single button
- editor.registerContextMenu(items): right-click context menu
- editor.toast(msg, {type, duration, animation}): toast notifications
style: toast notifications, context menu, dropdown CSS
- .me-toast with success/error/warning/info types, fade/slide animations
- .me-context-menu with items, separators, shortcut hints
test: 22 new tests covering plugin deps, unuse, shortcuts, toast, i18n plural (521 total)
chore: bump version 0.1.5 → 0.1.6 across all files, site, types
2026-07-24 10:17:57 +08:00
thzxx
d41da3c204
docs(site): update site pages for v0.1.5 theme features
...
- Update version references to 0.1.5 across demo/docs/index
- Add instance-level theme APIs to docs.html
- Add external theme following, theme inheritance docs
- Update index.html feature description
2026-07-24 09:57:11 +08:00
thzxx
f8b9f4a761
release: v0.1.4 — parser enhancement, new syntax, performance optimization
...
feat(parser): comprehensive Markdown parser enhancement
- Add nested list support (multi-level unordered/ordered, mixed nesting)
- Add Setext headings (=== / ---)
- Add indented code blocks (4-space indent)
- Add HTML comment passthrough (<!-- -->)
- Add entity reference protection (& ©)
- Add ordered list start attribute
- Add link title single-quote support
- Add LaTeX math formulas ($inline$ / $$block$$)
- Add footnote support ([^1] ref + [^1]: definition)
- Add definition lists (term\n: definition)
- Extend emoji map from 85 to 150+ common emojis
- Fix backtick code block matching (CommonMark spec)
- Fix italic regex character truncation (lookbehind assertions)
- Fix superscript/subscript/strikethrough ambiguity
- Fix blockquote prefix handling (>text without space)
- Enhance safeUrl filtering (additional protocol checks)
- Enhance slugify (Unicode NFKC normalization)
perf(parser): single-pass inline scanning, render cache, pre-compiled regex
- Replace 14-step chained regex with unified single-pass scanInline()
- Add cachedRenderInline() with FIFO LRU eviction (300-entry cap)
- Pre-compile 15+ static regex constants for block boundary detection
- Skip redundant style='text-align:left' on default-aligned table cells
style(parser): add CSS for footnotes, definition lists, math formulas, sup/sub
test(parser): 44 new test cases covering all v0.1.4 syntax additions (469 total)
chore: bump version 0.1.3 → 0.1.4 across all source files, docs, site pages
2026-07-24 09:35:51 +08:00
thzxx
71ddda1155
feat(site): add docs.html, update demo and index for v0.1.3
...
- docs.html: comprehensive single-page documentation with sidebar navigation
covering all APIs, config, events, plugins, themes, i18n, and syntax reference
- demo.html: add readOnly toggle, emoji/new syntax demo content,
imagePaste plugin, refresh API button, docs link
- index.html: add docs link to nav and footer
2026-07-23 21:08:12 +08:00
thzxx
e3142a17a8
feat(site): replace text 'M' logo with SVG icon
...
- Replace plain 'M' character with stylized SVG M monogram
- SVG uses the same white stroke-on-gradient style as before
- Add .logo .logo-mark style for hero section (32px, larger)
- Remove font-specific styles from logo-mark (now SVG-based)
- Add flex-shrink:0 to prevent icon squishing
2026-07-23 20:18:53 +08:00
thzxx
f080dcd1ff
fix(site): add white-space:pre-wrap to code block for proper line formatting
...
Root cause: .code-block was missing white-space:pre-wrap, causing all
newlines and indentation to collapse into a single line in the browser.
Also collapse open/close tags to avoid leading/trailing blank lines.
2026-07-23 20:16:56 +08:00
thzxx
86beddf63d
fix(site): format code block syntax highlighting and clarify logo mark
...
- Add .c-punc CSS class for punctuation coloring in code blocks
- Wrap all angle brackets, operators and delimiters in c-punc spans
- Add title/aria-label to logo-mark for accessibility and clarity
- Fix CDN path in code sample to match actual usage (../dist/...)
- Fix indentation consistency
2026-07-23 20:13:10 +08:00
thzxx
83357c3f22
docs: update npm package link to Gitea packages page
2026-07-23 18:04:31 +08:00
thzxx
22e867eda8
Initial commit: MetonaEditor v0.1.0
2026-07-23 16:23:07 +08:00