Skip to content

Commit 5b16e94

Browse files
Added Chart Demos (#32)
1 parent 96b610a commit 5b16e94

File tree

114 files changed

+36293
-2666
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

114 files changed

+36293
-2666
lines changed

wc-grid-examples-react.yml renamed to azure-pipelines/igniteui-react-grid-examples.yml

Lines changed: 40 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -39,41 +39,46 @@ stages:
3939
inputs:
4040
targetType: 'inline'
4141
script: |
42-
# Define the root path where projects are located
43-
rootPath="$(Build.SourcesDirectory)/projects"
44-
45-
# Get all first-level subdirectories in the specified root path
46-
subdirectories=$(find "$rootPath" -mindepth 1 -maxdepth 1 -type d)
47-
48-
for subdirectory in $subdirectories; do
49-
# Extract the directory name from the path
50-
dirName=$(basename "$subdirectory")
51-
52-
# Give each sample a version in its package.json file - for traceability
53-
cd "$subdirectory"
54-
echo "Calling npm version command"
55-
npm version $(Build.BuildNumber) --no-git-tag-version
56-
57-
# Check if the directory name is already camel-case
58-
if [[ "$dirName" =~ ^[A-Z]+[a-z]+([A-Z][a-z]*)*$ ]]; then
59-
# If already camel-case, print it as is
60-
echo "$dirName"
61-
else
62-
# Convert to camel-case (capitalize first letters and remove hyphens)
63-
dirName=$(echo "$dirName" | sed -E 's/(^|-)([a-z])/\U\2/g')
64-
65-
fi
66-
67-
echo "Processing directory: $dirName"
68-
69-
# Define the name for the zip file
70-
zipName="$(Build.ArtifactStagingDirectory)/IgniteUI_Grid_Demos_React_${dirName}_Source.zip"
71-
echo "Creating ZIP: $zipName"
72-
73-
# Compress the directory into a ZIP file
74-
(cd "$subdirectory" && zip -r "$zipName" .)
75-
done
76-
42+
create_zips() {
43+
local rootPath="$1"
44+
if [ -d "$rootPath" ]; then
45+
# Get all first-level subdirectories in the specified root path
46+
subdirectories=$(find "$rootPath" -mindepth 1 -maxdepth 1 -type d)
47+
for subdirectory in $subdirectories; do
48+
# Extract the directory name from the path
49+
dirName=$(basename "$subdirectory")
50+
51+
# Give each sample a version in its package.json file - for traceability
52+
cd "$subdirectory"
53+
echo "Setting project version in package.json to $(Build.BuildNumber) for $dirName"
54+
npm version $(Build.BuildNumber) --no-git-tag-version
55+
56+
# Check if the directory name is already camel-case
57+
if [[ "$dirName" =~ ^[A-Z]+[a-z]+([A-Z][a-z]*)*$ ]]; then
58+
# If already camel-case, print it as is
59+
echo "$dirName"
60+
else
61+
# Convert to camel-case (capitalize first letters and remove hyphens)
62+
dirName=$(echo "$dirName" | sed -E 's/(^|-)([a-z])/\U\2/g')
63+
fi
64+
65+
echo "Processing directory: $dirName"
66+
# Define the name for the zip file
67+
zipName="$(Build.ArtifactStagingDirectory)/IgniteUI_Grid_Demos_React_${dirName}_Source.zip"
68+
echo "Creating ZIP: $zipName"
69+
70+
# Compress the directory into a ZIP file
71+
(cd "$subdirectory" && zip -r "$zipName" .)
72+
done
73+
fi
74+
}
75+
76+
# Pass 1: All first-level directories in projects/
77+
create_zips "$(Build.SourcesDirectory)/projects"
78+
79+
# Pass 2: All first-level directories in projects/charts/
80+
create_zips "$(Build.SourcesDirectory)/projects/charts"
81+
7782
echo "All sample projects have been compressed and saved to the artifacts directory."
7883
7984
- task: PublishPipelineArtifact@1

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
content="width=device-width, initial-scale=1, shrink-to-fit=no"
99
/>
1010
<meta name="theme-color" content="#000000" />
11-
<title>grid landing pages</title>
11+
<title>Demos Landing Pages</title>
1212
<link rel="stylesheet" href="./styles.css">
1313
<link href='https://fonts.googleapis.com/css?family=Titillium+Web:wght@300;400;600;700' rel='stylesheet'>
1414
<link href='https://fonts.googleapis.com/icon?family=Material+Icons' rel='stylesheet'>

package-lock.json

Lines changed: 43 additions & 41 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@
1616
"@igniteui/material-icons-extended": "^3.0.0",
1717
"element-internals-polyfill": "^1.3.10",
1818
"functions-have-names": "^1.2.3",
19-
"igniteui-react": "19.0.3",
20-
"igniteui-react-charts": "19.0.0",
21-
"igniteui-react-core": "19.0.0",
22-
"igniteui-react-grids": "19.0.3",
23-
"igniteui-react-maps": "19.0.0",
19+
"igniteui-react": "19.2.0",
20+
"igniteui-react-charts": "19.0.1",
21+
"igniteui-react-core": "19.0.1",
22+
"igniteui-react-grids": "19.2.0",
23+
"igniteui-react-maps": "19.0.1",
2424
"lit": "^3.3.0",
2525
"react": "^19.0.0",
2626
"react-app-polyfill": "^0.2.0",
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
pnpm-debug.log*
8+
lerna-debug.log*
9+
10+
node_modules
11+
dist
12+
dist-ssr
13+
*.local
14+
15+
# Editor directories and files
16+
.vscode/*
17+
!.vscode/extensions.json
18+
.idea
19+
.DS_Store
20+
*.suo
21+
*.ntvs*
22+
*.njsproj
23+
*.sln
24+
*.sw?
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# React + TypeScript + Vite
2+
3+
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
4+
5+
Currently, two official plugins are available:
6+
7+
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh
8+
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
9+
10+
## Expanding the ESLint configuration
11+
12+
If you are developing a production application, we recommend updating the configuration to enable type-aware lint rules:
13+
14+
```js
15+
export default tseslint.config({
16+
extends: [
17+
// Remove ...tseslint.configs.recommended and replace with this
18+
...tseslint.configs.recommendedTypeChecked,
19+
// Alternatively, use this for stricter rules
20+
...tseslint.configs.strictTypeChecked,
21+
// Optionally, add this for stylistic rules
22+
...tseslint.configs.stylisticTypeChecked,
23+
],
24+
languageOptions: {
25+
// other options...
26+
parserOptions: {
27+
project: ['./tsconfig.node.json', './tsconfig.app.json'],
28+
tsconfigRootDir: import.meta.dirname,
29+
},
30+
},
31+
})
32+
```
33+
34+
You can also install [eslint-plugin-react-x](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-x) and [eslint-plugin-react-dom](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-dom) for React-specific lint rules:
35+
36+
```js
37+
// eslint.config.js
38+
import reactX from 'eslint-plugin-react-x'
39+
import reactDom from 'eslint-plugin-react-dom'
40+
41+
export default tseslint.config({
42+
plugins: {
43+
// Add the react-x and react-dom plugins
44+
'react-x': reactX,
45+
'react-dom': reactDom,
46+
},
47+
rules: {
48+
// other rules...
49+
// Enable its recommended typescript rules
50+
...reactX.configs['recommended-typescript'].rules,
51+
...reactDom.configs.recommended.rules,
52+
},
53+
})
54+
```
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
import js from '@eslint/js'
2+
import globals from 'globals'
3+
import reactHooks from 'eslint-plugin-react-hooks'
4+
import reactRefresh from 'eslint-plugin-react-refresh'
5+
import tseslint from 'typescript-eslint'
6+
7+
export default tseslint.config(
8+
{ ignores: ['dist'] },
9+
{
10+
extends: [js.configs.recommended, ...tseslint.configs.recommended],
11+
files: ['**/*.{ts,tsx}'],
12+
languageOptions: {
13+
ecmaVersion: 2020,
14+
globals: globals.browser,
15+
},
16+
plugins: {
17+
'react-hooks': reactHooks,
18+
'react-refresh': reactRefresh,
19+
},
20+
rules: {
21+
...reactHooks.configs.recommended.rules,
22+
'react-refresh/only-export-components': [
23+
'warn',
24+
{ allowConstantExport: true },
25+
],
26+
},
27+
},
28+
)
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<!doctype html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8" />
5+
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
7+
<title> Bar Chart </title>
8+
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
9+
<link href="https://fonts.googleapis.com/css?family=Titillium+Web:300,400,600,700" rel="stylesheet">
10+
<link rel="stylesheet" href="./node_modules/igniteui-webcomponents-grids/grids/themes/light/material.css" />
11+
<link rel="stylesheet" href="./styles.scss" />
12+
</head>
13+
<body class="ig-scrollbar ig-typography">
14+
<div id="root"></div>
15+
<script type="module" src="/src/main.tsx"></script>
16+
</body>
17+
</html>

0 commit comments

Comments
 (0)