@genesislcap/rapid-grid-tabulator 14.238.0
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/README.md +29 -0
- package/custom-elements-manifest.config.js +14 -0
- package/dist/custom-elements.json +1231 -0
- package/dist/dts/cell-renderers/action.renderer.d.ts +23 -0
- package/dist/dts/cell-renderers/action.renderer.d.ts.map +1 -0
- package/dist/dts/cell-renderers/index.d.ts +2 -0
- package/dist/dts/cell-renderers/index.d.ts.map +1 -0
- package/dist/dts/grid-components.d.ts +16 -0
- package/dist/dts/grid-components.d.ts.map +1 -0
- package/dist/dts/grid-tabulator.d.ts +38 -0
- package/dist/dts/grid-tabulator.d.ts.map +1 -0
- package/dist/dts/grid-tabulator.styles.d.ts +2 -0
- package/dist/dts/grid-tabulator.styles.d.ts.map +1 -0
- package/dist/dts/grid-tabulator.template.d.ts +2 -0
- package/dist/dts/grid-tabulator.template.d.ts.map +1 -0
- package/dist/dts/index.d.ts +9 -0
- package/dist/dts/index.d.ts.map +1 -0
- package/dist/dts/style/colors.d.ts +16 -0
- package/dist/dts/style/colors.d.ts.map +1 -0
- package/dist/dts/style/index.d.ts +3 -0
- package/dist/dts/style/index.d.ts.map +1 -0
- package/dist/dts/style/tokens.d.ts +9 -0
- package/dist/dts/style/tokens.d.ts.map +1 -0
- package/dist/dts/themes/genesis-rapid/theme-genesis-rapid-css.d.ts +2 -0
- package/dist/dts/themes/genesis-rapid/theme-genesis-rapid-css.d.ts.map +1 -0
- package/dist/dts/themes/genesis-rapid/theme-genesis-rapid.d.ts +8 -0
- package/dist/dts/themes/genesis-rapid/theme-genesis-rapid.d.ts.map +1 -0
- package/dist/dts/themes/index.d.ts +2 -0
- package/dist/dts/themes/index.d.ts.map +1 -0
- package/dist/esm/cell-renderers/action.renderer.js +39 -0
- package/dist/esm/cell-renderers/index.js +1 -0
- package/dist/esm/grid-components.js +29 -0
- package/dist/esm/grid-tabulator.js +53 -0
- package/dist/esm/grid-tabulator.styles.js +21 -0
- package/dist/esm/grid-tabulator.template.js +2 -0
- package/dist/esm/index.js +8 -0
- package/dist/esm/style/colors.js +16 -0
- package/dist/esm/style/index.js +2 -0
- package/dist/esm/style/tokens.js +21 -0
- package/dist/esm/themes/genesis-rapid/theme-genesis-rapid-css.js +1326 -0
- package/dist/esm/themes/genesis-rapid/theme-genesis-rapid.js +89 -0
- package/dist/esm/themes/index.js +1 -0
- package/genx.config.ts +11 -0
- package/license.txt +46 -0
- package/package.json +70 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { ActionRenderer } from '@genesislcap/grid-tabulator';
|
|
2
|
+
/**
|
|
3
|
+
* @tagname %%prefix%%-grid-tabulator-action-renderer
|
|
4
|
+
*/
|
|
5
|
+
export declare class RapidTabulatorActionRenderer extends ActionRenderer {
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* The Rapid Action Renderer
|
|
9
|
+
*
|
|
10
|
+
* @public
|
|
11
|
+
* @remarks
|
|
12
|
+
* HTML Element: \<rapid-grid-tabulator-action-renderer\>
|
|
13
|
+
*/
|
|
14
|
+
export declare const rapidTabulatorActionRenderer: (overrideDefinition?: import("@microsoft/fast-foundation").OverrideFoundationElementDefinition<{
|
|
15
|
+
baseName: string;
|
|
16
|
+
styles: import("@microsoft/fast-element").ElementStyles;
|
|
17
|
+
template: import("@microsoft/fast-element").ViewTemplate<RapidTabulatorActionRenderer, any>;
|
|
18
|
+
}>) => import("@microsoft/fast-foundation").FoundationElementRegistry<{
|
|
19
|
+
baseName: string;
|
|
20
|
+
styles: import("@microsoft/fast-element").ElementStyles;
|
|
21
|
+
template: import("@microsoft/fast-element").ViewTemplate<RapidTabulatorActionRenderer, any>;
|
|
22
|
+
}, typeof RapidTabulatorActionRenderer>;
|
|
23
|
+
//# sourceMappingURL=action.renderer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"action.renderer.d.ts","sourceRoot":"","sources":["../../../src/cell-renderers/action.renderer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAiC,MAAM,6BAA6B,CAAC;AAG5F;;GAEG;AACH,qBAAa,4BAA6B,SAAQ,cAAc;CAAG;AAEnE;;;;;;GAMG;AACH,eAAO,MAAM,4BAA4B;;;;;;;;uCAyBvC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/cell-renderers/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Container } from '@microsoft/fast-foundation';
|
|
2
|
+
export declare const rapidGridTabulatorComponents: {
|
|
3
|
+
rapidGridTabulator: (overrideDefinition?: import("@microsoft/fast-foundation").OverrideFoundationElementDefinition<{
|
|
4
|
+
shadowOptions: any;
|
|
5
|
+
baseName: string;
|
|
6
|
+
template: import("@microsoft/fast-element").ViewTemplate<any, any>;
|
|
7
|
+
styles: import("@microsoft/fast-element").ElementStyles;
|
|
8
|
+
}>) => import("@microsoft/fast-foundation").FoundationElementRegistry<{
|
|
9
|
+
shadowOptions: any;
|
|
10
|
+
baseName: string;
|
|
11
|
+
template: import("@microsoft/fast-element").ViewTemplate<any, any>;
|
|
12
|
+
styles: import("@microsoft/fast-element").ElementStyles;
|
|
13
|
+
}, typeof import("./grid-tabulator").RapidGridTabulator>;
|
|
14
|
+
register(container?: Container, ...rest: any[]): void;
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=grid-components.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grid-components.d.ts","sourceRoot":"","sources":["../../src/grid-components.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AAU5D,eAAO,MAAM,4BAA4B;;;;;;;;;;;;yBAOlB,SAAS,WAAW,GAAG,EAAE;CAa/C,CAAC"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { GridTabulator } from '@genesislcap/grid-tabulator';
|
|
2
|
+
import { Options } from 'tabulator-tables';
|
|
3
|
+
/**
|
|
4
|
+
* @tagname %%prefix%%-grid-tabulator
|
|
5
|
+
*/
|
|
6
|
+
export declare class RapidGridTabulator extends GridTabulator {
|
|
7
|
+
/**
|
|
8
|
+
* Sets default theme to Rapid
|
|
9
|
+
* @override
|
|
10
|
+
*/
|
|
11
|
+
theme: string;
|
|
12
|
+
themeChanged(oldValue: string, newValue: string): void;
|
|
13
|
+
/**
|
|
14
|
+
* Gets the grid options
|
|
15
|
+
*/
|
|
16
|
+
get gridOptions(): Options;
|
|
17
|
+
/**
|
|
18
|
+
* Handles extra RAPID configs and options
|
|
19
|
+
* @override
|
|
20
|
+
*/
|
|
21
|
+
set gridOptions(options: Options);
|
|
22
|
+
}
|
|
23
|
+
export declare const rapidGridTabulatorShadowOptions: ShadowRootInit;
|
|
24
|
+
export declare const rapidGridTabulatorDefaultConfig: {
|
|
25
|
+
shadowOptions: any;
|
|
26
|
+
};
|
|
27
|
+
export declare const rapidGridTabulator: (overrideDefinition?: import("@microsoft/fast-foundation").OverrideFoundationElementDefinition<{
|
|
28
|
+
shadowOptions: any;
|
|
29
|
+
baseName: string;
|
|
30
|
+
template: import("@microsoft/fast-element").ViewTemplate<any, any>;
|
|
31
|
+
styles: import("@microsoft/fast-element").ElementStyles;
|
|
32
|
+
}>) => import("@microsoft/fast-foundation").FoundationElementRegistry<{
|
|
33
|
+
shadowOptions: any;
|
|
34
|
+
baseName: string;
|
|
35
|
+
template: import("@microsoft/fast-element").ViewTemplate<any, any>;
|
|
36
|
+
styles: import("@microsoft/fast-element").ElementStyles;
|
|
37
|
+
}, typeof RapidGridTabulator>;
|
|
38
|
+
//# sourceMappingURL=grid-tabulator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grid-tabulator.d.ts","sourceRoot":"","sources":["../../src/grid-tabulator.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,aAAa,EAGd,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAQ3C;;GAEG;AACH,qBAAa,kBAAmB,SAAQ,aAAa;IACnD;;;OAGG;IACH,KAAK,SAAqB;IAC1B,YAAY,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM;IAK/C;;OAEG;IACH,IAAI,WAAW,IAAI,OAAO,CAEzB;IAED;;;OAGG;IACH,IAAI,WAAW,CAAC,OAAO,EAAE,OAAO,EAgB/B;CACF;AAGD,eAAO,MAAM,+BAA+B,EAAE,cAA2C,CAAC;AAC1F,eAAO,MAAM,+BAA+B;;CAA6B,CAAC;AAE1E,eAAO,MAAM,kBAAkB;;;;;;;;;;6BAM7B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grid-tabulator.styles.d.ts","sourceRoot":"","sources":["../../src/grid-tabulator.styles.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,wBAAwB,iDAiBpC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grid-tabulator.template.d.ts","sourceRoot":"","sources":["../../src/grid-tabulator.template.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,0BAA0B,0DAAwB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export * from './grid-tabulator';
|
|
2
|
+
export * from './grid-tabulator.styles';
|
|
3
|
+
export * from './grid-tabulator.template';
|
|
4
|
+
export * from './cell-renderers';
|
|
5
|
+
export * from './themes';
|
|
6
|
+
export * from './style';
|
|
7
|
+
export * from './grid-components';
|
|
8
|
+
export * from '@genesislcap/grid-tabulator';
|
|
9
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,yBAAyB,CAAC;AACxC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,kBAAkB,CAAC;AACjC,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AAExB,cAAc,mBAAmB,CAAC;AAElC,cAAc,6BAA6B,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { SwatchRGB } from '@microsoft/fast-components';
|
|
2
|
+
export declare const darkColors: {
|
|
3
|
+
foregroundSwatch: SwatchRGB;
|
|
4
|
+
headerForegroundSwatch: SwatchRGB;
|
|
5
|
+
backgroundSwatch: SwatchRGB;
|
|
6
|
+
borderSwatch: SwatchRGB;
|
|
7
|
+
rowHoverSwatch: SwatchRGB;
|
|
8
|
+
};
|
|
9
|
+
export declare const lightColors: {
|
|
10
|
+
foregroundSwatch: SwatchRGB;
|
|
11
|
+
headerForegroundSwatch: SwatchRGB;
|
|
12
|
+
backgroundSwatch: SwatchRGB;
|
|
13
|
+
borderSwatch: SwatchRGB;
|
|
14
|
+
rowHoverSwatch: SwatchRGB;
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=colors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"colors.d.ts","sourceRoot":"","sources":["../../../src/style/colors.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AAEvD,eAAO,MAAM,UAAU;;;;;;CAMtB,CAAC;AAEF,eAAO,MAAM,WAAW;;;;;;CAMvB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/style/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Swatch } from '@microsoft/fast-components';
|
|
2
|
+
export declare const gridThemeGenesisRapidTokens: {
|
|
3
|
+
backgroundColor: import("@microsoft/fast-foundation").CSSDesignToken<Swatch>;
|
|
4
|
+
borderColor: import("@microsoft/fast-foundation").CSSDesignToken<Swatch>;
|
|
5
|
+
foregroundColor: import("@microsoft/fast-foundation").CSSDesignToken<Swatch>;
|
|
6
|
+
headerForegroundColor: import("@microsoft/fast-foundation").CSSDesignToken<Swatch>;
|
|
7
|
+
rowHoverColor: import("@microsoft/fast-foundation").CSSDesignToken<Swatch>;
|
|
8
|
+
};
|
|
9
|
+
//# sourceMappingURL=tokens.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tokens.d.ts","sourceRoot":"","sources":["../../../src/style/tokens.ts"],"names":[],"mappings":"AAAA,OAAO,EAAyC,MAAM,EAAE,MAAM,4BAA4B,CAAC;AAM3F,eAAO,MAAM,2BAA2B;;;;;;CA2BvC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-genesis-rapid-css.d.ts","sourceRoot":"","sources":["../../../../src/themes/genesis-rapid/theme-genesis-rapid-css.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,oBAAoB,iDA4yChC,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { CSSVarTokenMap } from '@genesislcap/foundation-ui';
|
|
2
|
+
import { GridCSSVars } from '@genesislcap/grid-tabulator';
|
|
3
|
+
export declare const themeGenesisRapidTokenMap: CSSVarTokenMap<GridCSSVars | string>;
|
|
4
|
+
export declare const themeGenesisRapidName = "tabulator-theme-genesis-rapid";
|
|
5
|
+
export declare const themeGenesisRapid: import("@microsoft/fast-element").ElementStyles;
|
|
6
|
+
export declare const themeGenesisRapidDarkName = "tabulator-theme-genesis-rapid-dark";
|
|
7
|
+
export declare const themeGenesisRapidDark: import("@microsoft/fast-element").ElementStyles;
|
|
8
|
+
//# sourceMappingURL=theme-genesis-rapid.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-genesis-rapid.d.ts","sourceRoot":"","sources":["../../../../src/themes/genesis-rapid/theme-genesis-rapid.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAC5D,OAAO,EAAoB,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAO5E,eAAO,MAAM,yBAAyB,EAAE,cAAc,CAAC,WAAW,GAAG,MAAM,CAc1E,CAAC;AAEF,eAAO,MAAM,qBAAqB,kCAAkC,CAAC;AAErE,eAAO,MAAM,iBAAiB,iDAO7B,CAAC;AAEF,eAAO,MAAM,yBAAyB,uCAAuC,CAAC;AAE9E,eAAO,MAAM,qBAAqB,iDA0DjC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/themes/index.ts"],"names":[],"mappings":"AAAA,cAAc,qCAAqC,CAAC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { ActionRenderer, tabulatorActionRendererStyles } from '@genesislcap/grid-tabulator';
|
|
2
|
+
import { css, html } from '@microsoft/fast-element';
|
|
3
|
+
/**
|
|
4
|
+
* @tagname %%prefix%%-grid-tabulator-action-renderer
|
|
5
|
+
*/
|
|
6
|
+
export class RapidTabulatorActionRenderer extends ActionRenderer {
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* The Rapid Action Renderer
|
|
10
|
+
*
|
|
11
|
+
* @public
|
|
12
|
+
* @remarks
|
|
13
|
+
* HTML Element: \<rapid-grid-tabulator-action-renderer\>
|
|
14
|
+
*/
|
|
15
|
+
export const rapidTabulatorActionRenderer = RapidTabulatorActionRenderer.compose({
|
|
16
|
+
baseName: 'grid-tabulator-action-renderer',
|
|
17
|
+
styles: css `
|
|
18
|
+
${tabulatorActionRendererStyles}
|
|
19
|
+
`,
|
|
20
|
+
template: html `
|
|
21
|
+
<div class="action-container" part="action-container">
|
|
22
|
+
<rapid-button
|
|
23
|
+
class="action-renderer"
|
|
24
|
+
part="action-renderer"
|
|
25
|
+
aria-label=${(x) => x.params.actionName}
|
|
26
|
+
data-test-id="${(x) => x.dataTestId}"
|
|
27
|
+
?disabled=${(x) => x.pendingAction}
|
|
28
|
+
appearance="${(x) => x.params.appearance}"
|
|
29
|
+
@click=${(x) => x.clickHandler()}
|
|
30
|
+
>
|
|
31
|
+
${(x) => x.params.contentTemplate
|
|
32
|
+
? html `
|
|
33
|
+
${x.params.contentTemplate}
|
|
34
|
+
`
|
|
35
|
+
: x.params.actionName}
|
|
36
|
+
</rapid-button>
|
|
37
|
+
</div>
|
|
38
|
+
`,
|
|
39
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './action.renderer';
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
// import {
|
|
2
|
+
// rapidAgActionRenderer,
|
|
3
|
+
// rapidAgActionsMenuRenderer,
|
|
4
|
+
// rapidAgBooleanRenderer,
|
|
5
|
+
// rapidAgSelectRenderer,
|
|
6
|
+
// rapidAgTextRenderer,
|
|
7
|
+
// } from './cell-renderers';
|
|
8
|
+
import { rapidGridTabulator } from './grid-tabulator';
|
|
9
|
+
export const rapidGridTabulatorComponents = {
|
|
10
|
+
// rapidAgActionRenderer,
|
|
11
|
+
// rapidAgActionsMenuRenderer,
|
|
12
|
+
// rapidAgBooleanRenderer,
|
|
13
|
+
// rapidAgTextRenderer,
|
|
14
|
+
// rapidAgSelectRenderer,
|
|
15
|
+
rapidGridTabulator,
|
|
16
|
+
register(container, ...rest) {
|
|
17
|
+
if (!container) {
|
|
18
|
+
// preserve backward compatibility with code that loops through
|
|
19
|
+
// the values of this object and calls them as funcs with no args
|
|
20
|
+
return;
|
|
21
|
+
}
|
|
22
|
+
for (const key in this) {
|
|
23
|
+
if (key === 'register') {
|
|
24
|
+
continue;
|
|
25
|
+
}
|
|
26
|
+
this[key]().register(container, ...rest);
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { GridTabulator, defaultGridTabulatorConfig, gridTabulatorShadowOptions, } from '@genesislcap/grid-tabulator';
|
|
2
|
+
import { rapidGridTabulatorStyles as styles } from './grid-tabulator.styles';
|
|
3
|
+
import { rapidGridTabulatorTemplate as template } from './grid-tabulator.template';
|
|
4
|
+
import { themeGenesisRapidDarkName, themeGenesisRapidName } from './themes';
|
|
5
|
+
const defaultRowHeaderHeight = 40;
|
|
6
|
+
const defaultRapidTheme = 'tabulator-theme-genesis-rapid-dark';
|
|
7
|
+
/**
|
|
8
|
+
* @tagname %%prefix%%-grid-tabulator
|
|
9
|
+
*/
|
|
10
|
+
export class RapidGridTabulator extends GridTabulator {
|
|
11
|
+
constructor() {
|
|
12
|
+
super(...arguments);
|
|
13
|
+
/**
|
|
14
|
+
* Sets default theme to Rapid
|
|
15
|
+
* @override
|
|
16
|
+
*/
|
|
17
|
+
this.theme = defaultRapidTheme;
|
|
18
|
+
}
|
|
19
|
+
themeChanged(oldValue, newValue) {
|
|
20
|
+
if (!oldValue && newValue !== defaultRapidTheme)
|
|
21
|
+
return;
|
|
22
|
+
super.themeChanged(oldValue, newValue);
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Gets the grid options
|
|
26
|
+
*/
|
|
27
|
+
get gridOptions() {
|
|
28
|
+
return super.gridOptions;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Handles extra RAPID configs and options
|
|
32
|
+
* @override
|
|
33
|
+
*/
|
|
34
|
+
set gridOptions(options) {
|
|
35
|
+
// options.components = {
|
|
36
|
+
// [GridTabulatorRendererTypes.action]: RapidAgActionRenderer,
|
|
37
|
+
// [GridTabulatorRendererTypes.actionsMenu]: RapidAgActionsMenuRenderer,
|
|
38
|
+
// [GridTabulatorRendererTypes.boolean]: RapidBooleanRenderer,
|
|
39
|
+
// };
|
|
40
|
+
var _a;
|
|
41
|
+
const isRapidTheme = this.theme === themeGenesisRapidName || this.theme === themeGenesisRapidDarkName;
|
|
42
|
+
if (isRapidTheme) {
|
|
43
|
+
// this.headerHeight = options.headerHeight ?? defaultRowHeaderHeight;
|
|
44
|
+
this.rowHeight = (_a = options.rowHeight) !== null && _a !== void 0 ? _a : defaultRowHeaderHeight;
|
|
45
|
+
}
|
|
46
|
+
super.gridOptions = options;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
// explicitly declaring for extensibility
|
|
50
|
+
export const rapidGridTabulatorShadowOptions = gridTabulatorShadowOptions;
|
|
51
|
+
export const rapidGridTabulatorDefaultConfig = defaultGridTabulatorConfig;
|
|
52
|
+
export const rapidGridTabulator = RapidGridTabulator.compose(Object.assign({ baseName: 'grid-tabulator', template,
|
|
53
|
+
styles, shadowOptions: rapidGridTabulatorShadowOptions }, rapidGridTabulatorDefaultConfig));
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// import { gridTabulatorStyles } from '@genesislcap/grid-tabulator';
|
|
2
|
+
import { css } from '@microsoft/fast-element';
|
|
3
|
+
import { themeGenesisRapid, themeGenesisRapidDark } from './themes';
|
|
4
|
+
export const rapidGridTabulatorStyles = css `
|
|
5
|
+
/* All the Tabulator themes */
|
|
6
|
+
|
|
7
|
+
/* gridTabulatorStyles */
|
|
8
|
+
|
|
9
|
+
/* 100% custom, CSS based, our own name: tabulator-theme-genesis-rapid */
|
|
10
|
+
${themeGenesisRapid}
|
|
11
|
+
${themeGenesisRapidDark}
|
|
12
|
+
|
|
13
|
+
:host {
|
|
14
|
+
width: 100%;
|
|
15
|
+
height: 100%;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
#grid {
|
|
19
|
+
height: 100%;
|
|
20
|
+
}
|
|
21
|
+
`;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * from './grid-tabulator';
|
|
2
|
+
export * from './grid-tabulator.styles';
|
|
3
|
+
export * from './grid-tabulator.template';
|
|
4
|
+
export * from './cell-renderers';
|
|
5
|
+
export * from './themes';
|
|
6
|
+
export * from './style';
|
|
7
|
+
export * from './grid-components';
|
|
8
|
+
export * from '@genesislcap/grid-tabulator';
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { parseColorHexRGB } from '@microsoft/fast-colors';
|
|
2
|
+
import { SwatchRGB } from '@microsoft/fast-components';
|
|
3
|
+
export const darkColors = {
|
|
4
|
+
foregroundSwatch: SwatchRGB.from(parseColorHexRGB('#cccccc')),
|
|
5
|
+
headerForegroundSwatch: SwatchRGB.from(parseColorHexRGB('#879ba6')),
|
|
6
|
+
backgroundSwatch: SwatchRGB.from(parseColorHexRGB('#1f2126')),
|
|
7
|
+
borderSwatch: SwatchRGB.from(parseColorHexRGB('#2e3339')),
|
|
8
|
+
rowHoverSwatch: SwatchRGB.from(parseColorHexRGB('#2b2e34')),
|
|
9
|
+
};
|
|
10
|
+
export const lightColors = {
|
|
11
|
+
foregroundSwatch: SwatchRGB.from(parseColorHexRGB('#000000')),
|
|
12
|
+
headerForegroundSwatch: SwatchRGB.from(parseColorHexRGB('#181d1f')),
|
|
13
|
+
backgroundSwatch: SwatchRGB.from(parseColorHexRGB('#FFFFFF')),
|
|
14
|
+
borderSwatch: SwatchRGB.from(parseColorHexRGB('#babfc7')),
|
|
15
|
+
rowHoverSwatch: SwatchRGB.from(parseColorHexRGB('#2196f3')),
|
|
16
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { baseLayerLuminance, StandardLuminance } from '@microsoft/fast-components';
|
|
2
|
+
import { DesignToken } from '@microsoft/fast-foundation';
|
|
3
|
+
import { darkColors, lightColors } from './colors';
|
|
4
|
+
const { create } = DesignToken;
|
|
5
|
+
export const gridThemeGenesisRapidTokens = {
|
|
6
|
+
backgroundColor: create('rapid-grid-background-color').withDefault((elem) => baseLayerLuminance.getValueFor(elem) === StandardLuminance.LightMode
|
|
7
|
+
? lightColors.backgroundSwatch
|
|
8
|
+
: darkColors.backgroundSwatch),
|
|
9
|
+
borderColor: create('rapid-grid-border-color').withDefault((elem) => baseLayerLuminance.getValueFor(elem) === StandardLuminance.LightMode
|
|
10
|
+
? lightColors.borderSwatch
|
|
11
|
+
: darkColors.borderSwatch),
|
|
12
|
+
foregroundColor: create('rapid-grid-foreground-color').withDefault((elem) => baseLayerLuminance.getValueFor(elem) === StandardLuminance.LightMode
|
|
13
|
+
? lightColors.foregroundSwatch
|
|
14
|
+
: darkColors.foregroundSwatch),
|
|
15
|
+
headerForegroundColor: create('rapid-grid-header-foreground-color').withDefault((elem) => baseLayerLuminance.getValueFor(elem) === StandardLuminance.LightMode
|
|
16
|
+
? lightColors.headerForegroundSwatch
|
|
17
|
+
: darkColors.headerForegroundSwatch),
|
|
18
|
+
rowHoverColor: create('rapid-grid-row-hover-color').withDefault((elem) => baseLayerLuminance.getValueFor(elem) === StandardLuminance.LightMode
|
|
19
|
+
? lightColors.rowHoverSwatch
|
|
20
|
+
: darkColors.rowHoverSwatch),
|
|
21
|
+
};
|