@ingcreators/annot-core 0.1.0
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/CHANGELOG.md +7 -0
- package/LICENSE +201 -0
- package/README.md +56 -0
- package/dist/auto-capture-options.d.ts +78 -0
- package/dist/editor/arrow-markers.d.ts +142 -0
- package/dist/editor/bake-translate.d.ts +192 -0
- package/dist/editor/font-registry.d.ts +58 -0
- package/dist/editor/gradient-utils.d.ts +23 -0
- package/dist/editor/history-core.d.ts +48 -0
- package/dist/editor/icons/brand-icons.d.ts +53 -0
- package/dist/editor/icons/material-symbols.d.ts +105 -0
- package/dist/editor/icons/registry.d.ts +179 -0
- package/dist/editor/icons/render.d.ts +22 -0
- package/dist/editor/icons/sanitize.d.ts +60 -0
- package/dist/editor/index.d.ts +13 -0
- package/dist/editor/path-utils.d.ts +32 -0
- package/dist/editor/property-schema.d.ts +263 -0
- package/dist/editor/rich-text-mapper.d.ts +8 -0
- package/dist/editor/selection-geometry.d.ts +66 -0
- package/dist/editor/shape-utils.d.ts +27 -0
- package/dist/editor/svg-format.d.ts +68 -0
- package/dist/editor/svg-id-utils.d.ts +37 -0
- package/dist/editor/svg-to-annotation-shapes.d.ts +34 -0
- package/dist/editor/text-utils.d.ts +212 -0
- package/dist/editor/tool-lifecycle.d.ts +56 -0
- package/dist/editor/tool-options.d.ts +126 -0
- package/dist/editor/tool-panel-adapter.d.ts +105 -0
- package/dist/editor/tool-preset-serde.d.ts +43 -0
- package/dist/editor/tool-registry.d.ts +320 -0
- package/dist/editor/tool-style-reader.d.ts +36 -0
- package/dist/editor/tool-style-writer.d.ts +33 -0
- package/dist/editor/toolbar-icons.d.ts +84 -0
- package/dist/editor/transform-utils.d.ts +127 -0
- package/dist/editor/viewport-math.d.ts +69 -0
- package/dist/encode/index.d.ts +4 -0
- package/dist/encode/options.d.ts +79 -0
- package/dist/encode/png8.d.ts +10 -0
- package/dist/headless.d.ts +29 -0
- package/dist/icons/index.d.ts +15 -0
- package/dist/icons/types.d.ts +108 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +3164 -0
- package/dist/storage/errors.d.ts +59 -0
- package/dist/storage/index.d.ts +6 -0
- package/dist/storage/metadata-cache.d.ts +231 -0
- package/dist/storage/path.d.ts +49 -0
- package/dist/storage/thumbnail-cache.d.ts +110 -0
- package/dist/storage/thumbnail.d.ts +31 -0
- package/dist/storage/types.d.ts +677 -0
- package/dist/utils/assert.d.ts +31 -0
- package/dist/utils/constants.d.ts +10 -0
- package/dist/utils/dash-utils.d.ts +6 -0
- package/dist/utils/desktop-bridge.d.ts +349 -0
- package/dist/utils/filename.d.ts +48 -0
- package/dist/utils/id.d.ts +21 -0
- package/dist/utils/index.d.ts +5 -0
- package/dist/utils/types.d.ts +20 -0
- package/dist/xmp/xmp-browser.d.ts +39 -0
- package/dist/zip/zip-builder.d.ts +8 -0
- package/dist/zip/zip-bytes.d.ts +22 -0
- package/package.json +58 -0
- package/styles/editor.css +1912 -0
- package/styles/fonts.css +46 -0
- package/styles/property-panel.css +779 -0
- package/styles/toolbar.css +673 -0
package/styles/fonts.css
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/* Logical font-family stacks — Phase 2 of
|
|
2
|
+
* `docs/plans/multilingual-fonts-os-stack.md`.
|
|
3
|
+
*
|
|
4
|
+
* Three logical tokens (`Annot Sans` / `Annot Serif` / `Annot Mono`)
|
|
5
|
+
* the editor stores in `data-font-family` (and on the inner `<text>`'s
|
|
6
|
+
* `font-family` attribute). The CSS rules below resolve each token to
|
|
7
|
+
* an OS-aware family stack interleaving Latin / CJK / Arabic / Indic /
|
|
8
|
+
* Thai families so the browser's per-codepoint font selection lands on
|
|
9
|
+
* the OS native script font without any web-font download.
|
|
10
|
+
*
|
|
11
|
+
* Stack order matters: Latin families come FIRST so English text in
|
|
12
|
+
* mixed content uses native Latin glyphs (Helvetica Neue, Segoe UI),
|
|
13
|
+
* and CJK families come second so Japanese / Chinese / Korean fall
|
|
14
|
+
* through to the OS native CJK font without dragging the Latin glyphs
|
|
15
|
+
* into a CJK Latin variant.
|
|
16
|
+
*
|
|
17
|
+
* Keep these stacks in sync with `cssStackFor` in
|
|
18
|
+
* `packages/core/src/editor/font-registry.ts` — the registry version
|
|
19
|
+
* is the single source of truth for code paths that need the stack as
|
|
20
|
+
* a string (PNG export inlines it into the SVG `<defs><style>`); this
|
|
21
|
+
* stylesheet ships the same stacks as static CSS for the live editor
|
|
22
|
+
* + gallery + thumbnail panes that just need a stylesheet import.
|
|
23
|
+
*/
|
|
24
|
+
|
|
25
|
+
text[font-family="Annot Sans"],
|
|
26
|
+
foreignObject [data-font-family="Annot Sans"] {
|
|
27
|
+
font-family:
|
|
28
|
+
-apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial,
|
|
29
|
+
"Hiragino Sans", "Yu Gothic UI", "Yu Gothic", Meiryo, "MS PGothic",
|
|
30
|
+
"PingFang SC", "Microsoft YaHei", "Apple SD Gothic Neo", "Malgun Gothic",
|
|
31
|
+
"Nirmala UI", Tahoma,
|
|
32
|
+
sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
text[font-family="Annot Serif"],
|
|
36
|
+
foreignObject [data-font-family="Annot Serif"] {
|
|
37
|
+
font-family:
|
|
38
|
+
Cambria, Georgia, "Yu Mincho", "Hiragino Mincho ProN", SimSun, "Noto Serif CJK SC", serif;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
text[font-family="Annot Mono"],
|
|
42
|
+
foreignObject [data-font-family="Annot Mono"] {
|
|
43
|
+
font-family:
|
|
44
|
+
"SF Mono", Menlo, Consolas, "Cascadia Mono", "Yu Gothic Mono", "Noto Sans Mono CJK JP",
|
|
45
|
+
monospace;
|
|
46
|
+
}
|