@weasel-js/text 1.15.1 → 1.16.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/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { DEFAULT_TAB_SIZE, shapesWithFeature, resolveTextStyle, cachedLayoutRuns, graphemeCount, wrapLines, hangs, emboldenGlyph, layoutRuns, lineDecorations, runFaces, tabAdvance, widthWithTabs, DECORATION_KINDS, decorationRule, faceOutlineD, hasGlyphQuad } from './chunk-
|
|
2
|
-
export { BREAK_ALLOWED, BREAK_MANDATORY, DEFAULT_DECORATION_METRICS, DEFAULT_TEXT_FILL, DEFAULT_TEXT_STYLE, LAYOUT_CACHE_STRUCTURAL_LIMIT, LAYOUT_CACHE_VARIANT_LIMIT, NO_BREAK, QUAD_STRIDE, cachedLayoutRuns, cachedPaintRuns, clearRuns, decorationMetrics, dropRuns, emboldenGlyphD, fontString, isHardLineBreak, layoutRuns, lineBreakOpportunities, paintRuns, paragraphDirection, registerBidi, registerShaper, registeredBidi, resolveAlign, resolveTextStyle, resolveTextStyleInto, syntheticBoldOffset, warnRtlWithoutEngine } from './chunk-
|
|
1
|
+
import { DEFAULT_TAB_SIZE, shapesWithFeature, resolveTextStyle, cachedLayoutRuns, graphemeCount, wrapLines, hangs, emboldenGlyph, layoutRuns, lineDecorations, runFaces, tabAdvance, widthWithTabs, DECORATION_KINDS, decorationRule, faceOutlineD, hasGlyphQuad } from './chunk-VBLWNCSV.js';
|
|
2
|
+
export { BREAK_ALLOWED, BREAK_MANDATORY, DEFAULT_DECORATION_METRICS, DEFAULT_TEXT_FILL, DEFAULT_TEXT_STYLE, LAYOUT_CACHE_STRUCTURAL_LIMIT, LAYOUT_CACHE_VARIANT_LIMIT, NO_BREAK, QUAD_STRIDE, cachedLayoutRuns, cachedPaintRuns, clearRuns, decorationMetrics, dropRuns, emboldenGlyphD, fontString, isHardLineBreak, layoutRuns, lineBreakOpportunities, paintRuns, paragraphDirection, registerBidi, registerShaper, registeredBidi, resolveAlign, resolveTextStyle, resolveTextStyleInto, syntheticBoldOffset, warnRtlWithoutEngine } from './chunk-VBLWNCSV.js';
|
|
3
3
|
import { resolveScreenLength, paintKey, strokeKey } from '@weasel-js/paint';
|
|
4
4
|
import { faceMetricsOf, cachedFontVariant, loadFontOutlines, glyphGeneration, faceMetricsFor, outlineStatus, cssFamilyName } from '@weasel-js/font';
|
|
5
5
|
import { MIXED, deepEqual } from '@weasel-js/registry';
|
|
6
6
|
export { MIXED } from '@weasel-js/registry';
|
|
7
|
-
import { transformPath, joinPaths, pathFromD, pathSignedArea, reversePath, poseFrameOf, originFor, coordsFrom, PATH_M, PATH_L, PATH_Z } from '@weasel-js/geom';
|
|
7
|
+
import { transformPath, joinPaths, DEG_TO_RAD, pathFromD, pathSignedArea, reversePath, poseFrameOf, originFor, coordsFrom, PATH_M, PATH_L, PATH_Z } from '@weasel-js/geom';
|
|
8
8
|
|
|
9
9
|
// src/runs.ts
|
|
10
10
|
function toRuns(input) {
|
|
@@ -1108,11 +1108,9 @@ function effectiveRangeStyle(range, style, paint) {
|
|
|
1108
1108
|
|
|
1109
1109
|
// src/syntheticItalic.ts
|
|
1110
1110
|
var SYNTHETIC_ITALIC_RADIANS = 0.2094;
|
|
1111
|
-
|
|
1112
|
-
// src/glyphTurn.ts
|
|
1113
1111
|
function glyphTurn(rotate) {
|
|
1114
1112
|
if (!rotate) return UPRIGHT;
|
|
1115
|
-
const rad = rotate *
|
|
1113
|
+
const rad = rotate * DEG_TO_RAD;
|
|
1116
1114
|
return [Math.cos(rad), Math.sin(rad)];
|
|
1117
1115
|
}
|
|
1118
1116
|
var UPRIGHT = [1, 0];
|