fontdue-js 2.6.0 → 2.7.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
CHANGED
|
@@ -26,13 +26,14 @@ export declare const makeConfig: (config?: Config) => {
|
|
|
26
26
|
groupEdit: boolean;
|
|
27
27
|
bulletStyle: "square" | "round";
|
|
28
28
|
openTypeFeatures: {
|
|
29
|
+
buttonLabel: string;
|
|
29
30
|
interactionStyle: "select" | "panel";
|
|
30
31
|
columns: {
|
|
31
32
|
features: (string | {
|
|
32
33
|
code: string;
|
|
33
34
|
name: string;
|
|
34
35
|
})[];
|
|
35
|
-
range
|
|
36
|
+
range: number;
|
|
36
37
|
}[] | undefined;
|
|
37
38
|
selectionStyle: "checkbox" | "bullet";
|
|
38
39
|
};
|
|
@@ -76,13 +77,14 @@ declare const _default: React.Context<{
|
|
|
76
77
|
groupEdit: boolean;
|
|
77
78
|
bulletStyle: "square" | "round";
|
|
78
79
|
openTypeFeatures: {
|
|
80
|
+
buttonLabel: string;
|
|
79
81
|
interactionStyle: "select" | "panel";
|
|
80
82
|
columns: {
|
|
81
83
|
features: (string | {
|
|
82
84
|
code: string;
|
|
83
85
|
name: string;
|
|
84
86
|
})[];
|
|
85
|
-
range
|
|
87
|
+
range: number;
|
|
86
88
|
}[] | undefined;
|
|
87
89
|
selectionStyle: "checkbox" | "bullet";
|
|
88
90
|
};
|
|
@@ -7,7 +7,7 @@ exports.makeConfig = exports.default = void 0;
|
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
9
9
|
const makeTypeTesterConfig = config => {
|
|
10
|
-
var _config$openTypeFeatu, _config$openTypeFeatu2, _config$openTypeFeatu3, _config$size, _config$size2, _config$size3, _config$lineHeight, _config$lineHeight2, _config$lineHeight3;
|
|
10
|
+
var _config$openTypeFeatu, _config$openTypeFeatu2, _config$openTypeFeatu3, _config$openTypeFeatu4, _config$size, _config$size2, _config$size3, _config$lineHeight, _config$lineHeight2, _config$lineHeight3;
|
|
11
11
|
let shy = (config === null || config === void 0 ? void 0 : config.shy) ?? false;
|
|
12
12
|
if (shy === true) shy = 'hover';
|
|
13
13
|
let toolsPosition = (config === null || config === void 0 ? void 0 : config.toolsPosition) ?? 'inline';
|
|
@@ -28,9 +28,10 @@ const makeTypeTesterConfig = config => {
|
|
|
28
28
|
groupEdit: (config === null || config === void 0 ? void 0 : config.groupEdit) ?? false,
|
|
29
29
|
bulletStyle: (config === null || config === void 0 ? void 0 : config.bulletStyle) ?? 'square',
|
|
30
30
|
openTypeFeatures: {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
31
|
+
buttonLabel: (config === null || config === void 0 ? void 0 : (_config$openTypeFeatu = config.openTypeFeatures) === null || _config$openTypeFeatu === void 0 ? void 0 : _config$openTypeFeatu.buttonLabel) ?? 'OT Features',
|
|
32
|
+
interactionStyle: (config === null || config === void 0 ? void 0 : (_config$openTypeFeatu2 = config.openTypeFeatures) === null || _config$openTypeFeatu2 === void 0 ? void 0 : _config$openTypeFeatu2.interactionStyle) ?? 'panel',
|
|
33
|
+
columns: config === null || config === void 0 ? void 0 : (_config$openTypeFeatu3 = config.openTypeFeatures) === null || _config$openTypeFeatu3 === void 0 ? void 0 : _config$openTypeFeatu3.columns,
|
|
34
|
+
selectionStyle: (config === null || config === void 0 ? void 0 : (_config$openTypeFeatu4 = config.openTypeFeatures) === null || _config$openTypeFeatu4 === void 0 ? void 0 : _config$openTypeFeatu4.selectionStyle) ?? 'bullet'
|
|
34
35
|
},
|
|
35
36
|
variableAxesPosition: (config === null || config === void 0 ? void 0 : config.variableAxesPosition) ?? 'auto',
|
|
36
37
|
alignmentButtons: (config === null || config === void 0 ? void 0 : config.alignmentButtons) ?? false,
|
|
@@ -52,7 +52,7 @@ const TypeTesterFeaturesButton = _ref => {
|
|
|
52
52
|
onClick: () => toggleFeaturesOpen()
|
|
53
53
|
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
54
54
|
className: "type-tester__features-button__text"
|
|
55
|
-
},
|
|
55
|
+
}, config.openTypeFeatures.buttonLabel), ' ', featuresOpen ? /*#__PURE__*/_react.default.createElement(_CarrotUp.default, null) : /*#__PURE__*/_react.default.createElement(_CarrotDown.default, null)));
|
|
56
56
|
}
|
|
57
57
|
if (config.openTypeFeatures.interactionStyle === 'select') {
|
|
58
58
|
if (!showFeatures || showFeatures.length === 0) return null;
|
|
@@ -21,13 +21,14 @@ export interface TypeTesterConfig {
|
|
|
21
21
|
priceText?: boolean;
|
|
22
22
|
autofitOnChange?: boolean;
|
|
23
23
|
openTypeFeatures?: {
|
|
24
|
-
|
|
24
|
+
buttonLabel?: string;
|
|
25
|
+
interactionStyle?: 'panel' | 'select';
|
|
25
26
|
columns?: {
|
|
26
27
|
features: ({
|
|
27
28
|
code: string;
|
|
28
29
|
name: string;
|
|
29
30
|
} | string)[];
|
|
30
|
-
range
|
|
31
|
+
range: number;
|
|
31
32
|
}[];
|
|
32
33
|
selectionStyle?: 'bullet' | 'checkbox';
|
|
33
34
|
};
|