@datarailsshared/dr_renderer 1.5.159 → 1.5.168

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 (32) hide show
  1. package/.idea/jsLibraryMappings.xml +6 -0
  2. package/.idea/misc.xml +9 -0
  3. package/.nvmrc +1 -0
  4. package/jest.config.js +1 -1
  5. package/package.json +9 -11
  6. package/scripts/check-versions.js +16 -0
  7. package/src/highcharts_renderer.d.ts +2 -2
  8. package/tsconfig.json +1 -1
  9. package/.circleci/config.yml +0 -85
  10. package/.github/workflows/ai-coder-jira.yml +0 -915
  11. package/.github/workflows/ai-coder-n8n-caller.yml +0 -82
  12. package/.github/workflows/release.yml +0 -49
  13. package/tests/__snapshots__/suboptions.test.js.snap +0 -5028
  14. package/tests/dr-renderer-helpers.test.js +0 -228
  15. package/tests/dr_chart_tooltip.test.js +0 -789
  16. package/tests/dr_gauge_chart.test.js +0 -2041
  17. package/tests/errors.test.js +0 -157
  18. package/tests/highcharts_renderer.test.js +0 -9407
  19. package/tests/mock/add-in-dynamic-ranges.json +0 -127
  20. package/tests/mock/add-in-functions.json +0 -410
  21. package/tests/mock/add-in-tables.json +0 -347
  22. package/tests/mock/tables.json +0 -2258
  23. package/tests/mock/widgets.json +0 -401
  24. package/tests/options-builder.test.js +0 -1698
  25. package/tests/pivot-table/freeze-panes/constants.test.js +0 -92
  26. package/tests/pivot-table/freeze-panes/index.test.js +0 -193
  27. package/tests/pivot-table/freeze-panes/sticky-strategy.test.js +0 -542
  28. package/tests/pivot-table/freeze-panes/transform-strategy.test.js +0 -304
  29. package/tests/ptCreateDrillDownSeriesToDrilldownChart.test.js +0 -509
  30. package/tests/seriesPointStyles-helper.test.js +0 -114
  31. package/tests/suboptions.test.js +0 -322
  32. package/tests/value.formatter.test.js +0 -143
@@ -0,0 +1,6 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="JavaScriptLibraryMappings">
4
+ <includedPredefinedLibrary name="Node.js Core" />
5
+ </component>
6
+ </project>
package/.idea/misc.xml ADDED
@@ -0,0 +1,9 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="PreferredVcsStorage">
4
+ <preferredVcsName>ApexVCS</preferredVcsName>
5
+ </component>
6
+ <component name="ProjectRootManager" version="2" languageLevel="JDK_1_9" project-jdk-name="9.0" project-jdk-type="JavaSDK">
7
+ <output url="file://$PROJECT_DIR$/out" />
8
+ </component>
9
+ </project>
package/.nvmrc ADDED
@@ -0,0 +1 @@
1
+ 18.18.2
package/jest.config.js CHANGED
@@ -9,7 +9,7 @@ module.exports = {
9
9
  ],
10
10
  collectCoverage: true,
11
11
  collectCoverageFrom: [
12
- '**/*.js',
12
+ 'src/**/*.js',
13
13
  '!**/*.config.js',
14
14
  '!**/build/**',
15
15
  '!**/coverage/**',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@datarailsshared/dr_renderer",
3
- "version": "1.5.159",
3
+ "version": "1.5.168",
4
4
  "description": "DataRails charts and tables renderer",
5
5
  "keywords": [
6
6
  "datarails",
@@ -8,7 +8,12 @@
8
8
  "charts",
9
9
  "tables"
10
10
  ],
11
+ "engines": {
12
+ "node": ">=18.18.2",
13
+ "npm": ">=9.0.0"
14
+ },
11
15
  "scripts": {
16
+ "preinstall": "node scripts/check-versions.js",
12
17
  "login": "npm login",
13
18
  "test": "jest --coverage",
14
19
  "build:types": "npx tsc --build --verbose",
@@ -19,7 +24,7 @@
19
24
  "author": "Sergey Spivakov",
20
25
  "repository": {
21
26
  "type": "git",
22
- "url": "git+https://bitbucket.org/datarails/dr_renderer.git"
27
+ "url": "git+https://github.com/Datarails/dr_renderer.git"
23
28
  },
24
29
  "license": "",
25
30
  "dependencies": {
@@ -39,7 +44,7 @@
39
44
  "typescript": "^5.0.0"
40
45
  },
41
46
  "types": "src/index.d.ts",
42
- "homepage": "https://bitbucket.org/datarails/dr_renderer/src/master/",
47
+ "homepage": "https://github.com/Datarails/dr_renderer",
43
48
  "whitelistedNonPeerDependencies": [],
44
49
  "main": "src/index.js",
45
50
  "module": "src/index.js",
@@ -52,12 +57,5 @@
52
57
  "./src/pivot.css": "./src/pivot.css",
53
58
  "./pivot.css": "./src/pivot.css"
54
59
  },
55
- "sideEffects": [
56
- "*.css"
57
- ],
58
- "jest": {
59
- "setupFiles": [
60
- "./setup-jest.js"
61
- ]
62
- }
60
+ "sideEffects": ["*.css"]
63
61
  }
