overtype 2.0.3 → 2.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/overtype-webcomponent.esm.js +46 -6
- package/dist/overtype-webcomponent.esm.js.map +2 -2
- package/dist/overtype-webcomponent.js +46 -6
- package/dist/overtype-webcomponent.js.map +2 -2
- package/dist/overtype-webcomponent.min.js +13 -10
- package/dist/overtype.cjs +43 -6
- package/dist/overtype.cjs.map +2 -2
- package/dist/overtype.d.ts +25 -19
- package/dist/overtype.esm.js +43 -6
- package/dist/overtype.esm.js.map +2 -2
- package/dist/overtype.js +43 -6
- package/dist/overtype.js.map +2 -2
- package/dist/overtype.min.js +6 -3
- package/package.json +3 -2
- package/src/overtype-webcomponent.js +5 -1
- package/src/overtype.d.ts +25 -19
- package/src/overtype.js +10 -0
- package/src/styles.js +3 -0
- package/src/themes.js +17 -3
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* OverType v2.0.
|
|
2
|
+
* OverType v2.0.5
|
|
3
3
|
* A lightweight markdown editor library with perfect WYSIWYG alignment
|
|
4
4
|
* @license MIT
|
|
5
5
|
* @author David Miranda
|
|
@@ -1683,16 +1683,22 @@ ${blockSuffix}` : suffix;
|
|
|
1683
1683
|
// White - editor background
|
|
1684
1684
|
text: "#0d3b66",
|
|
1685
1685
|
// Yale Blue - main text
|
|
1686
|
+
textPrimary: "#0d3b66",
|
|
1687
|
+
// Yale Blue - primary text (same as text)
|
|
1688
|
+
textSecondary: "#5a7a9b",
|
|
1689
|
+
// Muted blue - secondary text
|
|
1686
1690
|
h1: "#f95738",
|
|
1687
1691
|
// Tomato - h1 headers
|
|
1688
1692
|
h2: "#ee964b",
|
|
1689
|
-
// Sandy Brown - h2 headers
|
|
1693
|
+
// Sandy Brown - h2 headers
|
|
1690
1694
|
h3: "#3d8a51",
|
|
1691
1695
|
// Forest green - h3 headers
|
|
1692
1696
|
strong: "#ee964b",
|
|
1693
1697
|
// Sandy Brown - bold text
|
|
1694
1698
|
em: "#f95738",
|
|
1695
1699
|
// Tomato - italic text
|
|
1700
|
+
del: "#ee964b",
|
|
1701
|
+
// Sandy Brown - deleted text (same as strong)
|
|
1696
1702
|
link: "#0d3b66",
|
|
1697
1703
|
// Yale Blue - links
|
|
1698
1704
|
code: "#0d3b66",
|
|
@@ -1705,17 +1711,25 @@ ${blockSuffix}` : suffix;
|
|
|
1705
1711
|
// Muted blue - horizontal rules
|
|
1706
1712
|
syntaxMarker: "rgba(13, 59, 102, 0.52)",
|
|
1707
1713
|
// Yale Blue with transparency
|
|
1714
|
+
syntax: "#999999",
|
|
1715
|
+
// Gray - syntax highlighting fallback
|
|
1708
1716
|
cursor: "#f95738",
|
|
1709
1717
|
// Tomato - cursor
|
|
1710
1718
|
selection: "rgba(244, 211, 94, 0.4)",
|
|
1711
1719
|
// Naples Yellow with transparency
|
|
1712
1720
|
listMarker: "#ee964b",
|
|
1713
1721
|
// Sandy Brown - list markers
|
|
1722
|
+
rawLine: "#5a7a9b",
|
|
1723
|
+
// Muted blue - raw line indicators
|
|
1724
|
+
border: "#e0e0e0",
|
|
1725
|
+
// Light gray - borders
|
|
1726
|
+
hoverBg: "#f0f0f0",
|
|
1727
|
+
// Very light gray - hover backgrounds
|
|
1728
|
+
primary: "#0d3b66",
|
|
1729
|
+
// Yale Blue - primary accent
|
|
1714
1730
|
// Toolbar colors
|
|
1715
1731
|
toolbarBg: "#ffffff",
|
|
1716
1732
|
// White - toolbar background
|
|
1717
|
-
toolbarBorder: "rgba(13, 59, 102, 0.15)",
|
|
1718
|
-
// Yale Blue border
|
|
1719
1733
|
toolbarIcon: "#0d3b66",
|
|
1720
1734
|
// Yale Blue - icon color
|
|
1721
1735
|
toolbarHover: "#f5f5f5",
|
|
@@ -1733,6 +1747,10 @@ ${blockSuffix}` : suffix;
|
|
|
1733
1747
|
// Darker charcoal - editor background
|
|
1734
1748
|
text: "#c5dde8",
|
|
1735
1749
|
// Light blue-gray - main text
|
|
1750
|
+
textPrimary: "#c5dde8",
|
|
1751
|
+
// Light blue-gray - primary text (same as text)
|
|
1752
|
+
textSecondary: "#9fcfec",
|
|
1753
|
+
// Brighter blue - secondary text
|
|
1736
1754
|
h1: "#d4a5ff",
|
|
1737
1755
|
// Rich lavender - h1 headers
|
|
1738
1756
|
h2: "#f6ae2d",
|
|
@@ -1743,6 +1761,8 @@ ${blockSuffix}` : suffix;
|
|
|
1743
1761
|
// Hunyadi Yellow - bold text
|
|
1744
1762
|
em: "#9fcfec",
|
|
1745
1763
|
// Brighter blue - italic text
|
|
1764
|
+
del: "#f6ae2d",
|
|
1765
|
+
// Hunyadi Yellow - deleted text (same as strong)
|
|
1746
1766
|
link: "#9fcfec",
|
|
1747
1767
|
// Brighter blue - links
|
|
1748
1768
|
code: "#c5dde8",
|
|
@@ -1755,17 +1775,25 @@ ${blockSuffix}` : suffix;
|
|
|
1755
1775
|
// Light blue-gray - horizontal rules
|
|
1756
1776
|
syntaxMarker: "rgba(159, 207, 236, 0.73)",
|
|
1757
1777
|
// Brighter blue semi-transparent
|
|
1778
|
+
syntax: "#7a8c98",
|
|
1779
|
+
// Muted gray-blue - syntax highlighting fallback
|
|
1758
1780
|
cursor: "#f26419",
|
|
1759
1781
|
// Orange Pantone - cursor
|
|
1760
1782
|
selection: "rgba(51, 101, 138, 0.4)",
|
|
1761
1783
|
// Lapis Lazuli with transparency
|
|
1762
1784
|
listMarker: "#f6ae2d",
|
|
1763
1785
|
// Hunyadi Yellow - list markers
|
|
1786
|
+
rawLine: "#9fcfec",
|
|
1787
|
+
// Brighter blue - raw line indicators
|
|
1788
|
+
border: "#2a3f52",
|
|
1789
|
+
// Dark blue-gray - borders
|
|
1790
|
+
hoverBg: "#243546",
|
|
1791
|
+
// Slightly lighter charcoal - hover backgrounds
|
|
1792
|
+
primary: "#9fcfec",
|
|
1793
|
+
// Brighter blue - primary accent
|
|
1764
1794
|
// Toolbar colors for dark theme
|
|
1765
1795
|
toolbarBg: "#1D2D3E",
|
|
1766
1796
|
// Darker charcoal - toolbar background
|
|
1767
|
-
toolbarBorder: "rgba(197, 221, 232, 0.1)",
|
|
1768
|
-
// Light blue-gray border
|
|
1769
1797
|
toolbarIcon: "#c5dde8",
|
|
1770
1798
|
// Light blue-gray - icon color
|
|
1771
1799
|
toolbarHover: "#243546",
|
|
@@ -2246,6 +2274,8 @@ ${blockSuffix}` : suffix;
|
|
|
2246
2274
|
font-size: 0.85rem !important;
|
|
2247
2275
|
color: #666 !important;
|
|
2248
2276
|
flex-shrink: 0 !important; /* Don't shrink */
|
|
2277
|
+
z-index: 10001 !important; /* Above link tooltip */
|
|
2278
|
+
position: relative !important; /* Enable z-index */
|
|
2249
2279
|
}
|
|
2250
2280
|
|
|
2251
2281
|
/* Dark theme stats bar */
|
|
@@ -2283,6 +2313,7 @@ ${blockSuffix}` : suffix;
|
|
|
2283
2313
|
gap: 4px !important;
|
|
2284
2314
|
padding: 8px !important; /* Override reset */
|
|
2285
2315
|
background: var(--toolbar-bg, var(--bg-primary, #f8f9fa)) !important; /* Override reset */
|
|
2316
|
+
border-bottom: 1px solid var(--toolbar-border, transparent) !important; /* Override reset */
|
|
2286
2317
|
overflow-x: auto !important; /* Allow horizontal scrolling */
|
|
2287
2318
|
overflow-y: hidden !important; /* Hide vertical overflow */
|
|
2288
2319
|
-webkit-overflow-scrolling: touch !important;
|
|
@@ -3356,6 +3387,12 @@ ${blockSuffix}` : suffix;
|
|
|
3356
3387
|
}
|
|
3357
3388
|
this.shortcuts = new ShortcutsManager(this);
|
|
3358
3389
|
this.linkTooltip = new LinkTooltip(this);
|
|
3390
|
+
requestAnimationFrame(() => {
|
|
3391
|
+
requestAnimationFrame(() => {
|
|
3392
|
+
this.textarea.scrollTop = this.preview.scrollTop;
|
|
3393
|
+
this.textarea.scrollLeft = this.preview.scrollLeft;
|
|
3394
|
+
});
|
|
3395
|
+
});
|
|
3359
3396
|
this.initialized = true;
|
|
3360
3397
|
if (this.options.onChange) {
|
|
3361
3398
|
this.options.onChange(this.getValue(), this);
|
|
@@ -4526,6 +4563,9 @@ ${blockSuffix}` : suffix;
|
|
|
4526
4563
|
break;
|
|
4527
4564
|
case "theme":
|
|
4528
4565
|
this._reinjectStyles();
|
|
4566
|
+
if (this._editor && this._editor.setTheme) {
|
|
4567
|
+
this._editor.setTheme(value || "solar");
|
|
4568
|
+
}
|
|
4529
4569
|
break;
|
|
4530
4570
|
case "placeholder":
|
|
4531
4571
|
if (this._editor.textarea) {
|