@malloydata/malloy-explorer 0.0.285-dev250610181307 → 0.0.285-dev250611150446
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/cjs/index.cjs +379 -7
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/esm/index.js +379 -7
- package/dist/esm/index.js.map +1 -1
- package/dist/malloy-explorer.css +3 -0
- package/dist/types/components/QueryPanel/RendererPopover.d.ts +20 -0
- package/dist/types/components/primitives/utils/icon.d.ts +18 -0
- package/dist/types/components/utils/renderer.d.ts +33 -3
- package/package.json +8 -8
package/dist/malloy-explorer.css
CHANGED
|
@@ -300,10 +300,12 @@ html[dir='rtl'] .mly17fq3gk{box-shadow:0 2px 12px 0 rgba(0,0,0,.1), 0 1px 2px 0
|
|
|
300
300
|
.mly52fmzj{grid-template-columns:1fr auto}
|
|
301
301
|
.mly1g3yg12{grid-template-columns:auto 1fr auto}
|
|
302
302
|
.mlybyjr8{grid-template-columns:auto}
|
|
303
|
+
.mly17bnpya{grid-template-columns:min-content 1fr}
|
|
303
304
|
.mlyl56j7k{justify-content:center}
|
|
304
305
|
.mly13a6bvl{justify-content:flex-end}
|
|
305
306
|
.mly1nhvcw1{justify-content:flex-start}
|
|
306
307
|
.mly1rfj78v{justify-content:left}
|
|
308
|
+
.mly1lvf691{justify-content:right}
|
|
307
309
|
.mly1l1ennw{justify-content:space-around}
|
|
308
310
|
.mly1qughib{justify-content:space-between}
|
|
309
311
|
.mlylqzeqv{justify-content:start}
|
|
@@ -376,6 +378,7 @@ html[dir='rtl'] .mly17fq3gk{box-shadow:0 2px 12px 0 rgba(0,0,0,.1), 0 1px 2px 0
|
|
|
376
378
|
.mlydk7pt{height:8px}
|
|
377
379
|
.mlylo07zb{height:90px}
|
|
378
380
|
.mlyt7dq6l{height:auto}
|
|
381
|
+
.mly1ktj5wk{height:calc(100% - 8px)}
|
|
379
382
|
.mlyu96u03{left:0}
|
|
380
383
|
.mly12nagc{margin-bottom:4px}
|
|
381
384
|
.mlyu06os2{margin-bottom:5px}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { VizOption, VizName } from '../utils/renderer';
|
|
2
|
+
import { ASTQuery, ASTView } from '@malloydata/malloy-query-builder';
|
|
3
|
+
import { StyleXStyles } from '@stylexjs/stylex';
|
|
4
|
+
export interface RendererPopoverProps {
|
|
5
|
+
rootQuery: ASTQuery;
|
|
6
|
+
viz: VizName;
|
|
7
|
+
options: VizOption[];
|
|
8
|
+
view: ASTQuery | ASTView;
|
|
9
|
+
customStyle?: StyleXStyles;
|
|
10
|
+
}
|
|
11
|
+
export declare function RendererPopover({ rootQuery, viz, options, view, customStyle, }: RendererPopoverProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export interface RendererEditorProps {
|
|
13
|
+
rootQuery: ASTQuery;
|
|
14
|
+
viz: VizName;
|
|
15
|
+
options: VizOption[];
|
|
16
|
+
view: ASTQuery | ASTView;
|
|
17
|
+
customStyle?: StyleXStyles;
|
|
18
|
+
setOpen: (open: boolean) => void;
|
|
19
|
+
}
|
|
20
|
+
export declare function RendererEditor({ rootQuery, view, viz, options, setOpen, }: RendererEditorProps): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -71,6 +71,12 @@ export declare const ICON_MAP: {
|
|
|
71
71
|
desc?: string;
|
|
72
72
|
descId?: string;
|
|
73
73
|
}>;
|
|
74
|
+
readonly gear: import("react").FunctionComponent<import("react").SVGProps<SVGSVGElement> & {
|
|
75
|
+
title?: string;
|
|
76
|
+
titleId?: string;
|
|
77
|
+
desc?: string;
|
|
78
|
+
descId?: string;
|
|
79
|
+
}>;
|
|
74
80
|
readonly info: import("react").FunctionComponent<import("react").SVGProps<SVGSVGElement> & {
|
|
75
81
|
title?: string;
|
|
76
82
|
titleId?: string;
|
|
@@ -251,6 +257,12 @@ export declare const ICON_MAP: {
|
|
|
251
257
|
desc?: string;
|
|
252
258
|
descId?: string;
|
|
253
259
|
}>;
|
|
260
|
+
readonly viz_bar: import("react").FunctionComponent<import("react").SVGProps<SVGSVGElement> & {
|
|
261
|
+
title?: string;
|
|
262
|
+
titleId?: string;
|
|
263
|
+
desc?: string;
|
|
264
|
+
descId?: string;
|
|
265
|
+
}>;
|
|
254
266
|
readonly viz_boolean: import("react").FunctionComponent<import("react").SVGProps<SVGSVGElement> & {
|
|
255
267
|
title?: string;
|
|
256
268
|
titleId?: string;
|
|
@@ -305,6 +317,12 @@ export declare const ICON_MAP: {
|
|
|
305
317
|
desc?: string;
|
|
306
318
|
descId?: string;
|
|
307
319
|
}>;
|
|
320
|
+
readonly viz_line: import("react").FunctionComponent<import("react").SVGProps<SVGSVGElement> & {
|
|
321
|
+
title?: string;
|
|
322
|
+
titleId?: string;
|
|
323
|
+
desc?: string;
|
|
324
|
+
descId?: string;
|
|
325
|
+
}>;
|
|
308
326
|
readonly viz_link: import("react").FunctionComponent<import("react").SVGProps<SVGSVGElement> & {
|
|
309
327
|
title?: string;
|
|
310
328
|
titleId?: string;
|
|
@@ -1,6 +1,36 @@
|
|
|
1
1
|
import { Tag } from '@malloydata/malloy-tag';
|
|
2
|
-
export declare const
|
|
3
|
-
export declare const
|
|
2
|
+
export declare const RENDERER_PREFIX = "# ";
|
|
3
|
+
export declare const VIZ_RENDERERS: VizName[];
|
|
4
|
+
export declare const QUERY_RENDERERS: QueryRendererName[];
|
|
5
|
+
export declare const ATOMIC_RENDERERS: AtomicRendererName[];
|
|
4
6
|
export declare const RENDERERS: RendererName[];
|
|
5
|
-
export type
|
|
7
|
+
export type VizName = 'table' | 'bar' | 'dashboard' | 'json' | 'line' | 'list' | 'list_detail' | 'point_map' | 'scatter_chart' | 'segment_map' | 'shape_map';
|
|
8
|
+
export type QueryRendererName = 'table' | 'bar_chart' | 'dashboard' | 'json' | 'line_chart' | 'list' | 'list_detail' | 'point_map' | 'scatter_chart' | 'segment_map' | 'shape_map';
|
|
9
|
+
export type AtomicRendererName = 'number' | 'boolean' | 'currency' | 'image' | 'url' | 'percent' | 'text' | 'time';
|
|
10
|
+
export type RendererName = QueryRendererName | AtomicRendererName;
|
|
6
11
|
export declare function tagToRenderer(tag: Tag | undefined): RendererName | null;
|
|
12
|
+
export declare function legacyToViz(name: QueryRendererName): VizName;
|
|
13
|
+
export interface BaseVizOption {
|
|
14
|
+
name: string;
|
|
15
|
+
label: string;
|
|
16
|
+
description?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface VizBooleanOption extends BaseVizOption {
|
|
19
|
+
type: 'boolean';
|
|
20
|
+
default: boolean;
|
|
21
|
+
}
|
|
22
|
+
export interface VizStringOption extends BaseVizOption {
|
|
23
|
+
type: 'string';
|
|
24
|
+
default: string;
|
|
25
|
+
}
|
|
26
|
+
export interface VizSelectOption extends BaseVizOption {
|
|
27
|
+
type: 'select';
|
|
28
|
+
default: string;
|
|
29
|
+
options: Array<{
|
|
30
|
+
label: string;
|
|
31
|
+
description?: string;
|
|
32
|
+
value: string;
|
|
33
|
+
}>;
|
|
34
|
+
}
|
|
35
|
+
export type VizOption = VizBooleanOption | VizStringOption | VizSelectOption;
|
|
36
|
+
export declare const VISUALIZATION_OPTIONS: Record<VizName, VizOption[] | null>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@malloydata/malloy-explorer",
|
|
3
|
-
"version": "0.0.285-
|
|
3
|
+
"version": "0.0.285-dev250611150446",
|
|
4
4
|
"description": "Malloy visual query builder",
|
|
5
5
|
"main": "dist/cjs/index.cjs",
|
|
6
6
|
"types": "dist/types/index.d.ts",
|
|
@@ -113,12 +113,12 @@
|
|
|
113
113
|
"vite-plugin-svgr": "^4.3.0"
|
|
114
114
|
},
|
|
115
115
|
"peerDependencies": {
|
|
116
|
-
"@malloydata/malloy-filter": ">=
|
|
117
|
-
"@malloydata/malloy-interfaces": ">=
|
|
118
|
-
"@malloydata/malloy-query-builder": ">=
|
|
119
|
-
"@malloydata/malloy-tag": ">=
|
|
120
|
-
"@malloydata/render": ">=
|
|
121
|
-
"react": ">=
|
|
122
|
-
"react-dom": ">=
|
|
116
|
+
"@malloydata/malloy-filter": ">=0.0.291",
|
|
117
|
+
"@malloydata/malloy-interfaces": ">=0.0.291",
|
|
118
|
+
"@malloydata/malloy-query-builder": ">=0.0.291",
|
|
119
|
+
"@malloydata/malloy-tag": ">=0.0.291",
|
|
120
|
+
"@malloydata/render": ">=0.0.291",
|
|
121
|
+
"react": ">=19.0.0",
|
|
122
|
+
"react-dom": ">=19.0.0"
|
|
123
123
|
}
|
|
124
124
|
}
|