@malloydata/malloy-explorer 0.0.266-dev250421232431 → 0.0.266-dev250425232629
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/@flowtypes/components/ResultPanel/SubmittedQuery.flow.js +4 -7
- package/@flowtypes/index.flow.js +3 -1
- package/dist/cjs/index.cjs +15146 -10922
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/esm/index.js +15149 -10925
- package/dist/esm/index.js.map +1 -1
- package/dist/malloy-explorer.css +23 -7
- package/dist/types/components/QueryPanel/AddMenu/AddFieldItem.d.ts +5 -4
- package/dist/types/components/QueryPanel/AddMenu/FieldList.d.ts +4 -3
- package/dist/types/components/QueryPanel/AddMenu/FieldMenu.d.ts +4 -3
- package/dist/types/components/QueryPanel/AddMenu/styles.d.ts +0 -1
- package/dist/types/components/QueryPanel/operations/AggregateOperations.d.ts +3 -2
- package/dist/types/components/QueryPanel/operations/GroupByOperations.d.ts +3 -2
- package/dist/types/components/QueryPanel/operations/NestOperation.d.ts +3 -1
- package/dist/types/components/QueryPanel/operations/RenameDialog.d.ts +10 -0
- package/dist/types/components/QueryPanel/operations/SortableOperations.d.ts +10 -0
- package/dist/types/components/ResultPanel/CopyToClipboard.d.ts +6 -0
- package/dist/types/components/ResultPanel/ResultDisplay.d.ts +1 -0
- package/dist/types/components/ResultPanel/RunInfoHover.d.ts +6 -0
- package/dist/types/components/ResultPanel/SubmittedQuery.d.ts +14 -7
- package/dist/types/components/filters/FilterDialog.d.ts +4 -4
- package/dist/types/components/filters/FilterPopover.d.ts +19 -0
- package/dist/types/components/filters/styles.d.ts +8 -7
- package/dist/types/components/primitives/DOMElement.d.ts +3 -1
- package/dist/types/components/primitives/DropdownMenu.d.ts +3 -1
- package/dist/types/components/primitives/HoverCard.d.ts +8 -0
- package/dist/types/components/primitives/tokens/Token.d.ts +7 -1
- package/dist/types/components/styles.d.ts +0 -1
- package/dist/types/components/utils/annotations.d.ts +1 -0
- package/dist/types/components/utils/fields.d.ts +2 -2
- package/dist/types/components/utils/segment.d.ts +4 -2
- package/dist/types/contexts/QueryEditorContext.d.ts +0 -2
- package/dist/types/index.d.ts +1 -1
- package/package.json +9 -6
- package/dist/types/components/QueryPanel/FieldHover.d.ts +0 -10
- package/dist/types/components/filters/hooks/useFilterModal.d.ts +0 -24
- package/dist/types/components/filters/hooks/useFilterPopup.d.ts +0 -8
- package/scripts/tsconfig.json +0 -8
- package/tsconfig.json +0 -16
package/dist/malloy-explorer.css
CHANGED
|
@@ -92,7 +92,6 @@
|
|
|
92
92
|
.mly16zck5j{margin:5px}
|
|
93
93
|
.mlykib98w{margin:8px}
|
|
94
94
|
.mly1bpp3o7{margin:auto}
|
|
95
|
-
.mly1p3i4rr{padding:0 10px}
|
|
96
95
|
.mlywp4ipm{padding:0 24px 24px 24px}
|
|
97
96
|
.mlyehqz9p{padding:0 4px}
|
|
98
97
|
.mly1l4tkcb{padding:0 8px 8px 8px}
|
|
@@ -170,12 +169,15 @@
|
|
|
170
169
|
.mlyb3r6kr{overflow:hidden}
|
|
171
170
|
.mly1rea2x4{overflow:visible}
|
|
172
171
|
.mly1ku5rj1{place-items:center}
|
|
172
|
+
.mly1hl2dhg{text-decoration:none}
|
|
173
173
|
.mly14znju7{transition:opacity .5s ease}
|
|
174
174
|
.mly1fxp9ov:hover{border-color:var(--malloy-composer-focus,#c3d7f7)}
|
|
175
175
|
.mlyetl2wx:focus{border-color:#4285F4}
|
|
176
176
|
}
|
|
177
177
|
|
|
178
178
|
@layer priority4{
|
|
179
|
+
.mly1ua5tub{-webkit-box-orient:vertical}
|
|
180
|
+
.mly1gzmk7r{-webkit-line-clamp:3}
|
|
179
181
|
.mly6s0dn4{align-items:center}
|
|
180
182
|
.mlypqajaz{align-items:end}
|
|
181
183
|
.mly1cy8zhl{align-items:flex-start}
|
|
@@ -261,6 +263,7 @@ html[dir='rtl'] .mly17fq3gk{box-shadow:0 2px 12px 0 rgba(0,0,0,.1), 0 1px 2px 0
|
|
|
261
263
|
.mly7eptgl{cursor:ew-resize}
|
|
262
264
|
.mly1ipiool{cursor:initial}
|
|
263
265
|
.mly1ypdohk{cursor:pointer}
|
|
266
|
+
.mly104kibb{display:-webkit-box}
|
|
264
267
|
.mly1lliihq{display:block}
|
|
265
268
|
.mly78zum5{display:flex}
|
|
266
269
|
.mlyrvj5dj{display:grid}
|
|
@@ -361,7 +364,6 @@ html[dir='rtl'] .mly17fq3gk{box-shadow:0 2px 12px 0 rgba(0,0,0,.1), 0 1px 2px 0
|
|
|
361
364
|
.mly1qx5ct2{height:20px}
|
|
362
365
|
.mlyxk0z11{height:24px}
|
|
363
366
|
.mly1fgtraw{height:28px}
|
|
364
|
-
.mly1gnnpzl{height:30px}
|
|
365
367
|
.mlyc9qbxq{height:36px}
|
|
366
368
|
.mlyng8ra{height:60px}
|
|
367
369
|
.mlydk7pt{height:8px}
|
|
@@ -380,25 +382,28 @@ html[dir='rtl'] .mly17fq3gk{box-shadow:0 2px 12px 0 rgba(0,0,0,.1), 0 1px 2px 0
|
|
|
380
382
|
.mly1xmf6yo{margin-top:8px}
|
|
381
383
|
.mly1rvw3h8{max-height:136px}
|
|
382
384
|
.mly1hkcv85{max-height:200px}
|
|
383
|
-
.
|
|
385
|
+
.mlyq3t0pi{max-height:280px}
|
|
384
386
|
.mlyuyqlj2{max-height:300px}
|
|
385
387
|
.mly1phlbz0{max-height:400px}
|
|
386
388
|
.mly3d5gib{max-height:50vh}
|
|
387
389
|
.mly1kbvuzt{max-height:var(--radix-tooltip-content-available-height)}
|
|
388
390
|
.mlyqyhut4{max-width:16.5px}
|
|
389
391
|
.mlyaka53j{max-width:230px}
|
|
392
|
+
.mly1pdpmub{max-width:264px}
|
|
393
|
+
.mly1jkqq1h{max-width:280px}
|
|
394
|
+
.mly1dc814f{max-width:350px}
|
|
390
395
|
.mlyxc7z9f{max-width:360px}
|
|
391
|
-
.mly1j9u4d2{max-width:400px}
|
|
392
396
|
.mlymcgfsh{max-width:60px}
|
|
397
|
+
.mly2lwn1j{min-height:0}
|
|
393
398
|
.mly4x6u8j{min-width:16.5px}
|
|
394
399
|
.mlygc0pbm{min-width:1px}
|
|
395
|
-
.mly1jzhcrs{min-width:200px}
|
|
396
400
|
.mlyt4ypqs{min-width:20px}
|
|
401
|
+
.mlyytlacd{min-width:224px}
|
|
402
|
+
.mlylm99nl{min-width:240px}
|
|
397
403
|
.mlyfvyar9{min-width:60px}
|
|
398
404
|
.mly1onzeue{min-width:95px}
|
|
399
|
-
.mly1odjw0f{overflow-y:auto}
|
|
400
405
|
.mly18d9i69{padding-bottom:0}
|
|
401
|
-
.
|
|
406
|
+
.mly1l90r2v{padding-bottom:16px}
|
|
402
407
|
.mlyjkvuk6{padding-bottom:4px}
|
|
403
408
|
.mlywib8y2{padding-bottom:8px}
|
|
404
409
|
.mlynm25rq{padding-left:16px}
|
|
@@ -423,6 +428,7 @@ html[dir='rtl'] .mly17fq3gk{box-shadow:0 2px 12px 0 rgba(0,0,0,.1), 0 1px 2px 0
|
|
|
423
428
|
.mlyw4jnvo{width:20px}
|
|
424
429
|
.mlyvy4d1p{width:24px}
|
|
425
430
|
.mly1f1nlb9{width:25%}
|
|
431
|
+
.mlyqyf9gi{width:250px}
|
|
426
432
|
.mlygd8bvy{width:28px}
|
|
427
433
|
.mlybl57os{width:323px}
|
|
428
434
|
.mlyxsgkw5{width:350px}
|
|
@@ -443,3 +449,13 @@ html[dir='rtl'] .mly17fq3gk{box-shadow:0 2px 12px 0 rgba(0,0,0,.1), 0 1px 2px 0
|
|
|
443
449
|
div[data-radix-popper-content-wrapper] {
|
|
444
450
|
z-index: 100 !important;
|
|
445
451
|
}
|
|
452
|
+
.malloy-render_result-wrapper malloy-render::part(table-container) {
|
|
453
|
+
width: 100%;
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
.malloy-render_result-wrapper {
|
|
457
|
+
height: 100%;
|
|
458
|
+
position: 'relative';
|
|
459
|
+
z-index: 0;
|
|
460
|
+
overflow: hidden;
|
|
461
|
+
}
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
3
2
|
import { FieldInfo } from '@malloydata/malloy-interfaces';
|
|
4
3
|
import { IconType } from '../../primitives';
|
|
5
4
|
import { ViewParent } from '../../utils/fields';
|
|
6
|
-
|
|
5
|
+
import { ParsedFilter } from '@malloydata/malloy-query-builder';
|
|
6
|
+
export interface AddFieldItemProps {
|
|
7
7
|
label: string;
|
|
8
8
|
icon: IconType;
|
|
9
9
|
view: ViewParent;
|
|
10
10
|
fields: FieldInfo[];
|
|
11
|
-
|
|
11
|
+
onAddOperation(field: FieldInfo, path: string[], filter?: ParsedFilter): void;
|
|
12
12
|
types: Array<'dimension' | 'measure' | 'view'>;
|
|
13
13
|
filter?: (view: ViewParent, field: Malloy.FieldInfo, path: string[]) => boolean;
|
|
14
14
|
disabledMessage?: string;
|
|
15
|
+
isFilterOperation?: boolean;
|
|
15
16
|
}
|
|
16
|
-
export declare function AddFieldItem({ view, fields, icon, label,
|
|
17
|
+
export declare function AddFieldItem({ view, fields, icon, label, onAddOperation, types, filter, disabledMessage, isFilterOperation, }: AddFieldItemProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
3
2
|
import { ViewParent } from '../../utils/fields';
|
|
3
|
+
import { ParsedFilter } from '@malloydata/malloy-query-builder';
|
|
4
4
|
export interface FieldListProps {
|
|
5
5
|
view: ViewParent;
|
|
6
6
|
fields: Malloy.FieldInfo[];
|
|
7
7
|
search: string;
|
|
8
|
-
|
|
8
|
+
onAddOperation: (field: Malloy.FieldInfo, path: string[], filter?: ParsedFilter) => void;
|
|
9
9
|
types: Array<'dimension' | 'measure' | 'view'>;
|
|
10
10
|
filter?: (view: ViewParent, field: Malloy.FieldInfo, path: string[]) => boolean;
|
|
11
|
+
isFilterOperation?: boolean;
|
|
11
12
|
}
|
|
12
|
-
export declare function FieldList({ view, fields,
|
|
13
|
+
export declare function FieldList({ view, fields, onAddOperation, search, types, filter, isFilterOperation, }: FieldListProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
3
2
|
import { ViewParent } from '../../utils/fields';
|
|
3
|
+
import { ParsedFilter } from '@malloydata/malloy-query-builder';
|
|
4
4
|
export interface FieldMenuProps {
|
|
5
5
|
view: ViewParent;
|
|
6
6
|
fields: Array<Malloy.FieldInfo>;
|
|
7
7
|
types: Array<'dimension' | 'measure' | 'view'>;
|
|
8
8
|
filter?: (view: ViewParent, field: Malloy.FieldInfo, path: string[]) => boolean;
|
|
9
|
-
|
|
9
|
+
onAddOperation: (field: Malloy.FieldInfo, path: string[], filter?: ParsedFilter) => void;
|
|
10
|
+
isFilterOperation?: boolean;
|
|
10
11
|
}
|
|
11
|
-
export declare function FieldMenu({ view, fields, types, filter,
|
|
12
|
+
export declare function FieldMenu({ view, fields, types, filter, onAddOperation, isFilterOperation, }: FieldMenuProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -6,7 +6,6 @@ export declare const addMenuStyles: Readonly<{
|
|
|
6
6
|
readonly boxShadow: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"boxShadow", `0px 2px 12px 0px ${import("@stylexjs/stylex/lib/StyleXTypes").StyleXVar<string>}`>;
|
|
7
7
|
readonly fontFamily: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"fontFamily", "sans-serif">;
|
|
8
8
|
readonly margin: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"margin", 8>;
|
|
9
|
-
readonly maxHeight: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"maxHeight", "50vh">;
|
|
10
9
|
readonly display: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"display", "flex">;
|
|
11
10
|
readonly flexDirection: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"flexDirection", "column">;
|
|
12
11
|
}>;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { ASTAggregateViewOperation, ASTQuery } from '@malloydata/malloy-query-builder';
|
|
1
|
+
import { ASTAggregateViewOperation, ASTQuery, ASTSegmentViewDefinition } from '@malloydata/malloy-query-builder';
|
|
2
2
|
import { ViewParent } from '../../utils/fields';
|
|
3
3
|
export interface AggregateOperationsProps {
|
|
4
4
|
rootQuery: ASTQuery;
|
|
5
|
+
segment: ASTSegmentViewDefinition;
|
|
5
6
|
view: ViewParent;
|
|
6
7
|
aggregates: ASTAggregateViewOperation[];
|
|
7
8
|
}
|
|
8
|
-
export declare function AggregateOperations({ rootQuery, view, aggregates, }: AggregateOperationsProps): import("react/jsx-runtime").JSX.Element
|
|
9
|
+
export declare function AggregateOperations({ rootQuery, segment, view, aggregates, }: AggregateOperationsProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { ASTGroupByViewOperation, ASTQuery } from '@malloydata/malloy-query-builder';
|
|
1
|
+
import { ASTGroupByViewOperation, ASTQuery, ASTSegmentViewDefinition } from '@malloydata/malloy-query-builder';
|
|
2
2
|
import { ViewParent } from '../../utils/fields';
|
|
3
3
|
export interface GroupByOperationsProps {
|
|
4
4
|
rootQuery: ASTQuery;
|
|
5
|
+
segment: ASTSegmentViewDefinition;
|
|
5
6
|
view: ViewParent;
|
|
6
7
|
groupBys: ASTGroupByViewOperation[];
|
|
7
8
|
}
|
|
8
|
-
export declare function GroupByOperations({ rootQuery, view, groupBys, }: GroupByOperationsProps): import("react/jsx-runtime").JSX.Element
|
|
9
|
+
export declare function GroupByOperations({ rootQuery, segment, view, groupBys, }: GroupByOperationsProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { ASTNestViewOperation, ASTQuery } from '@malloydata/malloy-query-builder';
|
|
2
|
+
import { ViewParent } from '../../utils/fields';
|
|
2
3
|
export interface NestOperationsProps {
|
|
3
4
|
rootQuery: ASTQuery;
|
|
5
|
+
view: ViewParent;
|
|
4
6
|
nests: ASTNestViewOperation[];
|
|
5
7
|
}
|
|
6
|
-
export declare function NestOperations({ rootQuery, nests }: NestOperationsProps): import("react/jsx-runtime").JSX.Element | null;
|
|
8
|
+
export declare function NestOperations({ rootQuery, view, nests }: NestOperationsProps): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ASTAggregateViewOperation, ASTGroupByViewOperation, ASTNestViewOperation, ASTQuery } from '@malloydata/malloy-query-builder';
|
|
2
|
+
import { ViewParent } from '../../utils/fields';
|
|
3
|
+
export interface RenameDialogProps {
|
|
4
|
+
rootQuery: ASTQuery | undefined;
|
|
5
|
+
view: ViewParent;
|
|
6
|
+
target: ASTGroupByViewOperation | ASTAggregateViewOperation | ASTNestViewOperation | undefined;
|
|
7
|
+
open: boolean;
|
|
8
|
+
setOpen: (open: boolean) => void;
|
|
9
|
+
}
|
|
10
|
+
export declare function RenameDialog({ rootQuery, view, target, open, setOpen, }: RenameDialogProps): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ASTAggregateViewOperation, ASTGroupByViewOperation, ASTQuery, ASTSegmentViewDefinition } from '@malloydata/malloy-query-builder';
|
|
2
|
+
import { ViewParent } from '../../utils/fields';
|
|
3
|
+
export interface SortableOperationsProps {
|
|
4
|
+
rootQuery: ASTQuery;
|
|
5
|
+
segment: ASTSegmentViewDefinition;
|
|
6
|
+
view: ViewParent;
|
|
7
|
+
operations: Array<ASTAggregateViewOperation | ASTGroupByViewOperation>;
|
|
8
|
+
kind: 'aggregate' | 'group_by';
|
|
9
|
+
}
|
|
10
|
+
export declare function SortableOperations({ rootQuery, segment, view, operations, kind, }: SortableOperationsProps): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -13,12 +13,19 @@ export type SubmittedQuery = {
|
|
|
13
13
|
onCancel: () => void;
|
|
14
14
|
response?: QueryResponse;
|
|
15
15
|
};
|
|
16
|
-
export type
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
16
|
+
export type RunInfo = {
|
|
17
|
+
queryLink?: {
|
|
18
|
+
linkText: string;
|
|
19
|
+
href: string;
|
|
20
|
+
};
|
|
21
|
+
/**
|
|
22
|
+
* Logical, named groupings of performance aspects.
|
|
23
|
+
*/
|
|
24
|
+
performanceAspects?: {
|
|
25
|
+
[key: string]: {
|
|
26
|
+
[key: string]: string;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
22
29
|
};
|
|
23
30
|
export type QueryResponse = {
|
|
24
31
|
/**
|
|
@@ -26,7 +33,7 @@ export type QueryResponse = {
|
|
|
26
33
|
*/
|
|
27
34
|
error?: Message;
|
|
28
35
|
result?: Malloy.Result;
|
|
29
|
-
|
|
36
|
+
runInfo?: RunInfo;
|
|
30
37
|
messages?: Array<Message>;
|
|
31
38
|
};
|
|
32
39
|
export type SeverityLevel = 'INFO' | 'DEBUG' | 'WARN' | 'ERROR' | 'FATAL';
|
|
@@ -3,8 +3,8 @@ import { ParsedFilter } from '@malloydata/malloy-query-builder';
|
|
|
3
3
|
export interface FilterDialogProps {
|
|
4
4
|
fieldInfo: Malloy.FieldInfoWithDimension | Malloy.FieldInfoWithMeasure;
|
|
5
5
|
path: string[];
|
|
6
|
-
filter
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
filter?: ParsedFilter;
|
|
7
|
+
onFilterApply: (filter: ParsedFilter) => void;
|
|
8
|
+
onOpenChange: (open: boolean) => void;
|
|
9
9
|
}
|
|
10
|
-
export declare function FilterDialog({ fieldInfo, path, filter,
|
|
10
|
+
export declare function FilterDialog({ fieldInfo, path, filter, onFilterApply, onOpenChange, }: FilterDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
3
|
+
import { ParsedFilter } from '@malloydata/malloy-query-builder';
|
|
4
|
+
interface FilterPopoverProps {
|
|
5
|
+
fieldInfo: Malloy.FieldInfoWithDimension | Malloy.FieldInfoWithMeasure;
|
|
6
|
+
path: string[];
|
|
7
|
+
filter?: ParsedFilter;
|
|
8
|
+
setFilter: (filter: ParsedFilter) => void;
|
|
9
|
+
trigger?: React.ReactElement;
|
|
10
|
+
anchor?: React.ReactElement;
|
|
11
|
+
layoutProps?: {
|
|
12
|
+
align?: 'start' | 'center' | 'end';
|
|
13
|
+
side?: 'top' | 'bottom' | 'left' | 'right';
|
|
14
|
+
alignOffset?: number;
|
|
15
|
+
sideOffset?: number;
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
export declare function FilterPopover({ fieldInfo, path, filter, setFilter, trigger, anchor, layoutProps, }: FilterPopoverProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export {};
|
|
@@ -2,13 +2,12 @@ export declare const filterStyles: Readonly<{
|
|
|
2
2
|
readonly filterDialog: Readonly<{
|
|
3
3
|
readonly display: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"display", "flex">;
|
|
4
4
|
readonly flexDirection: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"flexDirection", "column">;
|
|
5
|
-
readonly boxShadow: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"boxShadow", "0 1px 2px 0 rgba(0, 0, 0, 0.1), 0 2px 12px 0 rgba(0, 0, 0, 0.1)">;
|
|
6
|
-
readonly backgroundColor: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"backgroundColor", "white">;
|
|
7
|
-
readonly borderRadius: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"borderRadius", 8>;
|
|
8
5
|
readonly padding: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"padding", 8>;
|
|
9
|
-
readonly minWidth: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"minWidth",
|
|
10
|
-
readonly maxWidth: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"maxWidth",
|
|
6
|
+
readonly minWidth: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"minWidth", 224>;
|
|
7
|
+
readonly maxWidth: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"maxWidth", 264>;
|
|
11
8
|
readonly gap: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"gap", 8>;
|
|
9
|
+
readonly minHeight: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"minHeight", 0>;
|
|
10
|
+
readonly maxHeight: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"maxHeight", "50vh">;
|
|
12
11
|
}>;
|
|
13
12
|
readonly filterDialogHeader: Readonly<{
|
|
14
13
|
readonly fontWeight: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"fontWeight", "bold">;
|
|
@@ -21,13 +20,14 @@ export declare const filterStyles: Readonly<{
|
|
|
21
20
|
readonly gap: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"gap", 8>;
|
|
22
21
|
}>;
|
|
23
22
|
readonly editor: Readonly<{
|
|
24
|
-
readonly width: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"width", 350>;
|
|
25
23
|
readonly display: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"display", "flex">;
|
|
26
24
|
readonly flexDirection: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"flexDirection", "column">;
|
|
27
25
|
readonly gap: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"gap", 8>;
|
|
26
|
+
readonly minHeight: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"minHeight", 0>;
|
|
28
27
|
}>;
|
|
29
28
|
readonly editorRow: Readonly<{
|
|
30
|
-
readonly display: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"display", "
|
|
29
|
+
readonly display: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"display", "grid">;
|
|
30
|
+
readonly gridAutoFlow: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"gridAutoFlow", "column">;
|
|
31
31
|
readonly gap: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"gap", 8>;
|
|
32
32
|
}>;
|
|
33
33
|
readonly editorCell: Readonly<{
|
|
@@ -38,5 +38,6 @@ export declare const filterStyles: Readonly<{
|
|
|
38
38
|
readonly color: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"color", "rgb(95, 99, 104)">;
|
|
39
39
|
readonly padding: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"padding", "4px 8px 4px 8px">;
|
|
40
40
|
readonly borderRadius: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"borderRadius", 5>;
|
|
41
|
+
readonly minWidth: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"minWidth", "1px">;
|
|
41
42
|
}>;
|
|
42
43
|
}>;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
interface DOMElementProps {
|
|
2
2
|
element: HTMLElement;
|
|
3
|
+
className?: string;
|
|
4
|
+
style?: Record<string, string | number>;
|
|
3
5
|
}
|
|
4
|
-
export default function DOMElement({ element }: DOMElementProps): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export default function DOMElement({ element, className, style, }: DOMElementProps): import("react/jsx-runtime").JSX.Element;
|
|
5
7
|
export {};
|
|
@@ -29,8 +29,10 @@ interface DropdownSubMenuItemProps {
|
|
|
29
29
|
sublabel?: string;
|
|
30
30
|
disabled?: boolean;
|
|
31
31
|
children: DropdownMenuChild | DropdownMenuChild[];
|
|
32
|
+
open?: boolean;
|
|
33
|
+
onOpenChange?: (open: boolean) => void;
|
|
32
34
|
}
|
|
33
|
-
export declare function DropdownSubMenuItem({ icon, label, sublabel, disabled, children, }: DropdownSubMenuItemProps): import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
export declare function DropdownSubMenuItem({ icon, label, sublabel, disabled, children, open, onOpenChange, }: DropdownSubMenuItemProps): import("react/jsx-runtime").JSX.Element;
|
|
34
36
|
interface DropdownMenuLabelProps {
|
|
35
37
|
label: string;
|
|
36
38
|
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { StyleXStyles } from '@stylexjs/stylex';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
interface HoverCardProps {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
customStyle?: StyleXStyles;
|
|
6
|
+
}
|
|
7
|
+
export declare function HoverCard({ children, customStyle }: HoverCardProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -2,6 +2,8 @@ import * as React from 'react';
|
|
|
2
2
|
import { StyleXStyles } from '@stylexjs/stylex';
|
|
3
3
|
import { IconType } from '../utils/icon';
|
|
4
4
|
import { TokenColor, TokenSize } from './types';
|
|
5
|
+
import { DraggableAttributes } from '@dnd-kit/core';
|
|
6
|
+
import { SyntheticListenerMap } from '@dnd-kit/core/dist/hooks/utilities';
|
|
5
7
|
export interface TokenProps extends React.ComponentProps<'button'> {
|
|
6
8
|
/**
|
|
7
9
|
* The label to display on the token.
|
|
@@ -41,9 +43,13 @@ export interface TokenProps extends React.ComponentProps<'button'> {
|
|
|
41
43
|
alignOffset?: number;
|
|
42
44
|
sideOffset?: number;
|
|
43
45
|
};
|
|
46
|
+
dragProps?: {
|
|
47
|
+
attributes: DraggableAttributes;
|
|
48
|
+
listeners?: SyntheticListenerMap;
|
|
49
|
+
};
|
|
44
50
|
/**
|
|
45
51
|
* Custom styles for the token.
|
|
46
52
|
*/
|
|
47
53
|
customStyle?: StyleXStyles;
|
|
48
54
|
}
|
|
49
|
-
export default function Token({ label, icon, color, size, onClick, onHover, asButtonTrigger, tooltip, tooltipProps, customStyle, ...props }: TokenProps): import("react/jsx-runtime").JSX.Element;
|
|
55
|
+
export default function Token({ label, icon, color, size, onClick, onHover, asButtonTrigger, tooltip, tooltipProps, customStyle, dragProps, ...props }: TokenProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -45,7 +45,6 @@ export declare const styles: Readonly<{
|
|
|
45
45
|
readonly tokenContainer: Readonly<{
|
|
46
46
|
readonly display: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"display", "flex">;
|
|
47
47
|
readonly flexDirection: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"flexDirection", "column">;
|
|
48
|
-
readonly alignItems: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"alignItems", "start">;
|
|
49
48
|
readonly gap: import("@stylexjs/stylex/lib/StyleXTypes").StyleXClassNameFor<"gap", 8>;
|
|
50
49
|
}>;
|
|
51
50
|
readonly token: Readonly<{
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
2
2
|
export declare const getDescriptionAnnotation: (annotations: Array<Malloy.Annotation>) => string | undefined;
|
|
3
|
+
export declare const hasExplorerFilterFieldAnnotation: (annotations: Array<Malloy.Annotation>) => boolean;
|
|
@@ -11,5 +11,5 @@ export declare function sortFieldInfos(fields: Malloy.FieldInfo[]): Malloy.Field
|
|
|
11
11
|
export declare function isIndexView(field: Malloy.FieldInfoWithView): boolean;
|
|
12
12
|
export declare function getViewDefinition(parent: ViewParent): import("@malloydata/malloy-query-builder").ASTViewDefinition;
|
|
13
13
|
export declare function getInputSchemaFromViewParent(parent: ViewParent): Malloy.Schema;
|
|
14
|
-
export declare function
|
|
15
|
-
export declare function
|
|
14
|
+
export declare function isNotAnnotatedFilteredField(field: Malloy.FieldInfo): boolean;
|
|
15
|
+
export declare function findUniqueFieldName(fields: Malloy.FieldInfo[], rename: string): string;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
2
|
-
import {
|
|
2
|
+
import { ASTSegmentViewDefinition } from '@malloydata/malloy-query-builder';
|
|
3
3
|
import { ViewParent } from './fields';
|
|
4
4
|
export declare function segmentHasLimit(segment: ASTSegmentViewDefinition): boolean;
|
|
5
5
|
export declare function segmentHasOrderBy(segment: ASTSegmentViewDefinition, name: string): boolean;
|
|
6
6
|
export declare function segmentNestNo(segment: ASTSegmentViewDefinition, name?: string): number;
|
|
7
|
-
export declare function addGroupBy(
|
|
7
|
+
export declare function addGroupBy(view: ViewParent, field: Malloy.FieldInfo, path: string[]): void;
|
|
8
|
+
export declare function addAggregate(view: ViewParent, field: Malloy.FieldInfo, path: string[]): void;
|
|
9
|
+
export declare function addNest(view: ViewParent, field: Malloy.FieldInfo): void;
|
|
8
10
|
export declare function getSegmentIfPresent(parent: ViewParent): ASTSegmentViewDefinition | undefined;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
3
3
|
import { ASTQuery } from '@malloydata/malloy-query-builder';
|
|
4
|
-
import { OpenFilterModalCallback } from '../components/filters/hooks/useFilterModal';
|
|
5
4
|
export interface SearchValueMapResult {
|
|
6
5
|
fieldName: string;
|
|
7
6
|
cardinality: number;
|
|
@@ -18,7 +17,6 @@ export interface QueryEditorContextProps {
|
|
|
18
17
|
/** Provide to allow editing of the query */
|
|
19
18
|
setQuery?: (rootQuery: Malloy.Query | undefined) => void;
|
|
20
19
|
topValues?: SearchValueMapResult[];
|
|
21
|
-
openFilterModal: OpenFilterModalCallback;
|
|
22
20
|
}
|
|
23
21
|
/**
|
|
24
22
|
* QueryEditorContext enables query editing by providing the setQuery
|
package/dist/types/index.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import './stylex.css';
|
|
|
2
2
|
export { MalloyExplorerProvider } from './components/MalloyExplorerProvider';
|
|
3
3
|
export { QueryActionBar, QueryEditor, QueryPanel } from './components/QueryPanel';
|
|
4
4
|
export { ResultPanel } from './components/ResultPanel';
|
|
5
|
-
export type { EXECUTION_STATES, QueryExecutionState, QueryResponse,
|
|
5
|
+
export type { EXECUTION_STATES, Message, QueryExecutionState, QueryResponse, RunInfo, SeverityLevel, SubmittedQuery, } from './components/ResultPanel/SubmittedQuery';
|
|
6
6
|
export { SourcePanel } from './components/SourcePanel';
|
|
7
7
|
export { ResizeBar } from './components/primitives';
|
|
8
8
|
export { ExplorerPanelsContext } from './contexts/ExplorerPanelsContext';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@malloydata/malloy-explorer",
|
|
3
|
-
"version": "0.0.266-
|
|
3
|
+
"version": "0.0.266-dev250425232629",
|
|
4
4
|
"description": "Malloy visual query builder",
|
|
5
5
|
"main": "dist/cjs/index.cjs",
|
|
6
6
|
"types": "dist/types/index.d.ts",
|
|
@@ -51,6 +51,9 @@
|
|
|
51
51
|
},
|
|
52
52
|
"homepage": "https://github.com/malloydata/malloy-explorer#readme",
|
|
53
53
|
"dependencies": {
|
|
54
|
+
"@dnd-kit/core": "^6.3.1",
|
|
55
|
+
"@dnd-kit/sortable": "^10.0.0",
|
|
56
|
+
"@dnd-kit/utilities": "^3.2.2",
|
|
54
57
|
"@floating-ui/react-dom": "2.1.2",
|
|
55
58
|
"@radix-ui/react-dialog": "^1.1.6",
|
|
56
59
|
"@radix-ui/react-dropdown-menu": "^2.1.6",
|
|
@@ -99,11 +102,11 @@
|
|
|
99
102
|
"vite-plugin-svgr": "^4.3.0"
|
|
100
103
|
},
|
|
101
104
|
"peerDependencies": {
|
|
102
|
-
"@malloydata/malloy-filter": "
|
|
103
|
-
"@malloydata/malloy-interfaces": "
|
|
104
|
-
"@malloydata/malloy-query-builder": "
|
|
105
|
-
"@malloydata/malloy-tag": "
|
|
106
|
-
"@malloydata/render": "
|
|
105
|
+
"@malloydata/malloy-filter": "^0.0.268",
|
|
106
|
+
"@malloydata/malloy-interfaces": "^0.0.268",
|
|
107
|
+
"@malloydata/malloy-query-builder": "^0.0.268",
|
|
108
|
+
"@malloydata/malloy-tag": "^0.0.268",
|
|
109
|
+
"@malloydata/render": "^0.0.268",
|
|
107
110
|
"react": ">= 19.0.0",
|
|
108
111
|
"react-dom": ">= 19.0.0"
|
|
109
112
|
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
3
|
-
export interface FieldHoverProps {
|
|
4
|
-
align?: 'start' | 'center' | 'end';
|
|
5
|
-
children: ReactNode;
|
|
6
|
-
field: Malloy.FieldInfo;
|
|
7
|
-
path: string[] | undefined;
|
|
8
|
-
side?: 'top' | 'bottom' | 'left' | 'right';
|
|
9
|
-
}
|
|
10
|
-
export declare function FieldHover({ align, children, field, path, side, }: FieldHoverProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
3
|
-
import { ASTQuery, ParsedFilter } from '@malloydata/malloy-query-builder';
|
|
4
|
-
import { ViewParent } from '../../utils/fields';
|
|
5
|
-
export interface OpenFilterModalParams {
|
|
6
|
-
view: ViewParent;
|
|
7
|
-
fieldInfo: Malloy.FieldInfoWithDimension | Malloy.FieldInfoWithMeasure;
|
|
8
|
-
path: string[];
|
|
9
|
-
filter?: ParsedFilter;
|
|
10
|
-
x?: number;
|
|
11
|
-
y?: number;
|
|
12
|
-
}
|
|
13
|
-
export type OpenFilterModalCallback = ({ view, fieldInfo, path, filter, }: OpenFilterModalParams) => void;
|
|
14
|
-
export interface UseFilterModelProps {
|
|
15
|
-
setQuery: ((rootQuery: Malloy.Query | undefined) => void) | undefined;
|
|
16
|
-
rootQuery: ASTQuery | undefined;
|
|
17
|
-
}
|
|
18
|
-
export declare function useFilterModal({ setQuery, rootQuery }: UseFilterModelProps): {
|
|
19
|
-
openFilterModal: React.Dispatch<React.SetStateAction<OpenFilterModalParams | undefined>>;
|
|
20
|
-
FilterModal: () => null;
|
|
21
|
-
} | {
|
|
22
|
-
openFilterModal: React.Dispatch<React.SetStateAction<OpenFilterModalParams | undefined>>;
|
|
23
|
-
FilterModal: () => import("react/jsx-runtime").JSX.Element;
|
|
24
|
-
};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import * as Malloy from '@malloydata/malloy-interfaces';
|
|
3
|
-
import { ParsedFilter } from '@malloydata/malloy-query-builder';
|
|
4
|
-
export declare function useFilterPopup(fieldInfo: Malloy.FieldInfoWithDimension | Malloy.FieldInfoWithMeasure, path: string[], filter: ParsedFilter, setFilter: (filter: ParsedFilter) => void): {
|
|
5
|
-
FilterPopup: ({ trigger }: {
|
|
6
|
-
trigger: React.ReactElement;
|
|
7
|
-
}) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
-
};
|
package/scripts/tsconfig.json
DELETED
package/tsconfig.json
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
"esModuleInterop": true,
|
|
4
|
-
"jsx": "react-jsx",
|
|
5
|
-
"module": "ESNext",
|
|
6
|
-
"moduleResolution": "bundler",
|
|
7
|
-
"noEmit": false,
|
|
8
|
-
"outDir": "dist/types",
|
|
9
|
-
"resolveJsonModule": true,
|
|
10
|
-
"rootDir": "src",
|
|
11
|
-
"skipLibCheck": true,
|
|
12
|
-
"strict": true,
|
|
13
|
-
"target": "ES2019"
|
|
14
|
-
},
|
|
15
|
-
"include": ["src"]
|
|
16
|
-
}
|