@itwin/rpcinterface-full-stack-tests 3.4.0-dev.10 → 3.4.0-dev.12

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.
@@ -69268,12 +69268,21 @@ var Gradient;
69268
69268
  (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.assert)(undefined !== imageBuffer);
69269
69269
  return imageBuffer;
69270
69270
  }
69271
- /** Applies this gradient's settings to produce a bitmap image.
69271
+ /** Produces a bitmap image from this gradient.
69272
69272
  * @param width Width of the image
69273
69273
  * @param height Height of the image
69274
- * @returns Bitmap image of the specified dimensions. For thematic gradients with a width > 1, pixels in each column will be identical.
69274
+ * @note If this gradient uses [[Gradient.Mode.Thematic]], then the width of the image will be 1 and the margin color will be included in the top and bottom rows.
69275
+ * @see [[produceImage]] for more customization.
69275
69276
  */
69276
69277
  getImage(width, height) {
69278
+ if (this.mode === Mode.Thematic)
69279
+ width = 1;
69280
+ return this.produceImage({ width, height, includeThematicMargin: true });
69281
+ }
69282
+ /** Produces a bitmap image from this gradient. */
69283
+ produceImage(args) {
69284
+ var _a;
69285
+ const { width, height, includeThematicMargin } = { ...args };
69277
69286
  const thisAngle = (this.angle === undefined) ? 0 : this.angle.radians;
69278
69287
  const cosA = Math.cos(thisAngle);
69279
69288
  const sinA = Math.sin(thisAngle);
@@ -69379,27 +69388,29 @@ var Gradient;
69379
69388
  break;
69380
69389
  }
