UNPKG

1.6 kBJavaScriptView Raw
1/*
2 * Copyright 2021 Palantir Technologies, Inc. All rights reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16import { __assign, __rest } from "tslib";
17import classNames from "classnames";
18import * as React from "react";
19import { Classes } from "../../common";
20import { Dialog } from "../dialog/dialog";
21import { Hotkey } from "./hotkey";
22import { Hotkeys } from "./hotkeys";
23export var HotkeysDialog2 = function (_a) {
24 var _b = _a.globalGroupName, globalGroupName = _b === void 0 ? "Global" : _b, hotkeys = _a.hotkeys, props = __rest(_a, ["globalGroupName", "hotkeys"]);
25 return (React.createElement(Dialog, __assign({}, props, { className: classNames(Classes.HOTKEY_DIALOG, props.className) }),
26 React.createElement("div", { className: Classes.DIALOG_BODY },
27 React.createElement(Hotkeys, null, hotkeys.map(function (hotkey, index) { return (React.createElement(Hotkey, __assign({ key: index }, hotkey, { group: hotkey.global === true && hotkey.group == null ? globalGroupName : hotkey.group }))); })))));
28};
29//# sourceMappingURL=hotkeysDialog2.js.map
\No newline at end of file