@genesislcap/foundation-forms 14.468.1-alpha-0e71a41.0 → 14.469.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.
@@ -2236,29 +2236,6 @@
2236
2236
  "kind": "javascript-module",
2237
2237
  "path": "src/jsonforms/renderers/CategorizationWrapperRenderer.ts",
2238
2238
  "declarations": [
2239
- {
2240
- "kind": "function",
2241
- "name": "computeCategoryClassName",
2242
- "return": {
2243
- "type": {
2244
- "text": "string"
2245
- }
2246
- },
2247
- "parameters": [
2248
- {
2249
- "name": "category",
2250
- "type": {
2251
- "text": "UiSchemaElement"
2252
- }
2253
- },
2254
- {
2255
- "name": "data",
2256
- "type": {
2257
- "text": "any"
2258
- }
2259
- }
2260
- ]
2261
- },
2262
2239
  {
2263
2240
  "kind": "variable",
2264
2241
  "name": "tabControlIconStyles",
@@ -2295,18 +2272,6 @@
2295
2272
  },
2296
2273
  "default": "new Set([0])"
2297
2274
  },
2298
- {
2299
- "kind": "field",
2300
- "name": "activeTabIndex",
2301
- "type": {
2302
- "text": "number"
2303
- },
2304
- "default": "0"
2305
- },
2306
- {
2307
- "kind": "method",
2308
- "name": "controlChanged"
2309
- },
2310
2275
  {
2311
2276
  "kind": "method",
2312
2277
  "name": "isMounted",
@@ -2363,14 +2328,6 @@
2363
2328
  }
2364
2329
  ],
2365
2330
  "exports": [
2366
- {
2367
- "kind": "js",
2368
- "name": "computeCategoryClassName",
2369
- "declaration": {
2370
- "name": "computeCategoryClassName",
2371
- "module": "src/jsonforms/renderers/CategorizationWrapperRenderer.ts"
2372
- }
2373
- },
2374
2331
  {
2375
2332
  "kind": "js",
2376
2333
  "name": "tabControlIconStyles",
@@ -4240,26 +4197,6 @@
4240
4197
  "module": "src/jsonforms/renderers/CategorizationWrapperRenderer.ts"
4241
4198
  }
4242
4199
  },
