@perspective-dev/viewer-datagrid 4.3.0 → 4.4.1
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/cdn/perspective-viewer-datagrid.js +4 -22
- package/dist/cdn/perspective-viewer-datagrid.js.map +4 -4
- package/dist/css/perspective-viewer-datagrid-toolbar.css +1 -1
- package/dist/css/perspective-viewer-datagrid.css +1 -1
- package/dist/esm/color_utils.d.ts +22 -0
- package/dist/esm/custom_elements/datagrid.d.ts +5 -5
- package/dist/esm/data_listener/format_cell.d.ts +1 -1
- package/dist/esm/data_listener/formatter_cache.d.ts +1 -1
- package/dist/esm/data_listener/index.d.ts +3 -2
- package/dist/esm/event_handlers/click/edit_click.d.ts +3 -2
- package/dist/esm/event_handlers/click.d.ts +4 -6
- package/dist/esm/event_handlers/dispatch_click.d.ts +3 -2
- package/dist/esm/event_handlers/expand_collapse.d.ts +1 -1
- package/dist/esm/event_handlers/focus.d.ts +4 -5
- package/dist/esm/event_handlers/header_click.d.ts +5 -3
- package/dist/esm/event_handlers/keydown/edit_keydown.d.ts +3 -4
- package/dist/esm/event_handlers/select_region.d.ts +3 -1
- package/dist/esm/event_handlers/sort.d.ts +8 -7
- package/dist/esm/model/create.d.ts +1 -1
- package/dist/esm/perspective-viewer-datagrid.js +3 -3
- package/dist/esm/perspective-viewer-datagrid.js.map +4 -4
- package/dist/esm/plugin/activate.d.ts +1 -1
- package/dist/esm/plugin/column_style_controls.d.ts +1 -1
- package/dist/esm/style_handlers/body.d.ts +3 -3
- package/dist/esm/style_handlers/column_header.d.ts +4 -3
- package/dist/esm/style_handlers/consolidated.d.ts +3 -47
- package/dist/esm/style_handlers/editable.d.ts +3 -2
- package/dist/esm/style_handlers/focus.d.ts +4 -4
- package/dist/esm/style_handlers/group_header.d.ts +1 -1
- package/dist/esm/style_handlers/table_cell/boolean.d.ts +1 -1
- package/dist/esm/style_handlers/table_cell/cell_flash.d.ts +1 -1
- package/dist/esm/style_handlers/table_cell/datetime.d.ts +6 -2
- package/dist/esm/style_handlers/table_cell/numeric.d.ts +1 -1
- package/dist/esm/style_handlers/table_cell/row_header.d.ts +1 -1
- package/dist/esm/style_handlers/table_cell/string.d.ts +1 -1
- package/dist/esm/style_handlers/types.d.ts +0 -4
- package/dist/esm/types.d.ts +10 -17
- package/package.json +3 -5
- package/src/css/mitered-headers.css +64 -0
- package/src/css/perspective-viewer-datagrid.css +6 -0
- package/src/{less/pro.less → css/pro.css} +32 -31
- package/src/css/regular_table.css +589 -0
- package/src/{less/row-hover.less → css/row-hover.css} +48 -29
- package/src/{less/scrollbar.less → css/scrollbar.css} +16 -15
- package/src/{less/sub-cell-scroll.less → css/sub-cell-scroll.css} +14 -13
- package/src/{less/toolbar.less → css/toolbar.css} +57 -39
- package/src/ts/color_utils.ts +144 -16
- package/src/ts/custom_elements/datagrid.ts +11 -12
- package/src/ts/custom_elements/toolbar.ts +4 -5
- package/src/ts/data_listener/format_cell.ts +28 -9
- package/src/ts/data_listener/formatter_cache.ts +1 -1
- package/src/ts/data_listener/index.ts +4 -8
- package/src/ts/event_handlers/click/edit_click.ts +7 -6
- package/src/ts/event_handlers/click.ts +39 -68
- package/src/ts/event_handlers/dispatch_click.ts +24 -25
- package/src/ts/event_handlers/expand_collapse.ts +7 -7
- package/src/ts/event_handlers/focus.ts +38 -35
- package/src/ts/event_handlers/header_click.ts +101 -62
- package/src/ts/event_handlers/keydown/edit_keydown.ts +49 -52
- package/src/ts/event_handlers/select_region.ts +144 -133
- package/src/ts/event_handlers/sort.ts +16 -24
- package/src/ts/model/column_overrides.ts +13 -4
- package/src/ts/model/create.ts +55 -59
- package/src/ts/model/toolbar.ts +23 -7
- package/src/ts/plugin/activate.ts +120 -92
- package/src/ts/plugin/column_style_controls.ts +1 -1
- package/src/ts/plugin/save.ts +1 -0
- package/src/ts/style_handlers/body.ts +56 -61
- package/src/ts/style_handlers/column_header.ts +16 -19
- package/src/ts/style_handlers/consolidated.ts +22 -123
- package/src/ts/style_handlers/editable.ts +10 -8
- package/src/ts/style_handlers/focus.ts +5 -5
- package/src/ts/style_handlers/group_header.ts +3 -2
- package/src/ts/style_handlers/table_cell/boolean.ts +3 -3
- package/src/ts/style_handlers/table_cell/cell_flash.ts +11 -11
- package/src/ts/style_handlers/table_cell/datetime.ts +14 -11
- package/src/ts/style_handlers/table_cell/numeric.ts +24 -25
- package/src/ts/style_handlers/table_cell/row_header.ts +2 -2
- package/src/ts/style_handlers/table_cell/string.ts +20 -18
- package/src/ts/style_handlers/types.ts +0 -10
- package/src/ts/types.ts +28 -20
- package/dist/esm/event_handlers/deselect_all.d.ts +0 -5
- package/dist/esm/event_handlers/row_select_click.d.ts +0 -4
- package/src/less/mitered-headers.less +0 -65
- package/src/less/regular_table.less +0 -526
- package/src/ts/event_handlers/deselect_all.ts +0 -28
- package/src/ts/event_handlers/row_select_click.ts +0 -92
package/src/ts/types.ts
CHANGED
|
@@ -19,8 +19,12 @@ import type {
|
|
|
19
19
|
ViewWindow,
|
|
20
20
|
ViewConfigUpdate,
|
|
21
21
|
} from "@perspective-dev/client";
|
|
22
|
-
import {
|
|
23
|
-
|
|
22
|
+
import type {
|
|
23
|
+
HTMLPerspectiveViewerElement,
|
|
24
|
+
ViewerConfig,
|
|
25
|
+
} from "@perspective-dev/viewer";
|
|
26
|
+
import type { RegularTableElement } from "regular-table";
|
|
27
|
+
import type { CellMetadata, DataResponse } from "regular-table/dist/esm/types";
|
|
24
28
|
|
|
25
29
|
// Re-export types from regular-table for use throughout the codebase
|
|
26
30
|
export type { RegularTableElement as RegularTable };
|
|
@@ -46,7 +50,8 @@ export type EditMode =
|
|
|
46
50
|
| "EDIT"
|
|
47
51
|
| "SELECT_COLUMN"
|
|
48
52
|
| "SELECT_ROW"
|
|
49
|
-
| "SELECT_REGION"
|
|
53
|
+
| "SELECT_REGION"
|
|
54
|
+
| "SELECT_ROW_TREE";
|
|
50
55
|
|
|
51
56
|
// Color record for styling - tuple returned by make_color_record
|
|
52
57
|
export type ColorRecord = [
|
|
@@ -162,10 +167,11 @@ export interface DatagridModel {
|
|
|
162
167
|
_view: View;
|
|
163
168
|
_table: Table;
|
|
164
169
|
_table_schema: Schema;
|
|
165
|
-
_config:
|
|
170
|
+
_config: ViewerConfig;
|
|
166
171
|
_num_rows: number;
|
|
167
172
|
_num_columns?: number;
|
|
168
173
|
_schema: Schema;
|
|
174
|
+
_theme: string;
|
|
169
175
|
_ids: unknown[][];
|
|
170
176
|
_plugin_background: number[];
|
|
171
177
|
_color: ColorRecord;
|
|
@@ -177,6 +183,8 @@ export interface DatagridModel {
|
|
|
177
183
|
_column_types: ColumnType[];
|
|
178
184
|
_is_editable: boolean[];
|
|
179
185
|
_edit_mode: EditMode;
|
|
186
|
+
_tree_selection_id?: unknown[];
|
|
187
|
+
_last_insert_configs?: ViewConfigUpdate[];
|
|
180
188
|
_selection_state: SelectionState;
|
|
181
189
|
_row_header_types: ColumnType[];
|
|
182
190
|
_series_color_map: Map<string, Map<string, number>>;
|
|
@@ -212,19 +220,6 @@ export type DataListener = (
|
|
|
212
220
|
// Style listener function type
|
|
213
221
|
export type StyleListener = () => void;
|
|
214
222
|
|
|
215
|
-
// Perspective viewer element interface (subset)
|
|
216
|
-
export interface PerspectiveViewerElement extends HTMLElement {
|
|
217
|
-
getView(): Promise<View>;
|
|
218
|
-
getTable(): Promise<Table>;
|
|
219
|
-
getEditPort(): Promise<number>;
|
|
220
|
-
restore(config: Partial<ViewConfig>): Promise<void>;
|
|
221
|
-
toggleColumnSettings(columnName?: string): Promise<void>;
|
|
222
|
-
hasAttribute(name: string): boolean;
|
|
223
|
-
setSelection(viewport?: ViewWindow): void;
|
|
224
|
-
dispatchEvent(event: Event): boolean;
|
|
225
|
-
children: HTMLCollectionOf<HTMLElement>;
|
|
226
|
-
}
|
|
227
|
-
|
|
228
223
|
// Toolbar element interface
|
|
229
224
|
export interface DatagridToolbarElement extends HTMLElement {
|
|
230
225
|
setEditButton(button: HTMLElement): void;
|
|
@@ -255,7 +250,7 @@ export interface PerspectiveClickDetail {
|
|
|
255
250
|
config: Partial<ViewConfig>;
|
|
256
251
|
}
|
|
257
252
|
|
|
258
|
-
export { PerspectiveSelectDetail } from "@perspective-dev/viewer";
|
|
253
|
+
export { PerspectiveSelectDetail } from "@perspective-dev/viewer/src/ts/extensions.js";
|
|
259
254
|
|
|
260
255
|
// Mouse event with handled flag
|
|
261
256
|
export interface HandledMouseEvent extends MouseEvent {
|
|
@@ -281,9 +276,22 @@ export interface DatagridPluginElement extends HTMLElement {
|
|
|
281
276
|
_reset_column_size?: boolean;
|
|
282
277
|
}
|
|
283
278
|
|
|
284
|
-
// Map types for selected
|
|
285
|
-
export type SelectedRowsMap = WeakMap<RegularTableElement, Set<number>>;
|
|
279
|
+
// Map types for selected positions
|
|
286
280
|
export type SelectedPositionMap = WeakMap<
|
|
287
281
|
RegularTableElement,
|
|
288
282
|
SelectedPosition
|
|
289
283
|
>;
|
|
284
|
+
|
|
285
|
+
// Centralized editable mode check - used by style handlers and event handlers
|
|
286
|
+
export function isEditableMode(
|
|
287
|
+
model: DatagridModel,
|
|
288
|
+
viewer: HTMLPerspectiveViewerElement,
|
|
289
|
+
allowed: boolean = false,
|
|
290
|
+
): boolean {
|
|
291
|
+
const has_pivots =
|
|
292
|
+
model._config.group_by.length === 0 &&
|
|
293
|
+
model._config.split_by.length === 0;
|
|
294
|
+
const plugin = viewer.children[0] as DatagridPluginElement | undefined;
|
|
295
|
+
const editable = allowed || plugin?._edit_mode === "EDIT";
|
|
296
|
+
return has_pivots && editable;
|
|
297
|
+
}
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { RegularTableElement } from "regular-table";
|
|
2
|
-
import type { PerspectiveViewerElement } from "../types.js";
|
|
3
|
-
type SelectedRowsMap = Map<RegularTableElement, unknown[]>;
|
|
4
|
-
export declare function deselect_all_listener(regularTable: RegularTableElement, _viewer: PerspectiveViewerElement, selected_rows_map: SelectedRowsMap): Promise<void>;
|
|
5
|
-
export {};
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { type RegularTable, type DatagridModel, type PerspectiveViewerElement, type HandledMouseEvent } from "../types.js";
|
|
2
|
-
type SelectedRowsMap = Map<RegularTable, unknown[]>;
|
|
3
|
-
export declare function selectionListener(this: DatagridModel, regularTable: RegularTable, viewer: PerspectiveViewerElement, selected_rows_map: SelectedRowsMap, event: HandledMouseEvent): Promise<void>;
|
|
4
|
-
export {};
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
// ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
|
|
2
|
-
// ┃ ██████ ██████ ██████ █ █ █ █ █ █▄ ▀███ █ ┃
|
|
3
|
-
// ┃ ▄▄▄▄▄█ █▄▄▄▄▄ ▄▄▄▄▄█ ▀▀▀▀▀█▀▀▀▀▀ █ ▀▀▀▀▀█ ████████▌▐███ ███▄ ▀█ █ ▀▀▀▀▀ ┃
|
|
4
|
-
// ┃ █▀▀▀▀▀ █▀▀▀▀▀ █▀██▀▀ ▄▄▄▄▄ █ ▄▄▄▄▄█ ▄▄▄▄▄█ ████████▌▐███ █████▄ █ ▄▄▄▄▄ ┃
|
|
5
|
-
// ┃ █ ██████ █ ▀█▄ █ ██████ █ ███▌▐███ ███████▄ █ ┃
|
|
6
|
-
// ┣━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┫
|
|
7
|
-
// ┃ Copyright (c) 2017, the Perspective Authors. ┃
|
|
8
|
-
// ┃ ╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌ ┃
|
|
9
|
-
// ┃ This file is part of the Perspective library, distributed under the terms ┃
|
|
10
|
-
// ┃ of the [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0). ┃
|
|
11
|
-
// ┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛
|
|
12
|
-
|
|
13
|
-
.psp-header-border:not(.psp-is-top):not(.psp-header-leaf) {
|
|
14
|
-
// right
|
|
15
|
-
box-shadow: 1px 0px var(--inactive--border-color, #8b868045);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.psp-header-group {
|
|
19
|
-
// bottom
|
|
20
|
-
box-shadow: 0px 10px 0 -9px var(--inactive--border-color, #8b868045);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.psp-is-top {
|
|
24
|
-
// top-miter-right
|
|
25
|
-
box-shadow: 5px 4px 0px -4px var(--inactive--border-color, #8b868045);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.psp-is-top.psp-header-group:not(.psp-header-group-corner) {
|
|
29
|
-
// top-miter-right and bottom
|
|
30
|
-
box-shadow:
|
|
31
|
-
5px 4px 0px -4px var(--inactive--border-color, #8b868045),
|
|
32
|
-
0px 10px 0 -9px var(--inactive--border-color, #8b868045);
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.psp-header-border.psp-header-group {
|
|
36
|
-
&:not(.psp-is-top):not(.psp-header-group-corner) {
|
|
37
|
-
// right and bottom
|
|
38
|
-
box-shadow:
|
|
39
|
-
1px 0px var(--inactive--border-color, #8b868045),
|
|
40
|
-
0px 10px 0 -9px var(--inactive--border-color, #8b868045);
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
@mixin disabled-menu-funky-box-shadow {
|
|
45
|
-
tr.rt-autosize .psp-header-leaf.psp-header-border:not(.psp-menu-enabled) {
|
|
46
|
-
box-shadow: 1px 0px var(--inactive--border-color, #8b868045);
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
perspective-viewer[settings] {
|
|
51
|
-
@include disabled-menu-funky-box-shadow;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
:host-context(perspective-viewer[settings]) {
|
|
55
|
-
@include disabled-menu-funky-box-shadow;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
.psp-header-leaf.psp-header-border {
|
|
59
|
-
// bottom-miter-right
|
|
60
|
-
box-shadow: 5px -4px 0px -4px var(--inactive--border-color, #8b868045);
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
tr:only-child th {
|
|
64
|
-
box-shadow: none !important;
|
|
65
|
-
}
|
|
@@ -1,526 +0,0 @@
|
|
|
1
|
-
// ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
|
|
2
|
-
// ┃ ██████ ██████ ██████ █ █ █ █ █ █▄ ▀███ █ ┃
|
|
3
|
-
// ┃ ▄▄▄▄▄█ █▄▄▄▄▄ ▄▄▄▄▄█ ▀▀▀▀▀█▀▀▀▀▀ █ ▀▀▀▀▀█ ████████▌▐███ ███▄ ▀█ █ ▀▀▀▀▀ ┃
|
|
4
|
-
// ┃ █▀▀▀▀▀ █▀▀▀▀▀ █▀██▀▀ ▄▄▄▄▄ █ ▄▄▄▄▄█ ▄▄▄▄▄█ ████████▌▐███ █████▄ █ ▄▄▄▄▄ ┃
|
|
5
|
-
// ┃ █ ██████ █ ▀█▄ █ ██████ █ ███▌▐███ ███████▄ █ ┃
|
|
6
|
-
// ┣━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┫
|
|
7
|
-
// ┃ Copyright (c) 2017, the Perspective Authors. ┃
|
|
8
|
-
// ┃ ╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌ ┃
|
|
9
|
-
// ┃ This file is part of the Perspective library, distributed under the terms ┃
|
|
10
|
-
// ┃ of the [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0). ┃
|
|
11
|
-
// ┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛
|
|
12
|
-
|
|
13
|
-
@import "./pro.less";
|
|
14
|
-
@import "./mitered-headers.less";
|
|
15
|
-
@import "./row-hover.less";
|
|
16
|
-
@import "./sub-cell-scroll.less";
|
|
17
|
-
@import "./scrollbar.less";
|
|
18
|
-
|
|
19
|
-
// Row Selection
|
|
20
|
-
|
|
21
|
-
@mixin icon {
|
|
22
|
-
background-repeat: no-repeat;
|
|
23
|
-
background-color: var(--icon--color);
|
|
24
|
-
content: "";
|
|
25
|
-
display: inline-block;
|
|
26
|
-
-webkit-mask-size: cover;
|
|
27
|
-
mask-size: cover;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
// // TODO this makes the UI flash a CSS layout for a millsiecond when toggling
|
|
31
|
-
// // settings butit could be fixed.
|
|
32
|
-
|
|
33
|
-
// perspective-viewer:not([settings]) {
|
|
34
|
-
// @include settings-not-open;
|
|
35
|
-
// }
|
|
36
|
-
|
|
37
|
-
// :host-context(perspective-viewer:not([settings])) {
|
|
38
|
-
// @include settings-not-open;
|
|
39
|
-
// }
|
|
40
|
-
|
|
41
|
-
// @mixin settings-not-open {
|
|
42
|
-
// regular-table table tr.rt-autosize + tr th {
|
|
43
|
-
// height: 0px;
|
|
44
|
-
// span {
|
|
45
|
-
// display: none;
|
|
46
|
-
// }
|
|
47
|
-
// }
|
|
48
|
-
// }
|
|
49
|
-
|
|
50
|
-
@mixin settings-open {
|
|
51
|
-
.psp-menu-enabled {
|
|
52
|
-
padding: 0 6px;
|
|
53
|
-
font-size: 8px;
|
|
54
|
-
border-radius: 3px 3px 0 0;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
.psp-menu-enabled:hover,
|
|
58
|
-
tr:not(.rt-autosize) th.psp-menu-open {
|
|
59
|
-
color: var(--plugin--background);
|
|
60
|
-
background-color: var(--icon--color);
|
|
61
|
-
border-bottom-color: var(--icon--color);
|
|
62
|
-
cursor: pointer;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
tr:not(.rt-autosize) th.psp-menu-open {
|
|
66
|
-
&:before {
|
|
67
|
-
@include icon;
|
|
68
|
-
height: 8px;
|
|
69
|
-
width: 10px;
|
|
70
|
-
-webkit-mask-image: var(--column-settings-icon--mask-image);
|
|
71
|
-
mask-image: var(--column-settings-icon--mask-image);
|
|
72
|
-
margin-right: 4px;
|
|
73
|
-
background-color: var(--plugin--background);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
td.psp-menu-open {
|
|
78
|
-
box-shadow:
|
|
79
|
-
inset -2px 0px 0px var(--icon--color),
|
|
80
|
-
inset 2px 0px 0px var(--icon--color);
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
tr:first-child td.psp-menu-open {
|
|
84
|
-
border-top-color: var(--icon--color) !important;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
tr:last-child td.psp-menu-open {
|
|
88
|
-
box-shadow:
|
|
89
|
-
inset -2px 0px 0px var(--icon--color),
|
|
90
|
-
inset 2px 0px 0px var(--icon--color),
|
|
91
|
-
inset 0px -2px 0px var(--icon--color);
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
perspective-viewer {
|
|
96
|
-
@include settings-open;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
:host {
|
|
100
|
-
@include settings-open;
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
@mixin viewer-table-styles {
|
|
104
|
-
regular-table table thead tr:last-child th {
|
|
105
|
-
border-bottom-width: 1px;
|
|
106
|
-
border-bottom-color: var(--inactive--border-color, #8b868045);
|
|
107
|
-
}
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
perspective-viewer {
|
|
111
|
-
@include viewer-table-styles;
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
:host-context(perspective-viewer) {
|
|
115
|
-
@include viewer-table-styles;
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
.psp-sort-enabled:hover {
|
|
119
|
-
cursor: pointer;
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
.psp-row-selected,
|
|
123
|
-
:hover .psp-row-selected,
|
|
124
|
-
:hover th.psp-tree-leaf.psp-row-selected,
|
|
125
|
-
:hover th.psp-tree-label.psp-row-selected {
|
|
126
|
-
color: white !important;
|
|
127
|
-
background-color: var(--selected-row--background-color, #ea7319) !important;
|
|
128
|
-
border-color: var(--selected-row--background-color, #ea7319) !important;
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
regular-table.flat-group-rollup-mode.vertical-row-headers
|
|
132
|
-
th.psp-tree-label:not(:last-of-type) {
|
|
133
|
-
writing-mode: vertical-lr;
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
.psp-row-selected.psp-tree-label:not(:hover):before {
|
|
137
|
-
color: white;
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
regular-table:not(.flat-group-rollup-mode)
|
|
141
|
-
.psp-row-selected.psp-tree-label:not(:hover):before {
|
|
142
|
-
color: white;
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
.psp-row-subselected,
|
|
146
|
-
:hover .psp-row-subselected,
|
|
147
|
-
:hover th.psp-tree-leaf.psp-row-subselected,
|
|
148
|
-
:hover th.psp-tree-label.psp-row-subselected {
|
|
149
|
-
background: rgba(234, 115, 25, 0.2) !important;
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
.psp-error {
|
|
153
|
-
color: red;
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
td:focus {
|
|
157
|
-
outline: #666;
|
|
158
|
-
outline-style: dotted;
|
|
159
|
-
outline-width: 1px;
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
@mixin table-no-dragging {
|
|
163
|
-
regular-table {
|
|
164
|
-
pointer-events: none;
|
|
165
|
-
}
|
|
166
|
-
}
|
|
167
|
-
perspective-viewer.dragging {
|
|
168
|
-
@include table-no-dragging;
|
|
169
|
-
}
|
|
170
|
-
:host-context(perspective-viewer.dragging) {
|
|
171
|
-
@include table-no-dragging;
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
.psp-header-border:last-child {
|
|
175
|
-
border-right-width: 0px;
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
.psp-header-sort-desc:after {
|
|
179
|
-
@include icon;
|
|
180
|
-
width: 14px;
|
|
181
|
-
height: 11px;
|
|
182
|
-
margin-left: 4px;
|
|
183
|
-
-webkit-mask-image: var(--sort-desc-icon--mask-image);
|
|
184
|
-
mask-image: var(--sort-desc-icon--mask-image);
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
.psp-header-sort-asc:after {
|
|
188
|
-
@include icon;
|
|
189
|
-
width: 14px;
|
|
190
|
-
height: 11px;
|
|
191
|
-
margin-left: 4px;
|
|
192
|
-
-webkit-mask-image: var(--sort-asc-icon--mask-image);
|
|
193
|
-
mask-image: var(--sort-asc-icon--mask-image);
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
.psp-header-sort-col-desc:after {
|
|
197
|
-
@include icon;
|
|
198
|
-
width: 14px;
|
|
199
|
-
height: 11px;
|
|
200
|
-
margin-left: 4px;
|
|
201
|
-
-webkit-mask-image: var(--sort-col-desc-icon--mask-image);
|
|
202
|
-
mask-image: var(--sort-col-desc-icon--mask-image);
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
.psp-header-sort-col-asc:after {
|
|
206
|
-
@include icon;
|
|
207
|
-
width: 14px;
|
|
208
|
-
height: 11px;
|
|
209
|
-
margin-left: 4px;
|
|
210
|
-
-webkit-mask-image: var(--sort-col-asc-icon--mask-image);
|
|
211
|
-
mask-image: var(--sort-col-asc-icon--mask-image);
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
.psp-header-sort-abs-desc:after {
|
|
215
|
-
@include icon;
|
|
216
|
-
width: 14px;
|
|
217
|
-
height: 11px;
|
|
218
|
-
margin-left: 4px;
|
|
219
|
-
-webkit-mask-image: var(--sort-abs-desc-icon--mask-image);
|
|
220
|
-
mask-image: var(--sort-abs-desc-icon--mask-image);
|
|
221
|
-
}
|
|
222
|
-
|
|
223
|
-
.psp-header-sort-abs-asc:after {
|
|
224
|
-
@include icon;
|
|
225
|
-
width: 14px;
|
|
226
|
-
height: 11px;
|
|
227
|
-
margin-left: 4px;
|
|
228
|
-
-webkit-mask-image: var(--sort-abs-asc-icon--mask-image);
|
|
229
|
-
mask-image: var(--sort-abs-asc-icon--mask-image);
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
.psp-header-sort-abs-col-desc:after {
|
|
233
|
-
@include icon;
|
|
234
|
-
width: 14px;
|
|
235
|
-
height: 11px;
|
|
236
|
-
margin-left: 4px;
|
|
237
|
-
-webkit-mask-image: var(--sort-abs-col-desc-icon--mask-image);
|
|
238
|
-
mask-image: var(--sort-abs-col-desc-icon--mask-image);
|
|
239
|
-
}
|
|
240
|
-
|
|
241
|
-
.psp-header-sort-abs-col-asc:after {
|
|
242
|
-
@include icon;
|
|
243
|
-
width: 14px;
|
|
244
|
-
height: 11px;
|
|
245
|
-
margin-left: 4px;
|
|
246
|
-
-webkit-mask-image: var(--sort-abs-col-asc-icon--mask-image);
|
|
247
|
-
mask-image: var(--sort-abs-col-asc-icon--mask-image);
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
tbody th:last-of-type {
|
|
251
|
-
border-right: 1px solid var(--inactive--border-color, #8b868045);
|
|
252
|
-
overflow: hidden;
|
|
253
|
-
text-overflow: ellipsis;
|
|
254
|
-
}
|
|
255
|
-
tbody th:empty {
|
|
256
|
-
background-image: linear-gradient(
|
|
257
|
-
to right,
|
|
258
|
-
transparent 9px,
|
|
259
|
-
var(--inactive--border-color, #eee) 10px,
|
|
260
|
-
transparent 11px
|
|
261
|
-
);
|
|
262
|
-
background-repeat: no-repeat;
|
|
263
|
-
min-width: 20px;
|
|
264
|
-
max-width: 20px;
|
|
265
|
-
pointer-events: none;
|
|
266
|
-
}
|
|
267
|
-
|
|
268
|
-
regular-table:not(.flat-group-rollup-mode) {
|
|
269
|
-
.psp-tree-label {
|
|
270
|
-
max-width: 0px;
|
|
271
|
-
min-width: 0px;
|
|
272
|
-
}
|
|
273
|
-
|
|
274
|
-
.psp-tree-label:before {
|
|
275
|
-
color: var(--icon--color);
|
|
276
|
-
font-family: var(--button--font-family, inherit);
|
|
277
|
-
padding-right: 11px;
|
|
278
|
-
}
|
|
279
|
-
|
|
280
|
-
.psp-tree-label-expand:before {
|
|
281
|
-
content: var(--tree-label-expand--content, "+");
|
|
282
|
-
}
|
|
283
|
-
|
|
284
|
-
.psp-tree-label-collapse:before {
|
|
285
|
-
content: var(--tree-label-collapse--content, "-");
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
.psp-tree-label-expand,
|
|
289
|
-
.psp-tree-label-collapse {
|
|
290
|
-
cursor: pointer;
|
|
291
|
-
}
|
|
292
|
-
|
|
293
|
-
.psp-tree-label:hover:before {
|
|
294
|
-
color: var(--active--color);
|
|
295
|
-
text-shadow: 0px 0px 5px var(--active--color);
|
|
296
|
-
}
|
|
297
|
-
}
|
|
298
|
-
|
|
299
|
-
.psp-tree-leaf {
|
|
300
|
-
padding-left: 24px;
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
.psp-align-right {
|
|
304
|
-
text-align: right;
|
|
305
|
-
}
|
|
306
|
-
.psp-align-left {
|
|
307
|
-
text-align: left;
|
|
308
|
-
}
|
|
309
|
-
.psp-positive:not(:focus) {
|
|
310
|
-
color: var(--rt-pos-cell--color);
|
|
311
|
-
}
|
|
312
|
-
.psp-negative:not(:focus) {
|
|
313
|
-
color: var(--rt-neg-cell--color);
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
regular-table table tbody td {
|
|
317
|
-
min-width: 52px !important;
|
|
318
|
-
}
|
|
319
|
-
|
|
320
|
-
.psp-is-width-override .rt-column-resize,
|
|
321
|
-
.rt-column-resize:hover {
|
|
322
|
-
border: 1px dashed #999;
|
|
323
|
-
border-bottom-width: 0px;
|
|
324
|
-
border-left-width: 0px;
|
|
325
|
-
}
|
|
326
|
-
|
|
327
|
-
.boolean-editable {
|
|
328
|
-
cursor: pointer;
|
|
329
|
-
}
|
|
330
|
-
|
|
331
|
-
regular-table table {
|
|
332
|
-
user-select: none;
|
|
333
|
-
color: inherit;
|
|
334
|
-
border-collapse: separate;
|
|
335
|
-
|
|
336
|
-
th {
|
|
337
|
-
font-weight: 400;
|
|
338
|
-
}
|
|
339
|
-
|
|
340
|
-
td,
|
|
341
|
-
th {
|
|
342
|
-
border-color: var(--inactive--border-color, #8b868045);
|
|
343
|
-
height: 23px;
|
|
344
|
-
}
|
|
345
|
-
|
|
346
|
-
.psp-header-group {
|
|
347
|
-
text-overflow: ellipsis;
|
|
348
|
-
}
|
|
349
|
-
|
|
350
|
-
th.psp-header-leaf {
|
|
351
|
-
border-bottom-width: 0px;
|
|
352
|
-
span {
|
|
353
|
-
height: 23px;
|
|
354
|
-
min-height: 23px;
|
|
355
|
-
}
|
|
356
|
-
}
|
|
357
|
-
|
|
358
|
-
td,
|
|
359
|
-
th.psp-tree-label,
|
|
360
|
-
th.psp-tree-label,
|
|
361
|
-
th.psp-tree-leaf,
|
|
362
|
-
tbody tr:first-child th {
|
|
363
|
-
border-style: solid;
|
|
364
|
-
border-width: 0px;
|
|
365
|
-
border-top-width: 1px;
|
|
366
|
-
}
|
|
367
|
-
|
|
368
|
-
tbody th:empty {
|
|
369
|
-
background-position: 0px -10px;
|
|
370
|
-
}
|
|
371
|
-
|
|
372
|
-
td.psp-select-region,
|
|
373
|
-
th.psp-select-region {
|
|
374
|
-
// transition: background-color 0.5s, color 0.5s, border-color 0.5s;
|
|
375
|
-
background-color: var(--icon--color) !important;
|
|
376
|
-
color: var(--plugin--background) !important;
|
|
377
|
-
border-color: var(--plugin--background) !important;
|
|
378
|
-
}
|
|
379
|
-
}
|
|
380
|
-
|
|
381
|
-
regular-table
|
|
382
|
-
tbody
|
|
383
|
-
tr:hover
|
|
384
|
-
td.psp-select-region:not(.psp-row-selected):not(.psp-row-subselected),
|
|
385
|
-
regular-table
|
|
386
|
-
tbody
|
|
387
|
-
tr:hover
|
|
388
|
-
+ tr
|
|
389
|
-
td.psp-select-region:not(.psp-row-selected):not(.psp-row-subselected) {
|
|
390
|
-
border-color: var(--plugin--background) !important;
|
|
391
|
-
}
|
|
392
|
-
|
|
393
|
-
regular-table tbody tr:hover {
|
|
394
|
-
td.psp-select-region.psp-menu-open {
|
|
395
|
-
&:not(.psp-row-selected):not(.psp-row-subselected) {
|
|
396
|
-
box-shadow:
|
|
397
|
-
inset -2px 0px 0px var(--plugin--background),
|
|
398
|
-
inset 2px 0px 0px var(--plugin--background);
|
|
399
|
-
}
|
|
400
|
-
}
|
|
401
|
-
}
|
|
402
|
-
|
|
403
|
-
:host-context(perspective-viewer[settings]) td.psp-select-region.psp-menu-open {
|
|
404
|
-
box-shadow:
|
|
405
|
-
inset -2px 0px 0px var(--plugin--background),
|
|
406
|
-
inset 2px 0px 0px var(--plugin--background);
|
|
407
|
-
}
|
|
408
|
-
|
|
409
|
-
// This is a design/architecture bug. When the datagrid draws during a sidepanel
|
|
410
|
-
// collapse/uncollapse, the `settings` attribute is set to the _previous_ state
|
|
411
|
-
// as this collapse takes a while and we dont want the new state CSS to apply
|
|
412
|
-
// until the drawing is done. However, this causes the datagrid to draw its
|
|
413
|
-
// _first_ frame as if its in the wrong state, as it detects sidepanel state
|
|
414
|
-
// via HTML attribute checking.
|
|
415
|
-
@mixin design-slash-architecture-bug {
|
|
416
|
-
regular-table #psp-column-edit-buttons:after {
|
|
417
|
-
content: none;
|
|
418
|
-
}
|
|
419
|
-
}
|
|
420
|
-
|
|
421
|
-
regular-table
|
|
422
|
-
#psp-column-edit-buttons
|
|
423
|
-
th:not(.rt-group-corner)
|
|
424
|
-
span:not(.rt-column-resize):before {
|
|
425
|
-
content: var(--datagrid-column-edit-button--content, "Edit");
|
|
426
|
-
}
|
|
427
|
-
|
|
428
|
-
perspective-viewer:not([settings]) {
|
|
429
|
-
@include design-slash-architecture-bug;
|
|
430
|
-
}
|
|
431
|
-
|
|
432
|
-
:host-context(perspective-viewer:not([settings])) {
|
|
433
|
-
@include design-slash-architecture-bug;
|
|
434
|
-
}
|
|
435
|
-
|
|
436
|
-
// Style the last row of the `<thead>` so that is has a bottom border.
|
|
437
|
-
regular-table table thead tr:last-child:after {
|
|
438
|
-
width: 10000px;
|
|
439
|
-
box-sizing: border-box;
|
|
440
|
-
display: block;
|
|
441
|
-
height: 23px;
|
|
442
|
-
content: " ";
|
|
443
|
-
border-bottom: 1px solid var(--inactive--border-color);
|
|
444
|
-
}
|
|
445
|
-
|
|
446
|
-
// Extend every row to the right edge of the page with a fake column.
|
|
447
|
-
regular-table table tbody tr:after {
|
|
448
|
-
width: 10000px;
|
|
449
|
-
box-sizing: border-box;
|
|
450
|
-
display: block;
|
|
451
|
-
height: 23px;
|
|
452
|
-
content: " ";
|
|
453
|
-
border-top: 1px solid transparent;
|
|
454
|
-
}
|
|
455
|
-
|
|
456
|
-
regular-table table tbody tr:not(:first-child):after {
|
|
457
|
-
border-top: 1px solid var(--inactive--border-color);
|
|
458
|
-
}
|
|
459
|
-
|
|
460
|
-
regular-table table tbody tr:hover:not(:first-child):after {
|
|
461
|
-
border-top: 1px solid var(--rt-hover--border-color);
|
|
462
|
-
}
|
|
463
|
-
|
|
464
|
-
regular-table table tbody tr:hover + tr:after {
|
|
465
|
-
border-top: 1px solid var(--rt-hover--border-color);
|
|
466
|
-
}
|
|
467
|
-
|
|
468
|
-
@keyframes pulse_pos {
|
|
469
|
-
0% {
|
|
470
|
-
background-color: var(
|
|
471
|
-
--pulse--background-color-start,
|
|
472
|
-
rgba(0, 128, 255, 0.5)
|
|
473
|
-
);
|
|
474
|
-
}
|
|
475
|
-
100% {
|
|
476
|
-
background-color: var(
|
|
477
|
-
--pulse--background-color-end,
|
|
478
|
-
rgba(0, 128, 255, 0)
|
|
479
|
-
);
|
|
480
|
-
}
|
|
481
|
-
}
|
|
482
|
-
|
|
483
|
-
@keyframes pulse_pos2 {
|
|
484
|
-
0% {
|
|
485
|
-
background-color: var(
|
|
486
|
-
--pulse--background-color-start,
|
|
487
|
-
rgba(0, 128, 255, 0.5)
|
|
488
|
-
);
|
|
489
|
-
}
|
|
490
|
-
100% {
|
|
491
|
-
background-color: var(
|
|
492
|
-
--pulse--background-color-end,
|
|
493
|
-
rgba(0, 128, 255, 0)
|
|
494
|
-
);
|
|
495
|
-
}
|
|
496
|
-
}
|
|
497
|
-
|
|
498
|
-
@keyframes pulse_neg {
|
|
499
|
-
0% {
|
|
500
|
-
background-color: var(
|
|
501
|
-
--pulse--background-color-start,
|
|
502
|
-
rgba(255, 25, 0, 0.5)
|
|
503
|
-
);
|
|
504
|
-
}
|
|
505
|
-
100% {
|
|
506
|
-
background-color: var(
|
|
507
|
-
--pulse--background-color-end,
|
|
508
|
-
rgba(255, 25, 0, 0)
|
|
509
|
-
);
|
|
510
|
-
}
|
|
511
|
-
}
|
|
512
|
-
|
|
513
|
-
@keyframes pulse_neg2 {
|
|
514
|
-
0% {
|
|
515
|
-
background-color: var(
|
|
516
|
-
--pulse--background-color-start,
|
|
517
|
-
rgba(255, 25, 0, 0.5)
|
|
518
|
-
);
|
|
519
|
-
}
|
|
520
|
-
100% {
|
|
521
|
-
background-color: var(
|
|
522
|
-
--pulse--background-color-end,
|
|
523
|
-
rgba(255, 25, 0, 0)
|
|
524
|
-
);
|
|
525
|
-
}
|
|
526
|
-
}
|