igniteui-cli 15.8.2 → 15.8.3-alpha.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.
Files changed (48) hide show
  1. package/lib/MultiTemplateComponent.d.ts +1 -1
  2. package/lib/TemplateManager.d.ts +1 -1
  3. package/lib/cli.d.ts +1 -1
  4. package/lib/cli.js +2 -2
  5. package/lib/commands/doc.js +1 -1
  6. package/lib/commands/list.js +1 -1
  7. package/lib/commands/types.d.ts +2 -2
  8. package/lib/commands/upgrade.js +4 -1
  9. package/lib/project-utility/GridHelper.d.ts +6 -2
  10. package/lib/templates/IgniteUIForReactTemplate.d.ts +9 -5
  11. package/lib/templates/IgniteUIForReactTemplate.js +2 -2
  12. package/lib/templates/IgniteUIForWebComponentsTemplate.d.ts +8 -4
  13. package/lib/templates/IgniteUIForWebComponentsTemplate.js +8 -4
  14. package/lib/templates/jQueryTemplate.d.ts +8 -4
  15. package/lib/templates/jQueryTemplate.js +1 -1
  16. package/package.json +5 -4
  17. package/templates/blazor/igb/projects/ai-config/files/skills/AGENTS.md +7 -2
  18. package/templates/blazor/igb/projects/ai-config/files/skills/igniteui-blazor-components/references/data-display.md +2 -2
  19. package/templates/blazor/igb/projects/ai-config/files/skills/igniteui-blazor-components/references/setup.md +1 -1
  20. package/templates/blazor/igb/projects/ai-config/files/skills/igniteui-blazor-generate-from-image-design/references/gotchas.md +1 -1
  21. package/templates/blazor/igb/projects/ai-config/files/skills/igniteui-blazor-grids/SKILL.md +1 -1
  22. package/templates/blazor/igb/projects/ai-config/files/skills/igniteui-blazor-grids/references/grid-migration.md +1 -1
  23. package/templates/blazor/igb/projects/ai-config/files/skills/igniteui-blazor-grids/references/types.md +1 -1
  24. package/templates/blazor/igb/projects/ai-config/files/skills/igniteui-blazor-theming/references/common-patterns.md +1 -1
  25. package/templates/blazor/igb/projects/ai-config/index.d.ts +1 -1
  26. package/templates/blazor/igb/projects/ai-config/index.js +1 -0
  27. package/templates/blazor/igb/projects/empty/index.d.ts +1 -1
  28. package/templates/jquery/js/projects/empty/index.js +1 -0
  29. package/templates/react/ReactTypeScriptFileUpdate.js +4 -4
  30. package/templates/react/igr-ts/projects/_base/index.d.ts +1 -1
  31. package/templates/react/igr-ts/projects/_base/index.js +1 -0
  32. package/templates/react/igr-ts/projects/ai-config/index.d.ts +1 -1
  33. package/templates/webcomponents/WebComponentsTypeScriptFileUpdate.js +2 -2
  34. package/templates/webcomponents/igc-ts/category-chart/default/files/src/app/__path__/__filePrefix__.test.ts +9 -0
  35. package/templates/webcomponents/igc-ts/category-chart/default/files/src/app/__path__/__filePrefix__.ts +37 -0
  36. package/templates/webcomponents/igc-ts/category-chart/default/index.d.ts +1 -0
  37. package/templates/webcomponents/igc-ts/category-chart/default/index.js +21 -0
  38. package/templates/webcomponents/igc-ts/category-chart/index.d.ts +1 -0
  39. package/templates/webcomponents/igc-ts/category-chart/index.js +12 -0
  40. package/templates/webcomponents/igc-ts/doughnut-chart/default/files/src/app/__path__/__filePrefix__.test.ts +9 -0
  41. package/templates/webcomponents/igc-ts/doughnut-chart/default/files/src/app/__path__/__filePrefix__.ts +52 -0
  42. package/templates/webcomponents/igc-ts/doughnut-chart/default/index.d.ts +1 -0
  43. package/templates/webcomponents/igc-ts/doughnut-chart/default/index.js +21 -0
  44. package/templates/webcomponents/igc-ts/doughnut-chart/index.d.ts +1 -0
  45. package/templates/webcomponents/igc-ts/doughnut-chart/index.js +12 -0
  46. package/templates/webcomponents/igc-ts/projects/_base/index.d.ts +4 -2
  47. package/templates/webcomponents/igc-ts/projects/ai-config/index.d.ts +1 -1
  48. package/templates/webcomponents/igc-ts/projects/ai-config/index.js +1 -0
@@ -7,7 +7,7 @@ export declare abstract class MultiTemplateComponent<T extends Template> impleme
7
7
  description: string;
8
8
  groupPriority: number;
9
9
  get templates(): T[];
10
- constructor(testType: any, templatesMap: Map<string, {
10
+ constructor(testType: new () => T, templatesMap: Map<string, {
11
11
  name: string;
12
12
  widget: string;
13
13
  }>);
@@ -6,5 +6,5 @@ export declare class TemplateManager extends BaseTemplateManager {
6
6
  * @param filePath Path to a json config file representing a template
7
7
  * @returns null if no proper file is found
8
8
  */
9
- protected loadFromConfig(filePath: string): Template;
9
+ protected loadFromConfig(filePath: string): Template | null;
10
10
  }
package/lib/cli.d.ts CHANGED
@@ -1 +1 @@
1
- export declare function run(args?: any): Promise<void>;
1
+ export declare function run(args: string | string[]): Promise<void>;
package/lib/cli.js CHANGED
@@ -25,8 +25,8 @@ function logHelp() {
25
25
  cd: "$ig help"
26
26
  });
27
27
  }