@@ -0,0 +1,16 @@
1
+ #!/usr/bin/env node
2
+
3
+ const { execSync } = require('child_process');
4
+
5
+ const REQUIRED_NPM_MAJOR = 9;
6
+
7
+ const npmVersion = execSync('npm --version', { encoding: 'utf8' }).trim();
8
+ const npmMajor = parseInt(npmVersion.split('.')[0], 10);
9
+
10
+ if (npmMajor < REQUIRED_NPM_MAJOR) {
11
+ console.error(`\x1b[31mError: npm ${REQUIRED_NPM_MAJOR}.x or above is required. Current: ${npmVersion}\x1b[0m`);
12
+ console.error('Please run: npm install -g npm@9');
13
+ process.exit(1);
14
+ }
15
+
16
+ console.log(`\x1b[32m✓ npm ${npmVersion} meets requirements (>= ${REQUIRED_NPM_MAJOR}.x)\x1b[0m`);
@@ -1,5 +1,5 @@
1
1
  export = getHighchartsRenderer;
2
2
  /**
3
- * @param {EnvironmentOptions} envOptions
3
+ * @param {import("./index").EnvironmentOptions} envOptions
4
4
  */
5
- declare function getHighchartsRenderer($: any, document: any, Highcharts: any, default_colors: any, highchartsRenderer: any, DataFormatter: any, lodash: any, moment_lib: any, isNewAngular: any, envOptions: EnvironmentOptions): any;
5
+ declare function getHighchartsRenderer($: any, document: any, Highcharts: any, default_colors: any, highchartsRenderer: any, DataFormatter: any, lodash: any, moment_lib: any, isNewAngular: any, envOptions?: import("./index").EnvironmentOptions): any;
package/tsconfig.json CHANGED
@@ -18,5 +18,5 @@
18
18
  "./src/options/**/*.js",
19
19
  "./src/pivot-table/freeze-panes/**/*.js"
20
20
  ],
21
- "exclude": ["node_modules"]
21
+ "exclude": ["node_modules", "**/*.d.ts", "**/*.test.js", "**/__snapshots__", "**/__fixtures__"]
22
22
  }
@@ -1,85 +0,0 @@
1
- version: 2.1
2
-
3
- orbs:
4
- datarails-cicd-orb: datarails-ns/datarails-cicd-orb@dev:primary
5
-
6
- defaults: &defaults
7
- working_directory: ~/repo
8
- docker:
9
- - image: circleci/node:14.16.1
10
-
11
- jobs:
12
- deploy:
13
- <<: *defaults
14
- steps:
15
- - checkout
16
-
17
- - attach_workspace:
18
- at: ~/repo
19
- - run:
20
- name: Prepare publish version
21
- command: |
22
- postfix=""
23
- if [[ "${CIRCLE_BRANCH}" != master ]] ; then
24
- postfix="-$CIRCLE_BRANCH"
25
- fi
26
-
27
- VERSION="1.3.$CIRCLE_BUILD_NUM$postfix"
28
- sed -i s/{{cicd_version}}/$VERSION/g ./package.json
29
- cat ./package.json
30
- - run:
31
- name: Authenticate with registry
32
- command: echo "//registry.npmjs.org/:_authToken=$npm_TOKEN" > ~/repo/.npmrc
33
- - run:
34
- name: Install dependencies
35
- command: npm install
36
- - run:
37
- name: Run npm test
38
- command: npm test
39
- - run:
40
- name: Publish package
41
- command: npm publish . --access=public
42
- - datarails-cicd-orb/add-ssh-id:
43
- private_key_env_var: github_deploy_private_encoded
44
- public_key_env_var: github_deploy_pub_encoded
45
- is_public_key_encoded: true
46
- is_private_key_encoded: true
47
- - run:
48
- name: prepare git tag
49
- command: |
50
- postfix=""
51
- if [[ "${CIRCLE_BRANCH}" != prod ]] ; then
52
- postfix="-$CIRCLE_BRANCH"
53
- fi
54
-
55
- VERSION="1.3.$CIRCLE_BUILD_NUM$postfix"
56
- git config --global user.email noreplay@circleci.com
57
- git config --global user.name circleci
58
- git config --global -l
59
- git tag -a "$CIRCLE_BRANCH/$VERSION" -m "circleci build"
60
- # Test SSH connection to GitHub
61
- output=$(ssh -o "StrictHostKeyChecking no" -T git@github.com 2>&1 || true)
62
- echo "$output"
63
- if ! echo "$output" | grep -q "Hi.*You've successfully authenticated"; then
64
- echo "Failed to authenticate with GitHub"
65
- exit 1
66
- fi
67
- # Push the tag after successful authentication
68
- git push --tags origin
69
- workflows:
70
- version: 2
71
- npm-publish:
72
- jobs:
73
- - deploy:
74
- context:
75
- - metadata
76
- filters:
77
- branches:
78
- only:
79
- - /master/
80
- - /tigers/
81
- - /bratans/
82
- - /dragons/
83
- - /tigers/
84
- - /wizards/
85
- - /rocket/