4243
- {
4244
- "kind": "field",
4245
- "name": "activeTabIndex",
4246
- "type": {
4247
- "text": "number"
4248
- },
4249
- "default": "0",
4250
- "inheritedFrom": {
4251
- "name": "CategorizationWrapper",
4252
- "module": "src/jsonforms/renderers/CategorizationWrapperRenderer.ts"
4253
- }
4254
- },
4255
- {
4256
- "kind": "method",
4257
- "name": "controlChanged",
4258
- "inheritedFrom": {
4259
- "name": "CategorizationWrapper",
4260
- "module": "src/jsonforms/renderers/CategorizationWrapperRenderer.ts"
4261
- }
4262
- },
4263
4200
  {
4264
4201
  "kind": "method",
4265
4202
  "name": "isMounted",
@@ -12,7 +12,6 @@ import { UiSchemaElement } from '../../types';
12
12
  *
13
13
  * @internal
14
14
  */
15
- export declare function resolveActiveCategoryIndex(activeCategory: number | string | undefined, elements: UiSchemaElement[]): number;
16
15
  export declare function computeCategoryClassName(category: UiSchemaElement, data: any): string;
17
16
  export declare const tabControlIconStyles: import("@microsoft/fast-element").ElementStyles;
18
17
  export declare const CategorizationWrapperRendererTemplate: (prefix?: string) => import("@microsoft/fast-element").ViewTemplate<CategorizationWrapper, any>;
@@ -20,8 +19,6 @@ export declare class CategorizationWrapper extends FASTElement {
20
19
  form: any;
21
20
  control: any;
22
21
  mountedTabs: Set<number>;
23
- activeTabIndex: number;
24
- controlChanged(): void;
25
22
  isMounted(index: number): boolean;
26
23
  handleTabChange(event: Event): void;
27
24
  hasCategoryError(categoryIndex: number): boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"CategorizationWrapperRenderer.d.ts","sourceRoot":"","sources":["../../../../src/jsonforms/renderers/CategorizationWrapperRenderer.ts"],"names":[],"mappings":"AACA,OAAO,EAKL,WAAW,EAIZ,MAAM,yBAAyB,CAAC;AAGjC,OAAO,EAA2C,eAAe,EAAE,MAAM,aAAa,CAAC;AAEvF;;;;;;;;;;;GAWG;AACH,wBAAgB,0BAA0B,CACxC,cAAc,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,EAC3C,QAAQ,EAAE,eAAe,EAAE,GAC1B,MAAM,CASR;AAED,wBAAgB,wBAAwB,CAAC,QAAQ,EAAE,eAAe,EAAE,IAAI,EAAE,GAAG,GAAG,MAAM,CAMrF;AAED,eAAO,MAAM,oBAAoB,iDAKhC,CAAC;AAEF,eAAO,MAAM,qCAAqC,GAChD,eAAe,+EA6DhB,CAAC;AAkBF,qBAQa,qBAAsB,SAAQ,WAAW;IACxC,IAAI,MAAC;IACL,OAAO,MAAC;IACR,WAAW,EAAE,GAAG,CAAC,MAAM,CAAC,CAAgB;IACxC,cAAc,EAAE,MAAM,CAAK;IAEvC,cAAc;IASd,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO;IAIjC,eAAe,CAAC,KAAK,EAAE,KAAK;IAQ5B,gBAAgB,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO;CAQjD"}
1
+ {"version":3,"file":"CategorizationWrapperRenderer.d.ts","sourceRoot":"","sources":["../../../../src/jsonforms/renderers/CategorizationWrapperRenderer.ts"],"names":[],"mappings":"AACA,OAAO,EAKL,WAAW,EAIZ,MAAM,yBAAyB,CAAC;AAGjC,OAAO,EAA2C,eAAe,EAAE,MAAM,aAAa,CAAC;AAEvF;;;;;;;;;;;GAWG;AACH,wBAAgB,wBAAwB,CAAC,QAAQ,EAAE,eAAe,EAAE,IAAI,EAAE,GAAG,GAAG,MAAM,CAMrF;AAED,eAAO,MAAM,oBAAoB,iDAKhC,CAAC;AAEF,eAAO,MAAM,qCAAqC,GAChD,eAAe,+EA4DhB,CAAC;AAkBF,qBAQa,qBAAsB,SAAQ,WAAW;IACxC,IAAI,MAAC;IACL,OAAO,MAAC;IACR,WAAW,EAAE,GAAG,CAAC,MAAM,CAAC,CAAgB;IAEpD,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO;IAIjC,eAAe,CAAC,KAAK,EAAE,KAAK;IAO5B,gBAAgB,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO;CAQjD"}
@@ -1 +1 @@
1
- {"version":3,"file":"VerticalCategorizationWrapperRenderer.d.ts","sourceRoot":"","sources":["../../../../src/jsonforms/renderers/VerticalCategorizationWrapperRenderer.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,qBAAqB,EAA4B,MAAM,iCAAiC,CAAC;AAElG,eAAO,MAAM,6CAA6C,GACxD,eAAe,uFA0EhB,CAAC;AAmEF,qBAQa,6BAA8B,SAAQ,qBAAqB;IAChE,MAAM,EAAE,MAAM,CAAM;IAE1B,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM;IAMjD,iBAAiB;CAIlB"}
1
+ {"version":3,"file":"VerticalCategorizationWrapperRenderer.d.ts","sourceRoot":"","sources":["../../../../src/jsonforms/renderers/VerticalCategorizationWrapperRenderer.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,qBAAqB,EAA4B,MAAM,iCAAiC,CAAC;AAElG,eAAO,MAAM,6CAA6C,GACxD,eAAe,uFAwEhB,CAAC;AAmEF,qBAQa,6BAA8B,SAAQ,qBAAqB;IAChE,MAAM,EAAE,MAAM,CAAM;IAE1B,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM;IAMjD,iBAAiB;CAIlB"}
@@ -13,16 +13,6 @@ import { classNames } from '@microsoft/fast-web-utilities';
13
13
  *
14
14
  * @internal
15
15
  */
16
- export function resolveActiveCategoryIndex(activeCategory, elements) {
17
- if (typeof activeCategory === 'number') {
18
- return activeCategory >= 0 && activeCategory < elements.length ? activeCategory : 0;
19
- }
20
- if (typeof activeCategory === 'string') {
21
- const found = elements.findIndex((el) => el.label === activeCategory);
22
- return found !== -1 ? found : 0;
23
- }
24
- return 0;
25
- }
26
16
  export function computeCategoryClassName(category, data) {
27
17
  var _a, _b;
28
18
  const className = (_a = category === null || category === void 0 ? void 0 : category.options) === null || _a === void 0 ? void 0 : _a.className;
@@ -39,10 +29,9 @@ export const tabControlIconStyles = css `
39
29
  `;
40
30
  export const CategorizationWrapperRendererTemplate = (prefix = 'zero') => html `
41
31
  <template>
42
- <${prefix}-tabs appearance="secondary" class="tabs-container" :activeid="${(x) => 'tab-' + x.activeTabIndex}" @change=${(x, ctx) => x.handleTabChange(ctx.event)}>
32
+ <${prefix}-tabs appearance="secondary" class="tabs-container" @change=${(x, ctx) => x.handleTabChange(ctx.event)}>
43
33
  ${repeat((x) => x.control.uischema.elements, html `
44
34
  <${prefix}-tab
45
- id="${(x, ctx) => 'tab-' + ctx.index}"
46
35
  appearance="secondary"
47
36
  class="${(x, ctx) => {
48
37
  var _a, _b, _c;
@@ -100,18 +89,6 @@ let CategorizationWrapper = class CategorizationWrapper extends FASTElement {
100
89
  constructor() {
101
90
  super(...arguments);
102
91
  this.mountedTabs = new Set([0]);
103
- this.activeTabIndex = 0;
104
- }
105
- controlChanged() {
106
- var _a, _b, _c, _d;
107
- if (!this.control)
108
- return;
109
- const activeCategory = (_b = (_a = this.control.uischema) === null || _a === void 0 ? void 0 : _a.options) === null || _b === void 0 ? void 0 : _b.activeCategory;
110
- if (activeCategory === undefined)
111
- return;
112
- const index = resolveActiveCategoryIndex(activeCategory, (_d = (_c = this.control.uischema) === null || _c === void 0 ? void 0 : _c.elements) !== null && _d !== void 0 ? _d : []);
113
- this.activeTabIndex = index;
114
- this.mountedTabs = new Set([index]);
115
92
  }
116
93
  isMounted(index) {
117
94
  return this.mountedTabs.has(index);
@@ -120,7 +97,6 @@ let CategorizationWrapper = class CategorizationWrapper extends FASTElement {
120
97
  if (event.target !== event.currentTarget)
121
98
  return;
122
99
  const index = event.target.currentTabIndex;
123
- this.activeTabIndex = index;
124
100
  if (this.mountedTabs.has(index))
125
101
  return;
126
102
  this.mountedTabs = new Set(this.mountedTabs).add(index);
@@ -144,9 +120,6 @@ __decorate([
144
120
  __decorate([
145
121
  observable
146
122
  ], CategorizationWrapper.prototype, "mountedTabs", void 0);
147
- __decorate([
148
- observable
149
- ], CategorizationWrapper.prototype, "activeTabIndex", void 0);
150
123
  CategorizationWrapper = __decorate([
151
124
  customElement({
152
125
  name: 'categorization-wrapper',
@@ -7,12 +7,10 @@ export const VerticalCategorizationWrapperRendererTemplate = (prefix = 'zero') =
7
7
  <${prefix}-tabs
8
8
  class="tabs-container"
9
9
  orientation="vertical"
10
- :activeid="${(x) => 'tab-' + x.activeTabIndex}"
11
10
  @change=${(x, ctx) => x.handleTabChange(ctx.event)}
12
11
  >
13
12
  ${repeat((x) => x.control.uischema.elements, html `
14
13
  <${prefix}-tab
15
- id="${(x, ctx) => 'tab-' + ctx.index}"
16
14
  class="${(x, ctx) => {
17
15
  var _a, _b, _c;
18
16
  const custom = computeCategoryClassName(x, (_c = (_b = (_a = ctx.parent.form) === null || _a === void 0 ? void 0 : _a.jsonforms) === null || _b === void 0 ? void 0 : _b.core) === null || _c === void 0 ? void 0 : _c.data);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@genesislcap/foundation-forms",
3
3
  "description": "Genesis Foundation Forms",
4
- "version": "14.468.1-alpha-0e71a41.0",
4
+ "version": "14.469.0",
5
5
  "sideEffects": false,
6
6
  "license": "SEE LICENSE IN license.txt",
7
7
  "main": "dist/esm/index.js",
@@ -59,13 +59,13 @@
59
59
  }
60
60
  },
61
61
  "devDependencies": {
62
- "@genesislcap/foundation-testing": "14.468.1-alpha-0e71a41.0",
63
- "@genesislcap/genx": "14.468.1-alpha-0e71a41.0",
64
- "@genesislcap/rollup-builder": "14.468.1-alpha-0e71a41.0",
65
- "@genesislcap/ts-builder": "14.468.1-alpha-0e71a41.0",
66
- "@genesislcap/uvu-playwright-builder": "14.468.1-alpha-0e71a41.0",
67
- "@genesislcap/vite-builder": "14.468.1-alpha-0e71a41.0",
68
- "@genesislcap/webpack-builder": "14.468.1-alpha-0e71a41.0",
62
+ "@genesislcap/foundation-testing": "14.469.0",
63
+ "@genesislcap/genx": "14.469.0",
64
+ "@genesislcap/rollup-builder": "14.469.0",
65
+ "@genesislcap/ts-builder": "14.469.0",
66
+ "@genesislcap/uvu-playwright-builder": "14.469.0",
67
+ "@genesislcap/vite-builder": "14.469.0",
68
+ "@genesislcap/webpack-builder": "14.469.0",
69
69
  "@types/json-schema": "^7.0.11",
70
70
  "@types/papaparse": "^5.3.14"
71
71
  },
@@ -82,12 +82,12 @@
82
82
  }
83
83
  },
84
84
  "dependencies": {
85
- "@genesislcap/foundation-comms": "14.468.1-alpha-0e71a41.0",
86
- "@genesislcap/foundation-criteria": "14.468.1-alpha-0e71a41.0",
87
- "@genesislcap/foundation-logger": "14.468.1-alpha-0e71a41.0",
88
- "@genesislcap/foundation-notifications": "14.468.1-alpha-0e71a41.0",
89
- "@genesislcap/foundation-ui": "14.468.1-alpha-0e71a41.0",
90
- "@genesislcap/foundation-utils": "14.468.1-alpha-0e71a41.0",
85
+ "@genesislcap/foundation-comms": "14.469.0",
86
+ "@genesislcap/foundation-criteria": "14.469.0",
87
+ "@genesislcap/foundation-logger": "14.469.0",
88
+ "@genesislcap/foundation-notifications": "14.469.0",
89
+ "@genesislcap/foundation-ui": "14.469.0",
90
+ "@genesislcap/foundation-utils": "14.469.0",
91
91
  "@json-schema-tools/dereferencer": "^1.6.1",
92
92
  "@jsonforms/core": "^3.2.1",
93
93
  "@microsoft/fast-components": "2.30.6",
@@ -109,5 +109,5 @@
109
109
  "access": "public"
110
110
  },
111
111
  "customElements": "dist/custom-elements.json",
112
- "gitHead": "c6c6d65c3792af83208310d2d1969a08e7b8d73e"
112
+ "gitHead": "2b4460d5b9f20c36baddc55084e658bbcbd18c89"
113
113
  }