mirror of
https://github.com/priyanshujain/margin-docs.git
synced 2026-10-02 11:07:05 +00:00
refactor changes
This commit is contained in:
1 parent
c1c47bc513
commit
f7a536b2c3
58 files changed
+2524
-320
No files matched your search
@@ -0,0 +1,14 @@
|
||||
// The machine's font book, for the half of the font picker this app does not ship.
|
||||
|
||||
import { call } from "../ipc";
|
||||
|
||||
/**
|
||||
* Every family installed on this machine, sorted and deduplicated by the backend.
|
||||
*
|
||||
* Answers with an empty list rather than rejecting when there is no backend to ask, because the
|
||||
* picker's bundled half works perfectly well without this one and an empty "System" group is the
|
||||
* honest way to say the machine was not asked. The list is worth caching in the caller: it walks
|
||||
* several directories on the Rust side and cannot change while the app is running.
|
||||
*/
|
||||
export const fontsListSystem = (): Promise<string[]> =>
|
||||
call<string[]>("fonts_list_system").catch(() => []);
|
||||
Reference in new issue
Block a user