From caf7383e58f2665c7bbdbf98d28c8288c8c07ac4 Mon Sep 17 00:00:00 2001 From: LukasBoll Date: Thu, 6 Jul 2023 18:10:22 +0200 Subject: [PATCH] change path to JSON pointer --- .../src/layouts/array-layout.renderer.ts | 2 +- .../src/other/master-detail/master.ts | 7 ++- .../src/other/table.renderer.ts | 2 +- .../test/master-detail.spec.ts | 6 +- packages/core/src/i18n/i18nUtil.ts | 4 +- packages/core/src/reducers/core.ts | 27 +++++---- packages/core/src/reducers/i18n.ts | 23 +++++++- packages/core/src/util/path.ts | 44 ++++++++++---- packages/core/src/util/resolvers.ts | 2 +- packages/core/src/util/util.ts | 5 +- packages/core/test/i18n/i18nUtil.test.ts | 20 +++---- packages/core/test/reducers/core.test.ts | 58 +++++++++---------- packages/core/test/util/cell.test.ts | 12 ++-- packages/core/test/util/path.test.ts | 55 ++++++++++-------- packages/core/test/util/renderer.test.ts | 15 ++--- packages/core/test/util/resolvers.test.ts | 2 +- packages/examples/src/examples/object.ts | 9 ++- .../complex/MaterialArrayControlRenderer.tsx | 2 +- .../src/complex/MaterialEnumArrayRenderer.tsx | 2 +- .../src/complex/MaterialTableControl.tsx | 6 +- .../renderers/MaterialBooleanCell.test.tsx | 33 ++++++----- .../MaterialBooleanToggleCell.test.tsx | 28 ++++----- .../test/renderers/MaterialDateCell.test.tsx | 26 ++++----- .../test/renderers/MaterialEnumCell.test.tsx | 2 +- .../renderers/MaterialEnumControl.test.tsx | 2 +- .../renderers/MaterialIntegerCell.test.tsx | 28 ++++----- .../renderers/MaterialNumberCell.test.tsx | 28 ++++----- .../renderers/MaterialOneOfEnumCell.test.tsx | 2 +- .../test/renderers/MaterialTextCell.test.tsx | 44 +++++++------- .../test/renderers/MaterialTimeCell.test.tsx | 22 +++---- packages/react/test/JsonFormsContext.test.tsx | 4 +- .../src/complex/TableArrayControl.tsx | 12 ++-- .../test/renderers/BooleanCell.test.tsx | 28 ++++----- .../test/renderers/DateCell.test.tsx | 26 ++++----- .../test/renderers/DateTimeCell.test.tsx | 28 ++++----- .../test/renderers/EnumCell.test.tsx | 22 +++---- .../test/renderers/IntegerCell.test.tsx | 28 ++++----- .../test/renderers/NumberCell.test.tsx | 28 ++++----- .../test/renderers/SliderCell.test.tsx | 28 ++++----- .../test/renderers/TextAreaCell.test.tsx | 44 +++++++++----- .../test/renderers/TextCell.test.tsx | 46 +++++++-------- .../test/renderers/TimeCell.test.tsx | 28 ++++----- 42 files changed, 458 insertions(+), 382 deletions(-) diff --git a/packages/angular-material/src/layouts/array-layout.renderer.ts b/packages/angular-material/src/layouts/array-layout.renderer.ts index eb1b3c1b63..4860b0f2ef 100644 --- a/packages/angular-material/src/layouts/array-layout.renderer.ts +++ b/packages/angular-material/src/layouts/array-layout.renderer.ts @@ -221,7 +221,7 @@ export class ArrayLayoutRenderer } return { schema: this.scopedSchema, - path: Paths.compose(this.propsPath, `${index}`), + path: Paths.compose(this.propsPath, `/${index}`), uischema, }; } diff --git a/packages/angular-material/src/other/master-detail/master.ts b/packages/angular-material/src/other/master-detail/master.ts index 8b8f58b3d3..dc8bb8d039 100644 --- a/packages/angular-material/src/other/master-detail/master.ts +++ b/packages/angular-material/src/other/master-detail/master.ts @@ -87,7 +87,7 @@ export const removeSchemaKeywords = (path: string) => {