You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
93 lines
1.8 KiB
93 lines
1.8 KiB
|
4 months ago
|
"use strict";
|
||
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
||
|
|
exports.PRIMILTIVE_ATTRIBUTES = void 0;
|
||
|
|
exports.isPrimitiveAttribute = isPrimitiveAttribute;
|
||
|
|
exports.getPrimitiveAttributes = getPrimitiveAttributes;
|
||
|
|
exports.PRIMILTIVE_ATTRIBUTES = [
|
||
|
|
'$el',
|
||
|
|
'cx',
|
||
|
|
'cy',
|
||
|
|
'd',
|
||
|
|
'dx',
|
||
|
|
'dy',
|
||
|
|
'fill',
|
||
|
|
'fillOpacity',
|
||
|
|
'filter',
|
||
|
|
'fontFamily',
|
||
|
|
'fontSize',
|
||
|
|
'fontStyle',
|
||
|
|
'fontVariant',
|
||
|
|
'fontWeight',
|
||
|
|
'height',
|
||
|
|
'img',
|
||
|
|
'increasedLineWidthForHitTesting',
|
||
|
|
'innerHTML',
|
||
|
|
'isBillboard',
|
||
|
|
'billboardRotation',
|
||
|
|
'isSizeAttenuation',
|
||
|
|
'isClosed',
|
||
|
|
'isOverflowing',
|
||
|
|
'leading',
|
||
|
|
'letterSpacing',
|
||
|
|
'lineDash',
|
||
|
|
'lineHeight',
|
||
|
|
'lineWidth',
|
||
|
|
'markerEnd',
|
||
|
|
'markerEndOffset',
|
||
|
|
'markerMid',
|
||
|
|
'markerStart',
|
||
|
|
'markerStartOffset',
|
||
|
|
'maxLines',
|
||
|
|
'metrics',
|
||
|
|
'miterLimit',
|
||
|
|
'offsetX',
|
||
|
|
'offsetY',
|
||
|
|
'opacity',
|
||
|
|
'path',
|
||
|
|
'points',
|
||
|
|
'r',
|
||
|
|
'radius',
|
||
|
|
'rx',
|
||
|
|
'ry',
|
||
|
|
'shadowColor',
|
||
|
|
'src',
|
||
|
|
'stroke',
|
||
|
|
'strokeOpacity',
|
||
|
|
'text',
|
||
|
|
'textAlign',
|
||
|
|
'textBaseline',
|
||
|
|
'textDecorationColor',
|
||
|
|
'textDecorationLine',
|
||
|
|
'textDecorationStyle',
|
||
|
|
'textOverflow',
|
||
|
|
'textPath',
|
||
|
|
'textPathSide',
|
||
|
|
'textPathStartOffset',
|
||
|
|
'transform',
|
||
|
|
'transformOrigin',
|
||
|
|
'visibility',
|
||
|
|
'width',
|
||
|
|
'wordWrap',
|
||
|
|
'wordWrapWidth',
|
||
|
|
'x',
|
||
|
|
'x1',
|
||
|
|
'x2',
|
||
|
|
'y',
|
||
|
|
'y1',
|
||
|
|
'y2',
|
||
|
|
'z1',
|
||
|
|
'z2',
|
||
|
|
'zIndex',
|
||
|
|
];
|
||
|
|
function isPrimitiveAttribute(key) {
|
||
|
|
return exports.PRIMILTIVE_ATTRIBUTES.includes(key);
|
||
|
|
}
|
||
|
|
function getPrimitiveAttributes(attributes) {
|
||
|
|
var object = {};
|
||
|
|
for (var key in attributes) {
|
||
|
|
if (isPrimitiveAttribute(key))
|
||
|
|
object[key] = attributes[key];
|
||
|
|
}
|
||
|
|
return object;
|
||
|
|
}
|
||
|
|
//# sourceMappingURL=primitive.js.map
|