28
- function run() {
29
- return __awaiter(this, arguments, void 0, function* (args = null) {
28
+ function run(args) {
29
+ return __awaiter(this, void 0, void 0, function* () {
30
30
  cli_core_1.App.initialize();
31
31
  const templateManager = new TemplateManager_1.TemplateManager();
32
32
  cli_core_1.App.container.set(cli_core_1.TEMPLATE_MANAGER, templateManager);
@@ -46,7 +46,7 @@ const doc = {
46
46
  },
47
47
  open: (target) => __awaiter(void 0, void 0, void 0, function* () {
48
48
  const open = yield Promise.resolve().then(() => __importStar(require("open")));
49
- open.default.call(target);
49
+ yield open.default(target);
50
50
  }),
51
51
  handler(argv) {
52
52
  return __awaiter(this, void 0, void 0, function* () {
@@ -40,7 +40,7 @@ const command = {
40
40
  }
41
41
  return listAllFrameworks();
42
42
  }
43
- const templatesByGroup = [];
43
+ const templatesByGroup = {};
44
44
  const controlGroups = [];
45
45
  const templateManager = cli_core_1.App.container.get(cli_core_1.TEMPLATE_MANAGER);
46
46
  const framework = templateManager.getFrameworkById(argv.framework);
@@ -30,7 +30,7 @@ export interface PositionalArgs {
30
30
  }
31
31
  export interface CommandType extends CommandModule<{}, any> {
32
32
  /** Handler function that will be called by yargs after the command line has been parsed. */
33
- handler(/** do not use `this` in handler */ this: void, argv: ArgumentsCamelCase<PositionalArgs>): any;
33
+ handler(/** do not use `this` in handler */ this: void, argv: ArgumentsCamelCase<PositionalArgs>): void | Promise<void>;
34
34
  }
35
35
  export interface NewCommandType extends CommandType {
36
36
  /** Adds choices to the `builder.framework` option. */
@@ -62,7 +62,7 @@ export interface ConfigCommandType extends CommandType {
62
62
  }
63
63
  export interface DocCommandType extends CommandType {
64
64
  /** Uses the `open` package to open a URL, file etc. */
65
- open(string: any): void;
65
+ open(target: string): void;
66
66
  }
67
67
  export interface TestCommandType extends CommandType {
68
68
  /** Executes tests. */
@@ -66,7 +66,10 @@ const command = {
66
66
  if (projectType === "igx-ts" || projectType === "igr-ts" || projectType === "igc-ts") {
67
67
  const templateManager = cli_core_1.App.container.get(cli_core_1.TEMPLATE_MANAGER);
68
68
  const projectLibrary = templateManager.getProjectLibrary(framework, projectType);
69
- const project = (0, cli_core_1.resolveUpgradeableProject)(projectLibrary, (_c = config.project) === null || _c === void 0 ? void 0 : _c.projectTemplate);
69
+ // a framework and project type that don't match each other resolve to no library
70
+ const project = projectLibrary
71
+ ? (0, cli_core_1.resolveUpgradeableProject)(projectLibrary, (_c = config.project) === null || _c === void 0 ? void 0 : _c.projectTemplate)
72
+ : null;
70
73
  if (!project) {
71
74
  cli_core_1.Util.error("No valid Ignite UI project template found to upgrade packages.", "red");
72
75
  return;
@@ -21,8 +21,12 @@ export declare class GridHelper {
21
21
  */
22
22
  constructor();
23
23
  generateFeatures(gridFeatures: string[], pad?: number): string;
24
- addFeature(name: any, overrideOptions?: any): void;
25
- updateFeature(name: any, overrideOptions: any): void;
24
+ addFeature(name: string, overrideOptions?: {
25
+ [key: string]: unknown;
26
+ } | null): void;
27
+ updateFeature(name: string, overrideOptions: {
28
+ [key: string]: unknown;
29
+ }): void;
26
30
  /**
27
31
  * Returns and object like `{name: "feature"}` with any other default properties
28
32
  * @param name Feature name
@@ -13,21 +13,25 @@ export declare class IgniteUIForReactTemplate implements Template {
13
13
  projectType: string;
14
14
  hasExtraConfiguration: boolean;
15
15
  isHidden: boolean;
16
- packages: any[];
17
- delimiters: import("@igniteui/cli-core").TemplateDelimiters;
18
- protected widget: string;
16
+ packages: string[];
17
+ delimiters: Required<import("@igniteui/cli-core").TemplateDelimiters>;
18
+ protected widget?: string;
19
19
  /**
20
20
  * Base ReactTemplate constructor
21
21
  * @param rootPath The template folder path. Pass in `__dirname`
22
22
  */
23
23
  constructor(rootPath: string);
24
24
  get templatePaths(): string[];
25
- generateConfig(name: string, options: {}): {
25
+ generateConfig(name: string, options?: {
26
+ [key: string]: any;
27
+ }): {
26
28
  [key: string]: any;
27
29
  };
28
30
  registerInProject(projectPath: string, name: string, options?: AddTemplateArgs, defaultPath?: boolean): void;
29
31
  getExtraConfiguration(): ControlExtraConfiguration[];
30
- setExtraConfiguration(extraConfigKeys: {}): void;
32
+ setExtraConfiguration(extraConfigKeys: {
33
+ [key: string]: unknown;
34
+ }): void;
31
35
  protected folderName(pathName: string): string;
32
36
  protected fileName(pathName: string): string;
33
37
  }
@@ -47,7 +47,7 @@ class IgniteUIForReactTemplate {
47
47
  get templatePaths() {
48
48
  return [path.join(this.rootPath, "files")];
49
49
  }
50
- generateConfig(name, options) {
50
+ generateConfig(name, options = {}) {
51
51
  let config = {};
52
52
  if (options["extraConfig"]) {
53
53
  config = options["extraConfig"];
@@ -66,7 +66,7 @@ class IgniteUIForReactTemplate {
66
66
  }
67
67
  return config;
68
68
  }
69
- registerInProject(projectPath, name, options, defaultPath = false) {
69
+ registerInProject(projectPath, name, options = {}, defaultPath = false) {
70
70
  if (!options.parentName) {
71
71
  options.parentName = "app";
72
72
  }
@@ -12,17 +12,21 @@ export declare class IgniteUIForWebComponentsTemplate implements Template {
12
12
  projectType: string;
13
13
  hasExtraConfiguration: boolean;
14
14
  isHidden: boolean;
15
- packages: any[];
15
+ packages: string[];
16
16
  dependencies: TemplateDependency[];
17
- delimiters: import("@igniteui/cli-core").TemplateDelimiters;
17
+ delimiters: Required<import("@igniteui/cli-core").TemplateDelimiters>;
18
18
  get templatePaths(): string[];
19
19
  constructor(rootPath: string);
20
- generateConfig(name: string, options: {}): {
20
+ generateConfig(name: string, options?: {
21
+ [key: string]: any;
22
+ }): {
21
23
  [key: string]: any;
22
24
  };
23
25
  registerInProject(projectPath: string, fullName: string, options?: AddTemplateArgs, defaultPath?: boolean): void;
24
26
  getExtraConfiguration(): ControlExtraConfiguration[];
25
- setExtraConfiguration(extraConfigKeys: {}): void;
27
+ setExtraConfiguration(extraConfigKeys: {
28
+ [key: string]: unknown;
29
+ }): void;
26
30
  protected getBaseVariables(name: string): {
27
31
  [key: string]: string;
28
32
  };
@@ -43,21 +43,24 @@ class IgniteUIForWebComponentsTemplate {
43
43
  this.dependencies = [];
44
44
  this.delimiters = cli_core_1.defaultDelimiters;
45
45
  }
46
- generateConfig(name, options) {
46
+ generateConfig(name, options = {}) {
47
47
  if (options["modulePath"] && !cli_core_1.Util.fileExists(path.join(process.cwd(), `src\\app`, options["modulePath"]))) {
48
48
  cli_core_1.Util.error(`Wrong module path provided: ${options["modulePath"]}. No components were added!`);
49
49
  return Promise.resolve(false);
50
50
  }
51
51
  return Object.assign({}, options["extraConfig"], this.getBaseVariables(name));
52
52
  }
53
- registerInProject(projectPath, fullName, options, defaultPath = false) {
53
+ registerInProject(projectPath, fullName, options = {}, defaultPath = false) {
54
54
  if (!options.parentName) {
55
- return;
55
+ options.parentName = "app";
56
+ }
57
+ if (!options.parentRoutingModulePath) {
58
+ options.parentRoutingModulePath = "src/app/app-routing.ts";
56
59
  }
57
60
  const routeModulePath = options.parentRoutingModulePath;
58
- const routingModule = new WebComponentsTypeScriptFileUpdate_1.WebComponentsTypeScriptFileUpdate(path.join(projectPath, routeModulePath), { convertTabsToSpaces: true, indentSize: 2, singleQuotes: true });
59
61
  if (!(options && options.skipRoute) &&
60
62
  cli_core_1.App.container.get(cli_core_1.FS_TOKEN).fileExists(routeModulePath)) {
63
+ const routingModule = new WebComponentsTypeScriptFileUpdate_1.WebComponentsTypeScriptFileUpdate(path.join(projectPath, routeModulePath), { convertTabsToSpaces: true, indentSize: 2, singleQuotes: true });
61
64
  const modulePath = `./${cli_core_1.Util.lowerDashed(fullName)}/${cli_core_1.Util.lowerDashed(fullName)}-routing`;
62
65
  const componentTag = `app-${this.fileName(fullName)}`;
63
66
  const child = {
@@ -101,6 +104,7 @@ class IgniteUIForWebComponentsTemplate {
101
104
  config["filePrefix"] = this.fileName(name);
102
105
  config["description"] = this.description;
103
106
  config["cliVersion"] = cli_core_1.Util.version();
107
+ // component names are validated as non-empty before templates run
104
108
  config["camelCaseName"] = cli_core_1.Util.camelCase(name);
105
109
  config["dockManagerPackage"] = (0, cli_core_1.resolvePackage)(cli_core_1.NPM_DOCK_MANAGER);
106
110
  return config;
@@ -16,13 +16,15 @@ export declare class jQueryTemplate implements Template {
16
16
  projectType: string;
17
17
  hasExtraConfiguration: boolean;
18
18
  isHidden: boolean;
19
- packages: any[];
20
- delimiters: import("@igniteui/cli-core").TemplateDelimiters;
19
+ packages: string[];
20
+ delimiters: Required<import("@igniteui/cli-core").TemplateDelimiters>;
21
21
  private configFile;
22
22
  private replacePattern;
23
23
  constructor(rootPath: string);
24
24
  get templatePaths(): string[];
25
- generateConfig(name: string, options: {}): {
25
+ generateConfig(name: string, options?: {
26
+ [key: string]: any;
27
+ }): {
26
28
  [key: string]: any;
27
29
  };
28
30
  /**
@@ -32,7 +34,9 @@ export declare class jQueryTemplate implements Template {
32
34
  */
33
35
  registerInProject(projectPath: string, name: string, options?: AddTemplateArgs): void;
34
36
  getExtraConfiguration(): ControlExtraConfiguration[];
35
- setExtraConfiguration(extraConfigKeys: {}): void;
37
+ setExtraConfiguration(extraConfigKeys: {
38
+ [key: string]: unknown;
39
+ }): void;
36
40
  protected getJqueryDependenciesScriptTag(): string;
37
41
  protected getScriptTags(): string;
38
42
  protected getNavigationScript(): string;
@@ -46,7 +46,7 @@ class jQueryTemplate {
46
46
  get templatePaths() {
47
47
  return [path.join(this.rootPath, "files")];
48
48
  }
49
- generateConfig(name, options) {
49
+ generateConfig(name, options = {}) {
50
50
  let config = {};
51
51
  if (options["extraConfig"]) {
52
52
  config = options["extraConfig"];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "igniteui-cli",
3
- "version": "15.8.2",
3
+ "version": "15.8.3-alpha.0",
4
4
  "description": "CLI tool for creating Ignite UI projects",
5
5
  "keywords": [
6
6
  "CLI",
@@ -66,9 +66,9 @@
66
66
  "all": true
67
67
  },
68
68
  "dependencies": {
69
- "@igniteui/angular-templates": "~22.2.1582",
70
- "@igniteui/cli-core": "~15.8.2",
71
- "@igniteui/mcp-server": "~15.8.2",
69
+ "@igniteui/angular-templates": "~22.2.1583-alpha.0",
70
+ "@igniteui/cli-core": "~15.8.3-alpha.0",
71
+ "@igniteui/mcp-server": "~15.8.3-alpha.0",
72
72
  "@inquirer/prompts": "^7.9.0",
73
73
  "chalk": "^5.3.0",
74
74
  "glob": "^11.0.0",
@@ -84,6 +84,7 @@
84
84
  "@schematics/angular": "^22.0.0",
85
85
  "@types/jasmine": "^5.1.4",
86
86
  "@types/node": "^22.5.5",
87
+ "@types/resolve": "^1.20.6",
87
88
  "@types/yargs": "^17.0.33",
88
89
  "browser-sync": "^3.0.3",
89
90
  "coveralls-next": "^4.2.1",
@@ -58,7 +58,12 @@ You are an expert in C#, Blazor, and scalable web application development. You w
58
58
  ## UI Components — Ignite UI for Blazor
59
59
 
60
60
  - **Packages**: `IgniteUI.Blazor.Lite` for general-purpose components and `IgniteUI.Blazor.GridLite` for the lightweight grid (both MIT, NuGet.org); `IgniteUI.Blazor` — publicly available for evaluation as `IgniteUI.Blazor.Trial` — for feature-rich grids, charts, maps, gauges, and Dock Manager. If the project already references the full `IgniteUI.Blazor`, do not add Lite or GridLite unless the user explicitly chooses to switch package strategy. If no Ignite UI package is present, add the one that matches the chosen strategy.
61
- - **Setup**: `builder.Services.AddIgniteUIBlazor()` in `Program.cs`, `@using IgniteUI.Blazor.Controls` in `_Imports.razor`, and one theme stylesheet in the host page. `IgniteUI.Blazor.Lite` loads its scripts itself (JS initializer); the full `IgniteUI.Blazor`/`.Trial` also needs `_content/IgniteUI.Blazor/app.bundle.js` before the Blazor script in Blazor Web Apps (so the library's client resources initialize correctly there) — never wrapped in `@Assets[...]`.
62
- - **Do not write Ignite UI component, property, or event names from memory** — the Blazor API differs from the Angular, React, and Web Components products. Use the `skills/` reference files and the `igniteui-cli` MCP server.
61
+ - **Setup**: `builder.Services.AddIgniteUIBlazor()` in `Program.cs`, `@using IgniteUI.Blazor.Controls` in `_Imports.razor`, and the theme stylesheet(s) in the host page (see **Theme stylesheets** below — full grids need two). `IgniteUI.Blazor.Lite` loads its scripts itself (JS initializer); the full `IgniteUI.Blazor`/`.Trial` also needs `_content/IgniteUI.Blazor/app.bundle.js` before the Blazor script in Blazor Web Apps (so the library's client resources initialize correctly there) — never wrapped in `@Assets[...]`.
62
+ - **Theme stylesheets** (the “one theme stylesheet” setup above excludes full grids, which require both stylesheets):
63
+ - Base theme: `_content/IgniteUI.Blazor/themes/<variant>/<theme>.css` (`<variant>` is `light` or `dark`; `<theme>` is `bootstrap`, `material`, `fluent`, or `indigo`).
64
+ - Full grids (`IgbGrid`, `IgbTreeGrid`, `IgbHierarchicalGrid`, `IgbPivotGrid`) also need `_content/IgniteUI.Blazor/themes/grid/<variant>/<theme>.css` in the same variant and theme. Without it the grid renders unstyled.
65
+ - `_content/IgniteUI.Blazor.GridLite/themes/<variant>/<theme>.css` is only for an app whose sole Ignite UI component is `IgbGridLite`. When other Ignite UI components are on the page, link the base theme instead and do not add the GridLite stylesheet.
66
+ - **Do not write Ignite UI component, property, or event names from memory** — the Blazor API differs from the Angular, React, and Web Components products. Use the `igniteui-cli` MCP server and the Ignite UI Blazor skills (`igniteui-blazor-components`, `igniteui-blazor-grids`, `igniteui-blazor-theming`) when they are installed. This file is meant to ship with those skills (https://github.com/IgniteUI/igniteui-blazor/tree/master/skills); if neither is available, use the official docs at https://www.infragistics.com/products/ignite-ui-blazor/blazor/components/general-getting-started.
67
+ - Handle `IgbButton` / `IgbIconButton` clicks with Blazor's `@onclick`; they have no `Click`/`OnClick` event parameter (`ClickAsync()` is a method that triggers a click programmatically).
63
68
  - Prefer the `Async` form of component methods (`ShowAsync()`, not `Show()`); the sync twins require an in-process JS runtime and throw on Blazor Server.
64
69
  - Style components with `--ig-*` design tokens on `igc-*` selectors, adding `::deep` in `.razor.css` files. Scope a theme to a page region with `IgbThemeProvider`.
@@ -100,7 +100,7 @@ The parameter is **`IconName`**, not `Name` (`Name` is the framework element ide
100
100
  }
101
101
  ```
102
102
 
103
- `AvatarShape`: `Circle | Rounded | Square` — use `Shape`, there is no `RoundShape`. `StyleVariant` (shared by badge and chip): `Primary | Info | Success | Warning | Danger`. `IgbChip` also has `Outlined`, `Selected` / `SelectedChanged` and a `Select` event.
103
+ `AvatarShape`: `Circle | Rounded | Square` — use `Shape`, there is no `RoundShape`. `StyleVariant` (shared by badge and chip): `Primary | Info | Success | Warning | Danger`; a chip without `Variant` has no color variant. `IgbChip` also has `Outlined`, `Selected` / `SelectedChanged` and a `Select` event.
104
104
 
105
105
  ## Progress
106
106
 
@@ -150,7 +150,7 @@ The trigger goes in `slot="target"`. `IgbDropdownGroup` groups items; `Placement
150
150
  LogoSrc="images/logo.svg" LogoSize="0.6" />
151
151
  ```
152
152
 
153
- Renders the `Value` string (URL, text, any payload) as a scannable SVG. `Version` (1-40) is chosen automatically when unset; `ErrorLevel` (`Low | Medium | Quartile | High`) defaults to `Medium` and should be raised explicitly when a larger logo needs more error correction. `Size` is the rendered pixel size and `Margin` the quiet zone in modules; `LogoSrc`, `LogoSize` and `LogoMargin` place a centered logo. Color it with the `--ig-qr-code-background`, `--ig-qr-code-dark-color`, `--ig-qr-code-corner-square-color` and `--ig-qr-code-corner-dot-color` custom properties.
153
+ Renders the `Value` string (URL, text, any payload) as a scannable SVG. `Version` (1-40) is chosen automatically when unset; `ErrorLevel` (`Low | Medium | Quartile | High`) is `null` by default, which leaves the web component's default level, and should be raised explicitly when a larger logo needs more error correction. `Size` is the rendered pixel size and `Margin` the quiet zone in modules; `LogoSrc`, `LogoSize` and `LogoMargin` place a centered logo. Color it with the `--ig-qr-code-background`, `--ig-qr-code-dark-color`, `--ig-qr-code-corner-square-color` and `--ig-qr-code-corner-dot-color` custom properties.
154
154
 
155
155
  `ToImageAsync(IgbQrCodeExportOptions)` exports the code as an image file (`Format`: `Svg | Png | Jpeg | Webp`, default `Png`; `Scale` multiplies `Size`; `FileName` defaults to `qr-code`). The exported file stays on the client and is always handed to the user through the browser save dialog — there is no way to read the file bytes back into .NET. The export fails when the component has no `Value`.
156
156
 
@@ -92,7 +92,7 @@ Theme files under `_content/IgniteUI.Blazor/themes/` are `{light|dark}/{bootstra
92
92
  `IgniteUI.Blazor.GridLite` ships its own stylesheet from its own asset root, but should be used only if you are using the GridLite component exclusively. If you are using other Ignite UI components, do not link (or suggest) the GridLite stylesheet — use the main theme stylesheet above instead.
93
93
 
94
94
  ```html
95
- <link href="_content/IgniteUI.Blazor.GridLite/css/themes/light/bootstrap.css" rel="stylesheet" />
95
+ <link href="_content/IgniteUI.Blazor.GridLite/themes/light/bootstrap.css" rel="stylesheet" />
96
96
  ```
97
97
 
98
98
  ## 5. Render mode (Blazor Web App only)
@@ -245,7 +245,7 @@ Switch both stylesheets together:
245
245
  ```html
246
246
  <link href="_content/IgniteUI.Blazor/themes/dark/bootstrap.css" rel="stylesheet" />
247
247
  <link href="_content/IgniteUI.Blazor/themes/grid/dark/bootstrap.css" rel="stylesheet" />
248
- <!-- IgbGridLite instead: _content/IgniteUI.Blazor.GridLite/css/themes/dark/bootstrap.css -->
248
+ <!-- IgbGridLite instead: _content/IgniteUI.Blazor.GridLite/themes/dark/bootstrap.css -->
249
249
  ```
250
250
 
251
251
  For a runtime toggle, prefer `IgbThemeProvider` (`Theme`, `Variant`) over swapping `<link href>` via JS interop — no interop and it can scope to a region.
@@ -60,7 +60,7 @@ Grids are **not** included in `IgniteUI.Blazor.Lite`.
60
60
  | Registration | `builder.Services.AddIgniteUIBlazor(typeof(IgbGridModule), …)` in `Program.cs` |
61
61
  | Using directive | `@using IgniteUI.Blazor.Controls` in `_Imports.razor` |
62
62
  | CSS — full grids | **both** `_content/IgniteUI.Blazor/themes/light/bootstrap.css` **and** `_content/IgniteUI.Blazor/themes/grid/light/bootstrap.css` |
63
- | CSS — Grid Lite | `_content/IgniteUI.Blazor.GridLite/css/themes/light/bootstrap.css` only — not the two above |
63
+ | CSS — Grid Lite | `_content/IgniteUI.Blazor.GridLite/themes/light/bootstrap.css` only — not the two above |
64
64
  | Script | None for `IgniteUI.Blazor.GridLite`; full grids (`IgniteUI.Blazor`/`.Trial`) need `_content/IgniteUI.Blazor/app.bundle.js` before the Blazor framework script in Blazor Web Apps (so the library's client resources initialize correctly there) — never wrapped in `@Assets[...]` |
65
65
 
66
66
  The grid-specific stylesheet is easy to miss and is required whenever any full-featured grid is on the page. Full setup detail lives in the components skill's [`setup.md`](../igniteui-blazor-components/references/setup.md).
@@ -18,7 +18,7 @@ Batch editing with undo is not supported in Blazor on either grid.
18
18
 
19
19
  ```html
20
20
  <!-- index.html / App.razor — Grid Lite ships one stylesheet, IgbGrid needs two -->
21
- - <link href="_content/IgniteUI.Blazor.GridLite/css/themes/light/bootstrap.css" rel="stylesheet" />
21
+ - <link href="_content/IgniteUI.Blazor.GridLite/themes/light/bootstrap.css" rel="stylesheet" />
22
22
  + <link href="_content/IgniteUI.Blazor/themes/light/bootstrap.css" rel="stylesheet" />
23
23
  + <link href="_content/IgniteUI.Blazor/themes/grid/light/bootstrap.css" rel="stylesheet" />
24
24
  ```
@@ -12,7 +12,7 @@ builder.Services.AddIgniteUIBlazor(typeof(IgbGridLiteModule));
12
12
  ```
13
13
 
14
14
  ```html
15
- <link href="_content/IgniteUI.Blazor.GridLite/css/themes/light/bootstrap.css" rel="stylesheet" />
15
+ <link href="_content/IgniteUI.Blazor.GridLite/themes/light/bootstrap.css" rel="stylesheet" />
16
16
  ```
17
17
 
18
18
  ```razor
@@ -21,7 +21,7 @@ If the page hosts any full-featured grid, add the grid stylesheet in the **same
21
21
  <link href="_content/IgniteUI.Blazor/themes/grid/light/bootstrap.css" rel="stylesheet" />
22
22
  ```
23
23
 
24
- `IgbGridLite` replaces both with its own: `_content/IgniteUI.Blazor.GridLite/css/themes/light/bootstrap.css`.
24
+ `IgbGridLite` replaces both with its own: `_content/IgniteUI.Blazor.GridLite/themes/light/bootstrap.css`.
25
25
 
26
26
  ## Switching theme at runtime
27
27
 
@@ -8,7 +8,7 @@ export declare class IgbAiConfigPartial implements ProjectTemplate {
8
8
  dependencies: string[];
9
9
  hasExtraConfiguration: boolean;
10
10
  isHidden: boolean;
11
- delimiters: import("@igniteui/cli-core").TemplateDelimiters;
11
+ delimiters: Required<import("@igniteui/cli-core").TemplateDelimiters>;
12
12
  get templatePaths(): string[];
13
13
  installModules(): void;
14
14
  upgradeIgniteUIPackages(_projectPath: string, _packagePath: string): Promise<boolean>;
@@ -35,6 +35,7 @@ class IgbAiConfigPartial {
35
35
  this.description = "Ignite UI CLI AI config for Blazor partial project files";
36
36
  this.framework = "blazor";
37
37
  this.projectType = "igb";
38
+ this.dependencies = [];
38
39
  this.hasExtraConfiguration = false;
39
40
  this.isHidden = true;
40
41
  this.delimiters = cli_core_1.defaultDelimiters;
@@ -8,7 +8,7 @@ export declare class EmptyIgbProject implements ProjectTemplate {
8
8
  dependencies: string[];
9
9
  hasExtraConfiguration: boolean;
10
10
  isHidden: boolean;
11
- delimiters: import("@igniteui/cli-core").TemplateDelimiters;
11
+ delimiters: Required<import("@igniteui/cli-core").TemplateDelimiters>;
12
12
  templatePaths: string[];
13
13
  private extraConfiguration;
14
14
  getExtraConfiguration(): ControlExtraConfiguration[];
@@ -40,6 +40,7 @@ class EmptyProject {
40
40
  this.id = "jquery";
41
41
  this.name = "jquery with Javascript";
42
42
  this.description = "Ignite UI CLI project for jQuery";
43
+ this.dependencies = [];
43
44
  this.framework = "jquery";
44
45
  this.projectType = "js";
45
46
  this.hasExtraConfiguration = false;
@@ -39,7 +39,7 @@ class ReactTypeScriptFileUpdate extends cli_core_1.TypeScriptFileUpdate {
39
39
  this.requestImportForRouteLoader(_route);
40
40
  }
41
41
  else {
42
- const routeName = cli_core_1.Util.lowerDashed(_route.name || _route.path);
42
+ const routeName = cli_core_1.Util.lowerDashed((_route.name || _route.path));
43
43
  const modulePath = `./${routeName}/${routeName}`;
44
44
  this.requestImportForRouteIdentifier(Object.assign(Object.assign({}, _route), { modulePath }), true // is default - for React, we import the component as `import X from 'module'`.
45
45
  );
@@ -75,13 +75,13 @@ class ReactTypeScriptFileUpdate extends cli_core_1.TypeScriptFileUpdate {
75
75
  },
76
76
  {
77
77
  name: types_1.ReactRouteTarget.Element,
78
- value: ts.factory.createJsxSelfClosingElement(ts.factory.createIdentifier(route.element || route.identifierName), undefined, // type arguments
79
- undefined // jsx attributes
78
+ value: ts.factory.createJsxSelfClosingElement(ts.factory.createIdentifier((route.element || route.identifierName)), undefined, // type arguments
79
+ ts.factory.createJsxAttributes([]) // jsx attributes
80
80
  ),
81
81
  },
82
82
  {
83
83
  name: types_1.ReactRouteTarget.Text,
84
- value: ts.factory.createStringLiteral(route.text || route.name, this.formatSettings.singleQuotes),
84
+ value: ts.factory.createStringLiteral((route.text || route.name), this.formatSettings.singleQuotes),
85
85
  },
86
86
  ];
87
87
  }
@@ -8,7 +8,7 @@ export declare class BaseIgrTsProject implements ProjectTemplate {
8
8
  dependencies: string[];
9
9
  hasExtraConfiguration: boolean;
10
10
  isHidden: boolean;
11
- delimiters: import("@igniteui/cli-core").TemplateDelimiters;
11
+ delimiters: Required<import("@igniteui/cli-core").TemplateDelimiters>;
12
12
  get templatePaths(): string[];
13
13
  generateConfig(name: string, theme: string, ...options: any[]): {
14
14
  [key: string]: any;
@@ -42,6 +42,7 @@ class BaseIgrTsProject {
42
42
  this.description = "Ignite UI CLI project for React";
43
43
  this.framework = "react";
44
44
  this.projectType = "tsx";
45
+ this.dependencies = [];
45
46
  this.hasExtraConfiguration = false;
46
47
  this.isHidden = true;
47
48
  this.delimiters = cli_core_1.defaultDelimiters;
@@ -8,7 +8,7 @@ export declare class IgrTsAiConfigPartial implements ProjectTemplate {
8
8
  dependencies: string[];
9
9
  hasExtraConfiguration: boolean;
10
10
  isHidden: boolean;
11
- delimiters: import("@igniteui/cli-core").TemplateDelimiters;
11
+ delimiters: Required<import("@igniteui/cli-core").TemplateDelimiters>;
12
12
  get templatePaths(): string[];
13
13
  generateConfig(_name: string, _theme: string, ..._options: any[]): {
14
14
  [key: string]: any;
@@ -33,7 +33,7 @@ class WebComponentsTypeScriptFileUpdate extends cli_core_1.TypeScriptFileUpdate
33
33
  }
34
34
  //#region Overridden Public API
35
35
  addRoute(route, multiline = false, prepend = true, anchorElement = cli_core_1.WC_ANCHOR_ELEMENT) {
36
- const routeName = cli_core_1.Util.lowerDashed(route.name || route.path);
36
+ const routeName = cli_core_1.Util.lowerDashed((route.name || route.path));
37
37
  this.requestSideEffectsImportForModule(`./${routeName}/${routeName}`);
38
38
  if (!route.lazyload) {
39
39
  this.requestImportForRouteIdentifier(route);
@@ -53,7 +53,7 @@ class WebComponentsTypeScriptFileUpdate extends cli_core_1.TypeScriptFileUpdate
53
53
  },
54
54
  {
55
55
  name: cli_core_1.RouteTarget.Component,
56
- value: ts.factory.createStringLiteral(route.aliasName || route.identifierName, this.formatSettings.singleQuotes),
56
+ value: ts.factory.createStringLiteral((route.aliasName || route.identifierName), this.formatSettings.singleQuotes),
57
57
  },
58
58
  {
59
59
  name: cli_core_1.RouteTarget.Name,
@@ -0,0 +1,9 @@
1
+ import { describe, it, expect } from 'vitest';
2
+ import $(ClassName) from './$(filePrefix).js';
3
+
4
+ describe('IgcCategoryChartComponent', () => {
5
+ it('<app-$(filePrefix)> is an instance of $(ClassName)', async () => {
6
+ const element = document.createElement('app-$(filePrefix)');
7
+ expect(element).to.be.instanceOf($(ClassName));
8
+ });
9
+ });
@@ -0,0 +1,37 @@
1
+ import { html, css, LitElement } from 'lit';
2
+ import { customElement } from 'lit/decorators.js';
3
+ import { IgcCategoryChartComponent, IgcCategoryChartModule } from 'igniteui-webcomponents-charts';
4
+ import { ModuleManager } from 'igniteui-webcomponents-core';
5
+
6
+ ModuleManager.register(IgcCategoryChartModule);
7
+
8
+ const data = [
9
+ { CountryName: 'China', Pop1995: 1216, Pop2005: 1297, Pop2015: 1361, Pop2025: 1394 },
10
+ { CountryName: 'India', Pop1995: 920, Pop2005: 1090, Pop2015: 1251, Pop2025: 1396 },
11
+ { CountryName: 'United States', Pop1995: 266, Pop2005: 295, Pop2015: 322, Pop2025: 351 },
12
+ { CountryName: 'Indonesia', Pop1995: 197, Pop2005: 229, Pop2015: 256, Pop2025: 277 },
13
+ { CountryName: 'Brazil', Pop1995: 161, Pop2005: 186, Pop2015: 204, Pop2025: 218 }
14
+ ];
15
+
16
+ @customElement('app-$(filePrefix)')
17
+ export default class $(ClassName) extends LitElement {
18
+ static styles = css`
19
+ :host {
20
+ display: block;
21
+ width: 100%;
22
+ }
23
+ `;
24
+
25
+ render() {
26
+ return html`
27
+ <igc-category-chart id="chart" width="100%" height="500px"
28
+ chart-title="Population per Country (millions)">
29
+ </igc-category-chart>
30
+ `;
31
+ }
32
+
33
+ firstUpdated() {
34
+ const chart = this.shadowRoot?.getElementById('chart') as IgcCategoryChartComponent;
35
+ chart.dataSource = data;
36
+ }
37
+ }
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const IgniteUIForWebComponentsTemplate_1 = require("../../../../../lib/templates/IgniteUIForWebComponentsTemplate");
4
+ const constants_1 = require("../../constants");
5
+ class IgcCategoryChartTemplate extends IgniteUIForWebComponentsTemplate_1.IgniteUIForWebComponentsTemplate {
6
+ constructor() {
7
+ super(__dirname);
8
+ this.components = ["CategoryChart"];
9
+ this.controlGroup = "Charts";
10
+ this.listInComponentTemplates = true;
11
+ this.id = "category-chart";
12
+ this.projectType = "igc-ts";
13
+ this.name = "Category Chart";
14
+ this.description = "makes visualizing category data easy";
15
+ this.packages = [
16
+ constants_1.IGNITEUI_WEBCOMPONENTS_CORE_PACKAGE,
17
+ constants_1.IGNITEUI_WEBCOMPONENTS_CHARTS_PACKAGE
18
+ ];
19
+ }
20
+ }
21
+ module.exports = new IgcCategoryChartTemplate();
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const cli_core_1 = require("@igniteui/cli-core");
4
+ class IgcCategoryChartComponent extends cli_core_1.BaseComponent {
5
+ constructor() {
6
+ super(__dirname);
7
+ this.name = "Category Chart";
8
+ this.group = "Charts";
9
+ this.description = "makes visualizing category data easy";
10
+ }
11
+ }
12
+ module.exports = new IgcCategoryChartComponent();
@@ -0,0 +1,9 @@
1
+ import { describe, it, expect } from 'vitest';
2
+ import $(ClassName) from './$(filePrefix).js';
3
+
4
+ describe('IgcDoughnutChartComponent', () => {
5
+ it('<app-$(filePrefix)> is an instance of $(ClassName)', async () => {
6
+ const element = document.createElement('app-$(filePrefix)');
7
+ expect(element).to.be.instanceOf($(ClassName));
8
+ });
9
+ });
@@ -0,0 +1,52 @@
1
+ import { html, css, LitElement } from 'lit';
2
+ import { customElement } from 'lit/decorators.js';
3
+ import {
4
+ IgcDoughnutChartModule,
5
+ IgcItemLegendComponent,
6
+ IgcItemLegendModule,
7
+ IgcRingSeriesComponent,
8
+ IgcRingSeriesModule,
9
+ } from 'igniteui-webcomponents-charts';
10
+ import { ModuleManager } from 'igniteui-webcomponents-core';
11
+
12
+ ModuleManager.register(
13
+ IgcDoughnutChartModule,
14
+ IgcItemLegendModule,
15
+ IgcRingSeriesModule,
16
+ );
17
+
18
+ const data = [
19
+ { MarketShare: 30, Company: 'Google' },
20
+ { MarketShare: 15, Company: 'Microsoft' },
21
+ { MarketShare: 30, Company: 'Apple' },
22
+ { MarketShare: 15, Company: 'Samsung' },
23
+ { MarketShare: 10, Company: 'Other' }
24
+ ];
25
+
26
+ @customElement('app-$(filePrefix)')
27
+ export default class $(ClassName) extends LitElement {
28
+ static styles = css`
29
+ :host {
30
+ display: block;
31
+ }
32
+ `;
33
+
34
+ render() {
35
+ return html`
36
+ <igc-item-legend id="legend" orientation="Horizontal"></igc-item-legend>
37
+ <igc-doughnut-chart width="400px" height="400px">
38
+ <igc-ring-series id="series"
39
+ name="ring1"
40
+ value-member-path="MarketShare"
41
+ label-member-path="Company">
42
+ </igc-ring-series>
43
+ </igc-doughnut-chart>
44
+ `;
45
+ }
46
+
47
+ firstUpdated() {
48
+ const series = this.shadowRoot?.getElementById('series') as IgcRingSeriesComponent;
49
+ series.dataSource = data;
50
+ series.legend = this.shadowRoot?.getElementById('legend') as IgcItemLegendComponent;
51
+ }
52
+ }
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const IgniteUIForWebComponentsTemplate_1 = require("../../../../../lib/templates/IgniteUIForWebComponentsTemplate");
4
+ const constants_1 = require("../../constants");
5
+ class IgcDoughnutChartTemplate extends IgniteUIForWebComponentsTemplate_1.IgniteUIForWebComponentsTemplate {
6
+ constructor() {
7
+ super(__dirname);
8
+ this.components = ["DoughnutChart"];
9
+ this.controlGroup = "Charts";
10
+ this.listInComponentTemplates = true;
11
+ this.id = "doughnut-chart";
12
+ this.projectType = "igc-ts";
13
+ this.name = "Doughnut Chart";
14
+ this.description = "proportionally illustrate the occurrences of variables";
15
+ this.packages = [
16
+ constants_1.IGNITEUI_WEBCOMPONENTS_CORE_PACKAGE,
17
+ constants_1.IGNITEUI_WEBCOMPONENTS_CHARTS_PACKAGE
18
+ ];
19
+ }
20
+ }
21
+ module.exports = new IgcDoughnutChartTemplate();
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const cli_core_1 = require("@igniteui/cli-core");
4
+ class IgcDoughnutChartComponent extends cli_core_1.BaseComponent {
5
+ constructor() {
6
+ super(__dirname);
7
+ this.name = "Doughnut Chart";
8
+ this.group = "Charts";
9
+ this.description = "proportionally illustrate the occurrences of variables";
10
+ }
11
+ }
12
+ module.exports = new IgcDoughnutChartComponent();
@@ -8,12 +8,14 @@ export declare class BaseIgcProject implements ProjectTemplate {
8
8
  projectType: string;
9
9
  hasExtraConfiguration: boolean;
10
10
  isHidden: boolean;
11
- delimiters: import("@igniteui/cli-core").TemplateDelimiters;
11
+ delimiters: Required<import("@igniteui/cli-core").TemplateDelimiters>;
12
12
  get templatePaths(): string[];
13
13
  installModules(): void;
14
14
  upgradeIgniteUIPackages(projectPath: string, packagePath: string): Promise<boolean>;
15
15
  getExtraConfiguration(): ControlExtraConfiguration[];
16
- setExtraConfiguration(extraConfigKeys: any[]): void;
16
+ setExtraConfiguration(extraConfigKeys: {
17
+ [key: string]: unknown;
18
+ }): void;
17
19
  generateConfig(name: string, theme: string, ...options: any[]): {
18
20
  [key: string]: any;
19
21
  };
@@ -8,7 +8,7 @@ export declare class IgcTsAiConfigPartial implements ProjectTemplate {
8
8
  dependencies: string[];
9
9
  hasExtraConfiguration: boolean;
10
10
  isHidden: boolean;
11
- delimiters: import("@igniteui/cli-core").TemplateDelimiters;
11
+ delimiters: Required<import("@igniteui/cli-core").TemplateDelimiters>;
12
12
  get templatePaths(): string[];
13
13
  installModules(): void;
14
14
  upgradeIgniteUIPackages(_projectPath: string, _packagePath: string): Promise<boolean>;
@@ -35,6 +35,7 @@ class IgcTsAiConfigPartial {
35
35
  this.description = "Ignite UI CLI AI config for Web Components partial project files";
36
36
  this.framework = "webcomponents";
37
37
  this.projectType = "igc-ts";
38
+ this.dependencies = [];
38
39
  this.hasExtraConfiguration = false;
39
40
  this.isHidden = true;
40
41
  this.delimiters = cli_core_1.defaultDelimiters;