UNPKG

kepler.gl

Version:

kepler.gl is a webgl based application to visualize large scale location data in the browser

366 lines (364 loc) 62.9 kB
"use strict"; var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); var _typeof = require("@babel/runtime/helpers/typeof"); Object.defineProperty(exports, "__esModule", { value: true }); exports.LayerColorLegendFactory = LayerColorLegendFactory; exports.LayerDefaultLegend = void 0; exports.LayerLegendContentFactory = LayerLegendContentFactory; exports.LayerLegendHeaderFactory = LayerLegendHeaderFactory; exports.LayerRadiusLegend = void 0; exports.SingleColorLegendFactory = SingleColorLegendFactory; exports["default"] = exports.VisualChannelMetric = exports.StyledMapControlLegend = void 0; var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty")); var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray")); var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray")); var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral")); var _react = _interopRequireWildcard(require("react")); var _styledComponents = _interopRequireDefault(require("styled-components")); var _d3Color = require("d3-color"); var _d3Format = require("d3-format"); var _reactIntl = require("react-intl"); var _colorLegend = _interopRequireWildcard(require("../common/color-legend")); var _radiusLegend = _interopRequireDefault(require("../common/radius-legend")); var _constants = require("@kepler.gl/constants"); var _localization = require("@kepler.gl/localization"); var _viewportMercatorProject = require("viewport-mercator-project"); var _icons = require("../common/icons"); var _panelHeaderAction = _interopRequireDefault(require("../side-panel/panel-header-action")); var _templateObject; // SPDX-License-Identifier: MIT // Copyright contributors to the kepler.gl project function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); } function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; } function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; } function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2["default"])(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } var StyledMapControlLegend = exports.StyledMapControlLegend = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n padding: 10px ", "px 10px\n ", "px;\n font-size: 11px;\n font-family: ", ";\n border-bottom-color: ", ";\n border-bottom-style: solid;\n border-bottom-width: ", ";\n width: ", "px;\n box-sizing: border-box;\n\n .legend--layer_name {\n font-size: 12px;\n padding-right: ", "px;\n color: ", ";\n font-weight: 500;\n }\n .legend--layer_type {\n color: ", ";\n font-weight: 500;\n font-size: 11px;\n padding-right: ", "px;\n }\n\n .legend--layer_size-title-row {\n display: flex;\n margin-top: 4px;\n padding-right: ", "px;\n align-items: center;\n }\n\n .legend--layer__title {\n }\n\n .legend--layer__item {\n padding-bottom: 4px;\n }\n .legend--layer_by {\n color: ", ";\n margin-top: 4px;\n }\n\n .legend--layer_color_field {\n color: ", ";\n font-weight: 500;\n }\n\n .legend--layer_color-legend {\n margin-top: 6px;\n }\n"])), function (props) { return props.theme.mapControl.padding; }, function (props) { return props.theme.mapControl.padding; }, function (props) { return props.theme.fontFamily; }, function (props) { return props.theme.panelBorderColor; }, function (props) { return props.last ? 0 : '1px'; }, function (props) { return props.width; }, function (props) { return props.theme.mapControl.padding; }, function (props) { return props.theme.textColor; }, function (props) { return props.theme.subtextColor; }, function (props) { return props.theme.mapControl.padding; }, function (props) { return props.theme.mapControl.padding; }, function (props) { return props.theme.subtextColor; }, function (props) { return props.theme.textColorHl; }); var VisualChannelMetric = exports.VisualChannelMetric = function VisualChannelMetric(_ref) { var name = _ref.name; return /*#__PURE__*/_react["default"].createElement("div", { className: "legend--layer__title" }, /*#__PURE__*/_react["default"].createElement("span", { className: "legend--layer_color_field" }, /*#__PURE__*/_react["default"].createElement(_localization.FormattedMessage, { id: name }))); }; var LayerDefaultLegend = exports.LayerDefaultLegend = function LayerDefaultLegend(_ref2) { var label = _ref2.label, name = _ref2.name; return label ? /*#__PURE__*/_react["default"].createElement("div", { className: "legend--layer_size-schema" }, /*#__PURE__*/_react["default"].createElement("p", null, /*#__PURE__*/_react["default"].createElement("span", { className: "legend--layer_by" }, label ? /*#__PURE__*/_react["default"].createElement(_localization.FormattedMessage, { id: label }) : null), /*#__PURE__*/_react["default"].createElement("span", { className: "legend--layer_by" }, " by ")), name && /*#__PURE__*/_react["default"].createElement(VisualChannelMetric, { name: name })) : null; }; SingleColorLegendFactory.deps = [_colorLegend.LegendRowFactory]; function SingleColorLegendFactory(LegendRow) { var SingleColorLegend = function SingleColorLegend(_ref3) { var color = _ref3.color, label = _ref3.label; return /*#__PURE__*/_react["default"].createElement(LegendRow, { label: label !== null && label !== void 0 ? label : '', displayLabel: Boolean(label), color: Array.isArray(color) ? _d3Color.rgb.apply(void 0, (0, _toConsumableArray2["default"])(color)).toString() : color }); }; SingleColorLegend.displayName = 'SingleColorLegend'; return /*#__PURE__*/_react["default"].memo(SingleColorLegend); } LayerColorLegendFactory.deps = [_colorLegend["default"], SingleColorLegendFactory, _panelHeaderAction["default"]]; function LayerColorLegendFactory(ColorLegend, SingleColorLegend, PanelHeaderAction) { var LayerColorLegend = function LayerColorLegend(_ref4) { var description = _ref4.description, config = _ref4.config, layer = _ref4.layer, colorChannel = _ref4.colorChannel, disableEdit = _ref4.disableEdit, onLayerVisConfigChange = _ref4.onLayerVisConfigChange, isExport = _ref4.isExport, mapState = _ref4.mapState, actionIcons = _ref4.actionIcons; var intl = (0, _reactIntl.useIntl)(); var enableColorBy = description.measure; var scale = colorChannel.scale, field = colorChannel.field, domain = colorChannel.domain, range = colorChannel.range, property = colorChannel.property, fixed = colorChannel.fixed; var _map = [scale, field, domain].map(function (k) { return config[k]; }), _map2 = (0, _slicedToArray2["default"])(_map, 3), colorScale = _map2[0], colorField = _map2[1], colorDomain = _map2[2]; var isFixed = fixed && config.visConfig[fixed]; var colorRange = config.visConfig[range]; var onUpdateColorLegend = (0, _react.useCallback)(function (colorLegends) { if (onLayerVisConfigChange) { onLayerVisConfigChange(layer, (0, _defineProperty2["default"])({}, range, _objectSpread(_objectSpread({}, colorRange), {}, { colorLegends: colorLegends }))); } }, [layer, onLayerVisConfigChange, colorRange, range]); var _useState = (0, _react.useState)(isExport), _useState2 = (0, _slicedToArray2["default"])(_useState, 2), isExpanded = _useState2[0], setIsExpanded = _useState2[1]; var handleToggleExpanded = function handleToggleExpanded() { return setIsExpanded(!isExpanded); }; return /*#__PURE__*/_react["default"].createElement("div", { className: "legend--layer__item" }, /*#__PURE__*/_react["default"].createElement("div", { className: "legend--layer_color-schema" }, /*#__PURE__*/_react["default"].createElement("div", null, enableColorBy ? /*#__PURE__*/_react["default"].createElement("div", { className: "legend--layer_size-title-row" }, /*#__PURE__*/_react["default"].createElement(VisualChannelMetric, { name: enableColorBy }), !isExport ? /*#__PURE__*/_react["default"].createElement(PanelHeaderAction, { id: "legend-collapse-button", onClick: handleToggleExpanded, IconComponent: isExpanded ? actionIcons.expanded : actionIcons.collapsed }) : null) : null, /*#__PURE__*/_react["default"].createElement("div", { className: "legend--layer_color-legend" }, enableColorBy ? /*#__PURE__*/_react["default"].createElement(ColorLegend, { layer: layer, isExpanded: isExpanded, scaleType: colorScale, displayLabel: true, domain: colorDomain, fieldType: colorField && colorField.type || 'real', range: colorRange, onUpdateColorLegend: onUpdateColorLegend, disableEdit: disableEdit, isFixed: isFixed, mapState: mapState, labelFormat: colorField !== null && colorField !== void 0 && colorField.displayFormat ? (0, _d3Format.format)(colorField === null || colorField === void 0 ? void 0 : colorField.displayFormat) : null }) : /*#__PURE__*/_react["default"].createElement(SingleColorLegend, { color: config.visConfig[property] || config[property] || config.color, label: intl.formatMessage({ id: "mapLegend.layers.".concat(layer.type, ".singleColor.").concat(colorChannel.key), defaultMessage: intl.formatMessage({ id: "mapLegend.layers.default.singleColor.".concat(colorChannel.key), defaultMessage: ' ' // mustn't be empty string or id will be used }) }) }))))); }; LayerColorLegend.displayName = 'LayerColorLegend'; return /*#__PURE__*/_react["default"].memo(LayerColorLegend); } function getLayerRadiusScaleMetersToPixelsMultiplier(layer, mapState) { // @ts-ignore this actually exist var _getDistanceScales = (0, _viewportMercatorProject.getDistanceScales)(mapState), metersPerPixel = _getDistanceScales.metersPerPixel; // if no field size is defined we need to pass fixed radius = false var fixedRadius = layer.config.visConfig.fixedRadius && Boolean(layer.config.sizeField); return layer.getRadiusScaleByZoom(mapState, fixedRadius) / metersPerPixel[0]; } var LayerRadiusLegend = exports.LayerRadiusLegend = /*#__PURE__*/_react["default"].memo(function (_ref5) { var layer = _ref5.layer, width = _ref5.width, visualChannel = _ref5.visualChannel, mapState = _ref5.mapState; var description = layer.getVisualChannelDescription(visualChannel.key); var config = layer.config; var enableSizeBy = description.measure; var scale = visualChannel.scale, field = visualChannel.field, domain = visualChannel.domain, range = visualChannel.range; var _map3 = [scale, field, domain].map(function (k) { return config[k]; }), _map4 = (0, _slicedToArray2["default"])(_map3, 3), sizeScale = _map4[0], sizeField = _map4[1], sizeDomain = _map4[2]; var sizeRange = config.visConfig[range]; if (mapState) { var radiusMultiplier = getLayerRadiusScaleMetersToPixelsMultiplier(layer, mapState); sizeRange = sizeRange.map(function (v) { return v * radiusMultiplier; }); } return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement("div", { className: "legend--layer_size-schema" }, /*#__PURE__*/_react["default"].createElement("div", null, enableSizeBy ? /*#__PURE__*/_react["default"].createElement(VisualChannelMetric, { name: enableSizeBy }) : null, /*#__PURE__*/_react["default"].createElement("div", { className: "legend--layer_size-legend" }, enableSizeBy ? /*#__PURE__*/_react["default"].createElement(_radiusLegend["default"], { scaleType: sizeScale, domain: sizeDomain, fieldType: sizeField && sizeField.type || 'real', range: sizeRange, width: width }) : null)))); }); var isColorChannel = function isColorChannel(visualChannel) { return [_constants.CHANNEL_SCALES.color, _constants.CHANNEL_SCALES.colorAggr].includes(visualChannel.channelScaleType); }; var isRadiusChannel = function isRadiusChannel(visualChannel) { return [_constants.CHANNEL_SCALES.radius].includes(visualChannel.channelScaleType); }; function LayerLegendHeaderFactory() { var LayerLegendHeader = function LayerLegendHeader(_ref6) { var options = _ref6.options, layer = _ref6.layer; return (options === null || options === void 0 ? void 0 : options.showLayerName) !== false ? /*#__PURE__*/_react["default"].createElement("div", { className: "legend--layer_name" }, layer.config.label) : null; }; return LayerLegendHeader; } var defaultActionIcons = { expanded: _icons.ArrowDown, collapsed: _icons.ArrowRight }; LayerLegendContentFactory.deps = [LayerColorLegendFactory]; function LayerLegendContentFactory(LayerColorLegend) { var LayerLegendContent = function LayerLegendContent(_ref7) { var layer = _ref7.layer, containerW = _ref7.containerW, mapState = _ref7.mapState, disableEdit = _ref7.disableEdit, isExport = _ref7.isExport, onLayerVisConfigChange = _ref7.onLayerVisConfigChange, actionIcons = _ref7.actionIcons; var visualChannels = layer.getLegendVisualChannels(); var channelKeys = Object.values(visualChannels); var colorChannels = channelKeys.filter(isColorChannel); var nonColorChannels = channelKeys.filter(function (vc) { return !isColorChannel(vc); }); var width = containerW - 2 * _constants.DIMENSIONS.mapControl.padding; // render color by chanel only var colorChannelToRender = colorChannels.filter(function (cc) { var _layer$getVisualChann; return (!cc.condition || cc.condition(layer.config)) && ((_layer$getVisualChann = layer.getVisualChannelDescription(cc.key)) === null || _layer$getVisualChann === void 0 ? void 0 : _layer$getVisualChann.measure); }); // if no color by chanel, render rest if (!colorChannelToRender.length) { colorChannelToRender = colorChannels.filter(function (cc) { return !cc.condition || cc.condition(layer.config); }); } return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, colorChannelToRender.map(function (colorChannel) { return /*#__PURE__*/_react["default"].createElement(LayerColorLegend, { key: colorChannel.key, colorChannel: colorChannel, config: layer.config, description: layer.getVisualChannelDescription(colorChannel.key), layer: layer, isExport: isExport, disableEdit: disableEdit, mapState: mapState, onLayerVisConfigChange: onLayerVisConfigChange, actionIcons: actionIcons }); }), nonColorChannels.map(function (visualChannel) { var matchCondition = !visualChannel.condition || visualChannel.condition(layer.config); var enabled = layer.config[visualChannel.field] || visualChannel.defaultMeasure; if (matchCondition && enabled) { var description = layer.getVisualChannelDescription(visualChannel.key); if (isRadiusChannel(visualChannel)) { return /*#__PURE__*/_react["default"].createElement(LayerRadiusLegend, { key: visualChannel.key, layer: layer, mapState: mapState, width: width, visualChannel: visualChannel }); } return /*#__PURE__*/_react["default"].createElement(LayerDefaultLegend, { key: visualChannel.key, label: description.label, name: description.measure }); } return null; })); }; return LayerLegendContent; } MapLegendFactory.deps = [LayerLegendHeaderFactory, LayerLegendContentFactory]; function MapLegendFactory(LayerLegendHeader, LayerLegendContent) { var MapLegend = function MapLegend(_ref8) { var _ref8$layers = _ref8.layers, layers = _ref8$layers === void 0 ? [] : _ref8$layers, width = _ref8.width, mapState = _ref8.mapState, options = _ref8.options, disableEdit = _ref8.disableEdit, isExport = _ref8.isExport, onLayerVisConfigChange = _ref8.onLayerVisConfigChange, _ref8$actionIcons = _ref8.actionIcons, actionIcons = _ref8$actionIcons === void 0 ? defaultActionIcons : _ref8$actionIcons; return /*#__PURE__*/_react["default"].createElement("div", { className: "map-legend" }, layers.map(function (layer, index) { if (!layer.isValidToSave() || layer.config.hidden) { return null; } var containerW = width || _constants.DIMENSIONS.mapControl.width; return /*#__PURE__*/_react["default"].createElement(StyledMapControlLegend, { className: "legend--layer", last: index === layers.length - 1, key: index, width: containerW }, /*#__PURE__*/_react["default"].createElement(LayerLegendHeader, { isExport: isExport, options: options, layer: layer }), /*#__PURE__*/_react["default"].createElement(LayerLegendContent, { containerW: containerW, layer: layer, mapState: mapState, disableEdit: disableEdit, isExport: isExport, onLayerVisConfigChange: onLayerVisConfigChange, actionIcons: actionIcons })); })); }; MapLegend.displayName = 'MapLegend'; return MapLegend; } var _default = exports["default"] = MapLegendFactory; //# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJuYW1lcyI6WyJfcmVhY3QiLCJfaW50ZXJvcFJlcXVpcmVXaWxkY2FyZCIsInJlcXVpcmUiLCJfc3R5bGVkQ29tcG9uZW50cyIsIl9pbnRlcm9wUmVxdWlyZURlZmF1bHQiLCJfZDNDb2xvciIsIl9kM0Zvcm1hdCIsIl9yZWFjdEludGwiLCJfY29sb3JMZWdlbmQiLCJfcmFkaXVzTGVnZW5kIiwiX2NvbnN0YW50cyIsIl9sb2NhbGl6YXRpb24iLCJfdmlld3BvcnRNZXJjYXRvclByb2plY3QiLCJfaWNvbnMiLCJfcGFuZWxIZWFkZXJBY3Rpb24iLCJfdGVtcGxhdGVPYmplY3QiLCJfZ2V0UmVxdWlyZVdpbGRjYXJkQ2FjaGUiLCJlIiwiV2Vha01hcCIsInIiLCJ0IiwiX19lc01vZHVsZSIsIl90eXBlb2YiLCJoYXMiLCJnZXQiLCJuIiwiX19wcm90b19fIiwiYSIsIk9iamVjdCIsImRlZmluZVByb3BlcnR5IiwiZ2V0T3duUHJvcGVydHlEZXNjcmlwdG9yIiwidSIsImhhc093blByb3BlcnR5IiwiY2FsbCIsImkiLCJzZXQiLCJvd25LZXlzIiwia2V5cyIsImdldE93blBy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Htwcm9wcyA9PiBwcm9wcy53aWR0aH1weDtcbiAgYm94LXNpemluZzogYm9yZGVyLWJveDtcblxuICAubGVnZW5kLS1sYXllcl9uYW1lIHtcbiAgICBmb250LXNpemU6IDEycHg7XG4gICAgcGFkZGluZy1yaWdodDogJHtwcm9wcyA9PiBwcm9wcy50aGVtZS5tYXBDb250cm9sLnBhZGRpbmd9cHg7XG4gICAgY29sb3I6ICR7cHJvcHMgPT4gcHJvcHMudGhlbWUudGV4dENvbG9yfTtcbiAgICBmb250LXdlaWdodDogNTAwO1xuICB9XG4gIC5sZWdlbmQtLWxheWVyX3R5cGUge1xuICAgIGNvbG9yOiAke3Byb3BzID0+IHByb3BzLnRoZW1lLnN1YnRleHRDb2xvcn07XG4gICAgZm9udC13ZWlnaHQ6IDUwMDtcbiAgICBmb250LXNpemU6IDExcHg7XG4gICAgcGFkZGluZy1yaWdodDogJHtwcm9wcyA9PiBwcm9wcy50aGVtZS5tYXBDb250cm9sLnBhZGRpbmd9cHg7XG4gIH1cblxuICAubGVnZW5kLS1sYXllcl9zaXplLXRpdGxlLXJvdyB7XG4gICAgZGlzcGxheTogZmxleDtcbiAgICBtYXJnaW4tdG9wOiA0cHg7XG4gICAgcGFkZGluZy1yaWdodDogJHtwcm9wcyA9PiBwcm9wcy50aGVtZS5tYXBDb250cm9sLnBhZGRpbmd9cHg7XG4gICAgYWxpZ24taXRlbXM6IGNlbnRlcjtcbiAgfVxuXG4gIC5sZWdlbmQtLWxheWVyX190aXRsZSB7XG4gIH1cblxuICAubGVnZW5kLS1sYXllcl9faXRlbSB7XG4gICAgcGFkZGluZy1ib3R0b206IDRweDtcbiAgfVxuICAubGVnZW5kLS1sYXllcl9ieSB7XG4gICAgY29sb3I6ICR7cHJvcHMgPT4gcHJvcHMudGhlbWUuc3VidGV4dENvbG9yfTtcbiAgICBtYXJnaW4tdG9wOiA0cHg7XG4gIH1cblxuICAubGVnZW5kLS1sYXllcl9jb2xvcl9maWVsZCB7XG4gICAgY29s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FeHBhbmRlZCk7XG4gICAgcmV0dXJuIChcbiAgICAgIDxkaXYgY2xhc3NOYW1lPVwibGVnZW5kLS1sYXllcl9faXRlbVwiPlxuICAgICAgICA8ZGl2IGNsYXNzTmFtZT1cImxlZ2VuZC0tbGF5ZXJfY29sb3Itc2NoZW1hXCI+XG4gICAgICAgICAgPGRpdj5cbiAgICAgICAgICAgIHtlbmFibGVDb2xvckJ5ID8gKFxuICAgICAgICAgICAgICA8ZGl2IGNsYXNzTmFtZT1cImxlZ2VuZC0tbGF5ZXJfc2l6ZS10aXRsZS1yb3dcIj5cbiAgICAgICAgICAgICAgICA8VmlzdWFsQ2hhbm5lbE1ldHJpYyBuYW1lPXtlbmFibGVDb2xvckJ5fSAvPlxuICAgICAgICAgICAgICAgIHshaXNFeHBvcnQgPyAoXG4gICAgICAgICAgICAgICAgICA8UGFuZWxIZWFkZXJBY3Rpb25cbiAgICAgICAgICAgICAgICAgICAgaWQ9XCJsZWdlbmQtY29sbGFwc2UtYnV0dG9uXCJcbiAgICAgICAgICAgICAgICAgICAgb25DbGljaz17aGFuZGxlVG9nZ2xlRXhwYW5kZWR9XG4gICAgICAgICAgICAgICAgICAgIEljb25Db21wb25lbnQ9e2lzRXhwYW5kZWQgPyBhY3Rpb25JY29ucy5leHBhbmRlZCA6IGFjdGlvbkljb25zLmNvbGxhcHNlZH1cbiAgICAgICAgICAgICAgICAgIC8+XG4gICAgICAgICAgICAgICAgKSA6IG51bGx9XG4gICAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICAgICAgKSA6IG51bGx9XG4gICAgICAgICAgICA8ZGl2IGNsYXNzTmFtZT1cImxlZ2VuZC0tbGF5ZXJfY29sb3ItbGVnZW5kXCI+XG4gICAgICAgICAgICAgIHtlbmFibGVDb2xvckJ5ID8gKFxuICAgICAgICAgICAgICAgIDxDb2xvckxlZ2VuZFxuICAgICAgICAgICAgICAgICAgbGF5ZXI9e2xheWVyfVxuICAgICAgICAgICAgICAgICAgaXNFeHBhbmRlZD17aXNFeHBhbmRlZH1cbiAgICAgICAgICAgICAgICAgIHNjYWxlVHlwZT17Y29sb3JTY2FsZX1cbiAgICAgICAgICAgICAgICAgIGRpc3BsYXlMYWJlbFxuICAgICAgICAgICAgICAgICAgZG9tYWluPXtjb2xvckRvbWFpbn1cbiAgICAgICAgICAgICAgICAgIGZpZWxkVHlwZT17KGNvbG9yRmllbGQgJiYgY29sb3JGaWVsZC50eXBlKSB8fCAncmVhbCd9XG4gICAgICAgICAgICAgICAgICByYW5nZT17Y29sb3JSYW5nZX1cbiAgICAgICAgICAgICAgICAgIG9uVXBkYXRlQ29sb3JMZWdlbmQ9e29uVXBkYXRlQ29sb3JMZWdlbmR9XG4gICAgICAgICAgICAgICAgICBkaXNhYmxlRWRpdD17ZGlzYWJsZUVkaXR9XG4gICAgICAgICAgICAgICAgICBpc0ZpeGVkPXtpc0ZpeGVkfVxuICAgICAgICAgICAgICAgICAgbWFwU3RhdGU9e21hcFN0YXRlfVxuICAgICAgICAgICAgICAgICAgbGFiZWxGb3JtYXQ9e1xuICAgICAgICAgICAgICAgICAgICBjb2xvckZpZWxkPy5kaXNwbGF5Rm9ybWF0ID8gZDNGb3JtYXQoY29sb3JGaWVsZD8uZGlzcGxheUZvcm1hdCkgOiBudWxsXG4gICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgLz5cbiAgICAgICAgICAgICAgKSA6IChcbiAgICAgICAgICAgICAgICA8U2luZ2xlQ29sb3JMZWdlbmRcbiAgICAgICAgICAgICAgICAgIGNvbG9yPXtjb25maWcudmlzQ29uZmlnW3Byb3BlcnR5XSB8fCBjb25maWdbcHJvcGVydHldIHx8IGNvbmZpZy5jb2xvcn1cbiAgICAgICAgICAgICAgICAgIGxhYmVsPXtpbnRsLmZvcm1hdE1lc3NhZ2Uoe1xuICAgICAgICAgICAgICAgICAgICBpZDogYG1hcExlZ2VuZC5sYXllcnMuJHtsYXllci50eXBlfS5zaW5nbGVDb2xvci4ke2NvbG9yQ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xldCBzaXplUmFuZ2UgPSBjb25maWcudmlzQ29uZmlnW3JhbmdlXTtcblxuICAgIGlmIChtYXBTdGF0ZSkge1xuICAgICAgY29uc3QgcmFkaXVzTXVsdGlwbGllciA9IGdldExheWVyUmFkaXVzU2NhbGVNZXRlcnNUb1BpeGVsc011bHRpcGxpZXIobGF5ZXIsIG1hcFN0YXRlKTtcbiAgICAgIHNpemVSYW5nZSA9IHNpemVSYW5nZS5tYXAodiA9PiB2ICogcmFkaXVzTXVsdGlwbGllcik7XG4gICAgfVxuXG4gICAgcmV0dXJuIChcbiAgICAgIDxkaXY+XG4gICAgICAgIDxkaXYgY2xhc3NOYW1lPVwibGVnZW5kLS1sYXllcl9zaXplLXNjaGVtYVwiPlxuICAgICAgICAgIDxkaXY+XG4gICAgICAgICAgICB7ZW5hYmxlU2l6ZUJ5ID8gPFZpc3VhbENoYW5uZWxNZXRyaWMgbmFtZT17ZW5hYmxlU2l6ZUJ5fSAvPiA6IG51bGx9XG4gICAgICAgICAgICA8ZGl2IGNsYXNzTmFtZT1cImxlZ2VuZC0tbGF5ZXJfc2l6ZS1sZWdlbmRcIj5cbiAgICAgICAgICAgICAge2VuYWJsZVNpemVCeSA/IChcbiAgICAgICAgICAgICAgICA8UmFkaXVzTGVnZW5kXG4gICAgICAgICAgICAgICAgICBzY2FsZVR5cGU9e3NpemVTY2FsZX1cbiAgICAgICAgICAgICAgICAgIGRvbWFpbj17c2l6ZURvbWFpbn1cbiAgICAgICAgICAgICAgICAgIGZpZWxkVHlwZT17KHNpemVGaWVsZCAmJiBzaXplRmllbGQudHlwZSkgfHwgJ3JlYWwnfVxuICAgICAgICAgICAgICAgICAgcmFuZ2U9e3NpemVSYW5nZX1cbiAgICAgICAgICAgICAgICAgIHdpZHRoPXt3aWR0aH1cbiAgICAgICAgICAgICAgICAvPlxuICAgICAgICAgICAgICApIDogbnVsbH1cbiAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICAgIDwvZGl2PlxuICAgICAgICA8L2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IDxMYXllclJhZGl1c0xlZ2VuZFxuICAgICAgICAgICAgICAgICAga2V5PXt2aXN1YWxDaGFubmVsLmtleX1cbiAgICAgICAgICAgICAgICAgIGxheWVyPXtsYXllcn1cbiAgICAgICAgICAgICAgICAgIG1hcFN0YXRlPXttYXBTdGF0ZX1cbiAgICAgICAgICAgICAgICAgIHdpZHRoPXt3aWR0aH1cbiAgICAgICAgICAgICAgICAgIHZpc3VhbENoYW5uZWw9e3Zpc3VhbENoYW5uZWx9XG4gICAgICAgICAgICAgICAgLz5cbiAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHJldHVybiAoXG4gICAgICAgICAgICAgIDxMYXllckRlZmF1bHRMZWdlbmRcbiAgICAgICAgICAgICAgICBrZXk9e3Zpc3VhbENoYW5uZWwua2V5fVxuICAgICAgICAgICAgICAgIGxhYmVsPXtkZXNjcmlwdGlvbi5sYWJlbH1cbiAgICAgICAgICAgICAgICBuYW1lPXtkZXNjcmlwdGlvbi5tZWFzdXJlfVxuICAgICAgICAgICAgICAvPlxuICAgICAgICAgICAgKTtcbiAgICAgICAgICB9XG4gICAgICAgICAgcmV0dXJuIG51bGw7XG4gICAgICAgIH0pfVxuICAgICAgPC8+XG4gICAgKTtcbiAgfTtcblxuICByZXR1cm4gTGF5ZXJMZWdlbmRDb250ZW50O1xufVxuXG5leHBvcnQgdHlwZSBNYXBMZWdlbmRQcm9wcyA9IHtcbiAgbGF5ZXJzPzogUmVhZG9ubHlBcnJheTxMYXllcj47XG4gIHdpZHRoPzogbnVtYmVyO1xuICBtYXBTdGF0ZT86IE1hcFN0YXRlO1xuICBvcHRpb25zPzoge1xuICAgIHNob3dMYXllck5hbWU/OiBib29sZWFuO1xuICB9O1xuICBkaXNhYmxlRWRpdD86IGJvb2xlYW47XG4gIGlzRXhwb3J0PzogYm9vbGVhbjtcbiAgb25MYXllclZpc0NvbmZpZ0NoYW5nZT86IChvbGRMYXllcjogTGF5ZXIsIG5ld1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