69381
69390
  case Mode.Thematic: {
69382
- let settings = this.thematicSettings;
69383
- if (settings === undefined) {
69384
- settings = _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientSettings.defaults;
69385
- }
69391
+ const settings = (_a = this.thematicSettings) !== null && _a !== void 0 ? _a : _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientSettings.defaults;
69386
69392
  for (let j = 0; j < height; j++) {
69387
69393
  let f = 1 - j / height;
69388
69394
  let color;
69389
- f = (f - _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientSettings.margin) / (_ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientSettings.contentRange);
69390
- switch (settings.mode) {
69391
- case _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientMode.SteppedWithDelimiter:
69392
- case _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientMode.IsoLines:
69393
- case _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientMode.Stepped: {
69394
- if (settings.stepCount > 1) {
69395
- const fStep = Math.floor(f * settings.stepCount - 0.00001) / (settings.stepCount - 1);
69396
- color = this.mapColor(fStep);
69395
+ if (includeThematicMargin && (f < _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientSettings.margin || f > _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientSettings.contentMax)) {
69396
+ color = settings.marginColor;
69397
+ }
69398
+ else {
69399
+ f = (f - _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientSettings.margin) / (_ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientSettings.contentRange);
69400
+ switch (settings.mode) {
69401
+ case _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientMode.SteppedWithDelimiter:
69402
+ case _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientMode.IsoLines:
69403
+ case _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientMode.Stepped: {
69404
+ if (settings.stepCount > 1) {
69405
+ const fStep = Math.floor(f * settings.stepCount - 0.00001) / (settings.stepCount - 1);
69406
+ color = this.mapColor(fStep);
69407
+ }
69408
+ break;
69397
69409
  }
69398
- break;
69410
+ case _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientMode.Smooth:
69411
+ color = this.mapColor(f);
69412
+ break;
69399
69413
  }
69400
- case _ThematicDisplay__WEBPACK_IMPORTED_MODULE_4__.ThematicGradientMode.Smooth:
69401
- color = this.mapColor(f);
69402
- break;
69403
69414
  }
69404
69415
  for (let i = 0; i < width; i++) {
69405
69416
  image[currentIdx--] = color.getAlpha();
@@ -143862,7 +143873,15 @@ class System extends _RenderSystem__WEBPACK_IMPORTED_MODULE_7__.RenderSystem {
143862
143873
  }
143863
143874
  /** Attempt to create a texture using gradient symbology. */
143864
143875
  getGradientTexture(symb, iModel) {
143865
- const source = symb.getImage(0x100, 0x100);
143876
+ let width = 0x100;
143877
+ let height = 0x100;
143878
+ if (symb.mode === _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.Gradient.Mode.Thematic) {
143879
+ // Pixels in each row are identical, no point in having width > 1.
143880
+ width = 1;
143881
+ // We want maximum height to minimize bleeding of margin color.
143882
+ height = this.maxTextureSize;
143883
+ }
143884
+ const source = symb.produceImage({ width, height, includeThematicMargin: true });
143866
143885
  return this.createTexture({
143867
143886
  image: {
143868
143887
  source,
@@ -287470,7 +287489,7 @@ class TestContext {
287470
287489
  this.initializeRpcInterfaces({ title: this.settings.Backend.name, version: this.settings.Backend.version });
287471
287490
  const iModelClient = new imodels_client_management_1.IModelsClient({ api: { baseUrl: `https://${(_a = process.env.IMJS_URL_PREFIX) !== null && _a !== void 0 ? _a : ""}api.bentley.com/imodels` } });
287472
287491
  await core_frontend_1.NoRenderApp.startup({
287473
- applicationVersion: "3.4.0-dev.10",
287492
+ applicationVersion: "3.4.0-dev.12",
287474
287493
  applicationId: this.settings.gprid,
287475
287494
  authorizationClient: new frontend_1.TestFrontendAuthorizationClient(this.adminUserAccessToken),
287476
287495
  hubAccess: new imodels_access_frontend_1.FrontendIModelsAccess(iModelClient),
@@ -306386,7 +306405,7 @@ module.exports = JSON.parse('{"name":"axios","version":"0.21.4","description":"P
306386
306405
  /***/ ((module) => {
306387
306406
 
306388
306407
  "use strict";
306389
- module.exports = JSON.parse('{"name":"@itwin/core-frontend","version":"3.4.0-dev.10","description":"iTwin.js frontend components","main":"lib/cjs/core-frontend.js","module":"lib/esm/core-frontend.js","typings":"lib/cjs/core-frontend","license":"MIT","scripts":{"build":"npm run -s copy:public && npm run -s build:cjs","build:ci":"npm run -s build && npm run -s build:esm","build:cjs":"tsc 1>&2 --outDir lib/cjs","build:esm":"tsc 1>&2 --module ES2020 --outDir lib/esm","clean":"rimraf lib .rush/temp/package-deps*.json","copy:public":"cpx \\"./src/public/**/*\\" ./lib/public","docs":"betools docs --includes=../../generated-docs/extract --json=../../generated-docs/core/core-frontend/file.json --tsIndexFile=./core-frontend.ts --onlyJson --excludes=webgl/**/*,**/primitives,**/map/*.d.ts,**/tile/*.d.ts,**/*-css.ts","extract-api":"betools extract-api --entry=core-frontend && npm run extract-extension-api","extract-extension-api":"eslint --no-eslintrc -c \\"../../tools/eslint-plugin/dist/configs/extension-exports-config.js\\" \\"./src/**/*.ts\\" 1>&2","lint":"eslint -f visualstudio \\"./src/**/*.ts\\" 1>&2","pseudolocalize":"betools pseudolocalize --englishDir ./src/public/locales/en --out ./public/locales/en-PSEUDO","test":"npm run -s webpackTests && certa -r chrome","cover":"npm -s test","test:debug":"certa -r chrome --debug","webpackTests":"webpack --config ./src/test/utils/webpack.config.js 1>&2"},"repository":{"type":"git","url":"https://github.com/iTwin/itwinjs-core/tree/master/core/frontend"},"keywords":["Bentley","BIM","iModel","digital-twin","iTwin"],"author":{"name":"Bentley Systems, Inc.","url":"http://www.bentley.com"},"peerDependencies":{"@itwin/appui-abstract":"workspace:^3.4.0-dev.10","@itwin/core-bentley":"workspace:^3.4.0-dev.10","@itwin/core-common":"workspace:^3.4.0-dev.10","@itwin/core-geometry":"workspace:^3.4.0-dev.10","@itwin/core-orbitgt":"workspace:^3.4.0-dev.10","@itwin/core-quantity":"workspace:^3.4.0-dev.10","@itwin/webgl-compatibility":"workspace:^3.4.0-dev.10"},"//devDependencies":["NOTE: All peerDependencies should also be listed as devDependencies since peerDependencies are not considered by npm install","NOTE: All tools used by scripts in this package must be listed as devDependencies"],"devDependencies":{"@itwin/appui-abstract":"workspace:*","@itwin/build-tools":"workspace:*","@itwin/core-bentley":"workspace:*","@itwin/core-common":"workspace:*","@itwin/core-geometry":"workspace:*","@itwin/core-orbitgt":"workspace:*","@itwin/core-quantity":"workspace:*","@itwin/certa":"workspace:*","@itwin/eslint-plugin":"workspace:*","@itwin/webgl-compatibility":"workspace:*","@types/chai":"4.3.1","@types/chai-as-promised":"^7","@types/deep-assign":"^0.1.0","@types/lodash":"^4.14.0","@types/mocha":"^8.2.2","@types/node":"16.11.7","@types/qs":"^6.5.0","@types/semver":"7.3.10","@types/superagent":"^4.1.14","@types/sinon":"^9.0.0","chai":"^4.1.2","chai-as-promised":"^7","cpx2":"^3.0.0","eslint":"^7.11.0","glob":"^7.1.2","mocha":"^10.0.0","nyc":"^15.1.0","rimraf":"^3.0.2","sinon":"^9.0.2","source-map-loader":"^4.0.0","typescript":"~4.4.0","webpack":"^5.64.4"},"//dependencies":["NOTE: these dependencies should be only for things that DO NOT APPEAR IN THE API","NOTE: core-frontend should remain UI technology agnostic, so no react/angular dependencies are allowed"],"dependencies":{"@itwin/core-i18n":"workspace:*","@itwin/core-telemetry":"workspace:*","@loaders.gl/core":"^3.1.6","@loaders.gl/draco":"^3.1.6","deep-assign":"^2.0.0","fuse.js":"^3.3.0","lodash":"^4.17.10","qs":"^6.5.1","semver":"^7.3.5","superagent":"7.1.3","wms-capabilities":"0.4.0","xml-js":"~1.6.11"},"nyc":{"extends":"./node_modules/@itwin/build-tools/.nycrc"},"eslintConfig":{"plugins":["@itwin"],"extends":"plugin:@itwin/itwinjs-recommended","rules":{"@itwin/no-internal-barrel-imports":["error",{"required-barrel-modules":["./src/tile/internal.ts"]}],"@itwin/public-extension-exports":["error",{"releaseTags":["public","preview"],"outputApiFile":false}]},"overrides":[{"files":["*.test.ts","*.test.tsx","**/test/**/*.ts"],"rules":{"@itwin/no-internal-barrel-imports":"off"}}]}}');
306408
+ module.exports = JSON.parse('{"name":"@itwin/core-frontend","version":"3.4.0-dev.12","description":"iTwin.js frontend components","main":"lib/cjs/core-frontend.js","module":"lib/esm/core-frontend.js","typings":"lib/cjs/core-frontend","license":"MIT","scripts":{"build":"npm run -s copy:public && npm run -s build:cjs","build:ci":"npm run -s build && npm run -s build:esm","build:cjs":"tsc 1>&2 --outDir lib/cjs","build:esm":"tsc 1>&2 --module ES2020 --outDir lib/esm","clean":"rimraf lib .rush/temp/package-deps*.json","copy:public":"cpx \\"./src/public/**/*\\" ./lib/public","docs":"betools docs --includes=../../generated-docs/extract --json=../../generated-docs/core/core-frontend/file.json --tsIndexFile=./core-frontend.ts --onlyJson --excludes=webgl/**/*,**/primitives,**/map/*.d.ts,**/tile/*.d.ts,**/*-css.ts","extract-api":"betools extract-api --entry=core-frontend && npm run extract-extension-api","extract-extension-api":"eslint --no-eslintrc -c \\"../../tools/eslint-plugin/dist/configs/extension-exports-config.js\\" \\"./src/**/*.ts\\" 1>&2","lint":"eslint -f visualstudio \\"./src/**/*.ts\\" 1>&2","pseudolocalize":"betools pseudolocalize --englishDir ./src/public/locales/en --out ./public/locales/en-PSEUDO","test":"npm run -s webpackTests && certa -r chrome","cover":"npm -s test","test:debug":"certa -r chrome --debug","webpackTests":"webpack --config ./src/test/utils/webpack.config.js 1>&2"},"repository":{"type":"git","url":"https://github.com/iTwin/itwinjs-core/tree/master/core/frontend"},"keywords":["Bentley","BIM","iModel","digital-twin","iTwin"],"author":{"name":"Bentley Systems, Inc.","url":"http://www.bentley.com"},"peerDependencies":{"@itwin/appui-abstract":"workspace:^3.4.0-dev.12","@itwin/core-bentley":"workspace:^3.4.0-dev.12","@itwin/core-common":"workspace:^3.4.0-dev.12","@itwin/core-geometry":"workspace:^3.4.0-dev.12","@itwin/core-orbitgt":"workspace:^3.4.0-dev.12","@itwin/core-quantity":"workspace:^3.4.0-dev.12","@itwin/webgl-compatibility":"workspace:^3.4.0-dev.12"},"//devDependencies":["NOTE: All peerDependencies should also be listed as devDependencies since peerDependencies are not considered by npm install","NOTE: All tools used by scripts in this package must be listed as devDependencies"],"devDependencies":{"@itwin/appui-abstract":"workspace:*","@itwin/build-tools":"workspace:*","@itwin/core-bentley":"workspace:*","@itwin/core-common":"workspace:*","@itwin/core-geometry":"workspace:*","@itwin/core-orbitgt":"workspace:*","@itwin/core-quantity":"workspace:*","@itwin/certa":"workspace:*","@itwin/eslint-plugin":"workspace:*","@itwin/webgl-compatibility":"workspace:*","@types/chai":"4.3.1","@types/chai-as-promised":"^7","@types/deep-assign":"^0.1.0","@types/lodash":"^4.14.0","@types/mocha":"^8.2.2","@types/node":"16.11.7","@types/qs":"^6.5.0","@types/semver":"7.3.10","@types/superagent":"^4.1.14","@types/sinon":"^9.0.0","chai":"^4.1.2","chai-as-promised":"^7","cpx2":"^3.0.0","eslint":"^7.11.0","glob":"^7.1.2","mocha":"^10.0.0","nyc":"^15.1.0","rimraf":"^3.0.2","sinon":"^9.0.2","source-map-loader":"^4.0.0","typescript":"~4.4.0","webpack":"^5.64.4"},"//dependencies":["NOTE: these dependencies should be only for things that DO NOT APPEAR IN THE API","NOTE: core-frontend should remain UI technology agnostic, so no react/angular dependencies are allowed"],"dependencies":{"@itwin/core-i18n":"workspace:*","@itwin/core-telemetry":"workspace:*","@loaders.gl/core":"^3.1.6","@loaders.gl/draco":"^3.1.6","deep-assign":"^2.0.0","fuse.js":"^3.3.0","lodash":"^4.17.10","qs":"^6.5.1","semver":"^7.3.5","superagent":"7.1.3","wms-capabilities":"0.4.0","xml-js":"~1.6.11"},"nyc":{"extends":"./node_modules/@itwin/build-tools/.nycrc"},"eslintConfig":{"plugins":["@itwin"],"extends":"plugin:@itwin/itwinjs-recommended","rules":{"@itwin/no-internal-barrel-imports":["error",{"required-barrel-modules":["./src/tile/internal.ts"]}],"@itwin/public-extension-exports":["error",{"releaseTags":["public","preview"],"outputApiFile":false}]},"overrides":[{"files":["*.test.ts","*.test.tsx","**/test/**/*.ts"],"rules":{"@itwin/no-internal-barrel-imports":"off"}}]}}');
306390
306409
 
306391
306410
  /***/ }),
306392
306411