Commit 7d463ea
committed
fix(optimizer): include SD-card fonts in preflight modal; v4.1.1
The "Lock in reader settings?" dialog that fires before each EPUB
optimization hardcoded a 3-entry built-in font list (Lexend Deca /
Bitter / CharEink) and ignored SD-card fonts entirely. Users with a
custom .cpfont selected as their reader font (e.g. anyone who
installed the CharEink SD bundle from the 4.1.0 release page) hit
the modal and saw their actual selection missing from the dropdown.
Fix: showOptimizerPreflightModal now awaits /api/fonts before
building the dialog and appends each SD family as a "Name (SD)"
option with a string tag "sd:<family-name>" (built-ins use
"builtin:<index>" tags). The current selection picks the sd:* tag
when renderInfo.sdFontFamilyName is non-empty.
On save, the confirm handler routes:
- "sd:Name" -> sdFontFamilyName = "Name"
- "builtin:N" -> fontFamily = N, sdFontFamilyName = ""
handleSaveReaderSettings already accepts both fields, so the
server-side change is zero.
Will auto-deliver to v4.1.0 users via the OTA path wired in #22.1 parent d6d2d88 commit 7d463ea
3 files changed
Lines changed: 54 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
3 | 8 | | |
4 | 9 | | |
5 | 10 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
| 38 | + | |
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1872 | 1872 | | |
1873 | 1873 | | |
1874 | 1874 | | |
| 1875 | + | |
| 1876 | + | |
| 1877 | + | |
| 1878 | + | |
| 1879 | + | |
| 1880 | + | |
1875 | 1881 | | |
1876 | | - | |
1877 | | - | |
1878 | | - | |
| 1882 | + | |
| 1883 | + | |
| 1884 | + | |
1879 | 1885 | | |
| 1886 | + | |
| 1887 | + | |
| 1888 | + | |
| 1889 | + | |
| 1890 | + | |
| 1891 | + | |
| 1892 | + | |
| 1893 | + | |
| 1894 | + | |
| 1895 | + | |
| 1896 | + | |
| 1897 | + | |
| 1898 | + | |
| 1899 | + | |
| 1900 | + | |
| 1901 | + | |
| 1902 | + | |
1880 | 1903 | | |
1881 | 1904 | | |
1882 | 1905 | | |
| |||
1990 | 2013 | | |
1991 | 2014 | | |
1992 | 2015 | | |
1993 | | - | |
| 2016 | + | |
| 2017 | + | |
| 2018 | + | |
| 2019 | + | |
| 2020 | + | |
| 2021 | + | |
1994 | 2022 | | |
1995 | 2023 | | |
1996 | 2024 | | |
| |||
2036 | 2064 | | |
2037 | 2065 | | |
2038 | 2066 | | |
2039 | | - | |
2040 | | - | |
| 2067 | + | |
| 2068 | + | |
| 2069 | + | |
| 2070 | + | |
| 2071 | + | |
| 2072 | + | |
| 2073 | + | |
| 2074 | + | |
| 2075 | + | |
| 2076 | + | |
| 2077 | + | |
| 2078 | + | |
| 2079 | + | |
| 2080 | + | |
| 2081 | + | |
| 2082 | + | |
2041 | 2083 | | |
2042 | 2084 | | |
2043 | 2085 | | |
| |||
0 commit comments