@umbraco/playwright-testhelpers 16.0.5 → 16.0.7
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.
- package/dist/lib/helpers/ContentUiHelper.d.ts +6 -4
- package/dist/lib/helpers/ContentUiHelper.js +13 -7
- package/dist/lib/helpers/ContentUiHelper.js.map +1 -1
- package/dist/lib/helpers/DataTypeApiHelper.d.ts +2 -1
- package/dist/lib/helpers/DataTypeApiHelper.js +10 -2
- package/dist/lib/helpers/DataTypeApiHelper.js.map +1 -1
- package/dist/lib/helpers/DataTypeUiHelper.js +1 -1
- package/dist/lib/helpers/DataTypeUiHelper.js.map +1 -1
- package/dist/lib/helpers/DocumentApiHelper.d.ts +1 -0
- package/dist/lib/helpers/DocumentApiHelper.js +55 -3
- package/dist/lib/helpers/DocumentApiHelper.js.map +1 -1
- package/dist/lib/helpers/MediaApiHelper.d.ts +1 -0
- package/dist/lib/helpers/MediaApiHelper.js +7 -2
- package/dist/lib/helpers/MediaApiHelper.js.map +1 -1
- package/dist/lib/helpers/NotificationConstantHelper.d.ts +1 -0
- package/dist/lib/helpers/NotificationConstantHelper.js +2 -1
- package/dist/lib/helpers/NotificationConstantHelper.js.map +1 -1
- package/dist/lib/helpers/UiBaseLocators.js +1 -1
- package/dist/lib/helpers/UiBaseLocators.js.map +1 -1
- package/dist/lib/helpers/UserGroupApiHelper.js +1 -0
- package/dist/lib/helpers/UserGroupApiHelper.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -2
|
@@ -57,7 +57,7 @@ export declare class DataTypeApiHelper {
|
|
|
57
57
|
createBlockGridWithLayoutStylesheet(blockGridName: string, stylesheetName: string): Promise<string | undefined>;
|
|
58
58
|
createBlockGridWithAnAreaInABlock(blockGridName: string, contentElementTypeId: string, areaAlias?: string, createButtonLabel?: string, columnSpan?: number, rowSpan?: number, minAllowed?: number, maxAllowed?: number): Promise<string | undefined>;
|
|
59
59
|
createBlockGridWithAnAreaInABlockWithAllowInAreas(blockGridName: string, contentElementTypeId: string, areaAlias?: string, allowInAreas?: boolean, createButtonLabel?: string, columnSpan?: number, rowSpan?: number, minAllowed?: number, maxAllowed?: number): Promise<string | undefined>;
|
|
60
|
-
createBlockGridWithAnAreaInABlockWithAllowInAreasAndASecondBlock(blockGridName: string, contentElementTypeId: string, secondContentElementTypeId: string, areaAlias?: string, allowInAreas?: boolean, createButtonLabel?: string, columnSpan?: number, rowSpan?: number, minAllowed?: number, maxAllowed?: number): Promise<string | undefined>;
|
|
60
|
+
createBlockGridWithAnAreaInABlockWithAllowInAreasAndASecondBlock(blockGridName: string, contentElementTypeId: string, secondContentElementTypeId: string, areaAlias?: string, allowInAreas?: boolean, createButtonLabel?: string, columnSpan?: number, rowSpan?: number, minAllowed?: number, maxAllowed?: number, secondBlockAllowAtRoot?: boolean, secondBlockAllowInAreas?: boolean): Promise<string | undefined>;
|
|
61
61
|
createBlockGridWithAnAreaInABlockWithACreateLabel(blockGridName: string, contentElementTypeId: string, createButtonLabel?: string, areaAlias?: string): Promise<string | undefined>;
|
|
62
62
|
createBlockGridWithAnAreaInABlockWithColumnSpanAndRowSpan(blockGridName: string, contentElementTypeId: string, columnSpan?: number, rowSpan?: number, areaAlias?: string, createButtonLabel?: string): Promise<string | undefined>;
|
|
63
63
|
createBlockGridWithAnAreaInABlockWithMinAndMaxAllowed(blockGridName: string, contentElementTypeId: string, secondContentElementTypeId: string, minAllowed?: number, maxAllowed?: number, areaAlias?: string, createButtonLabel?: string): Promise<string | undefined>;
|
|
@@ -68,6 +68,7 @@ export declare class DataTypeApiHelper {
|
|
|
68
68
|
createBlockGridWithPermissions(blockGridName: string, contentElementTypeId: string, toAllowInRoot?: boolean, toAllowInAreas?: boolean): Promise<string | undefined>;
|
|
69
69
|
createBlockGridWithSizeOptions(blockGridName: string, contentElementTypeId: string, columnSpans?: number, minRowSpan?: number, maxRowSpan?: number): Promise<string | undefined>;
|
|
70
70
|
createBlockGridWithABlockWithInlineEditingModeAndABlockWithAnArea(blockGridName: string, firstBlockElementTypeId: string, inlineEditing: boolean, secondBlockElementTypeId: string, areaAlias?: string): Promise<string | undefined>;
|
|
71
|
+
getBlockGridAreaKeyFromBlock(blockGridName: string, elementTypeKey: string, areaAlias: string): Promise<any>;
|
|
71
72
|
doesBlockEditorContainBlocksWithContentTypeIds(blockEditorName: string, elementTypeIds: string[]): Promise<boolean>;
|
|
72
73
|
doesBlockEditorContainBlocksWithSettingsTypeIds(blockEditorName: string, elementTypeIds: string[]): Promise<boolean>;
|
|
73
74
|
isLiveEditingModeEnabledForBlockEditor(blockEditorName: string, enabled: boolean): Promise<boolean>;
|
|
@@ -470,7 +470,7 @@ class DataTypeApiHelper {
|
|
|
470
470
|
.build();
|
|
471
471
|
return await this.save(blockGrid);
|
|
472
472
|
}
|
|
473
|
-
async createBlockGridWithAnAreaInABlockWithAllowInAreasAndASecondBlock(blockGridName, contentElementTypeId, secondContentElementTypeId, areaAlias = 'area', allowInAreas = false, createButtonLabel = 'CreateLabel', columnSpan = 6, rowSpan = 1, minAllowed = 0, maxAllowed = 2) {
|
|
473
|
+
async createBlockGridWithAnAreaInABlockWithAllowInAreasAndASecondBlock(blockGridName, contentElementTypeId, secondContentElementTypeId, areaAlias = 'area', allowInAreas = false, createButtonLabel = 'CreateLabel', columnSpan = 6, rowSpan = 1, minAllowed = 0, maxAllowed = 2, secondBlockAllowAtRoot = true, secondBlockAllowInAreas = true) {
|
|
474
474
|
await this.ensureNameNotExists(blockGridName);
|
|
475
475
|
const blockGrid = new json_models_builders_1.BlockGridDataTypeBuilder()
|
|
476
476
|
.withName(blockGridName)
|
|
@@ -489,7 +489,8 @@ class DataTypeApiHelper {
|
|
|
489
489
|
.done()
|
|
490
490
|
.addBlock()
|
|
491
491
|
.withContentElementTypeKey(secondContentElementTypeId)
|
|
492
|
-
.
|
|
492
|
+
.withAllowAtRoot(secondBlockAllowAtRoot)
|
|
493
|
+
.withAllowInAreas(secondBlockAllowInAreas)
|
|
493
494
|
.done()
|
|
494
495
|
.build();
|
|
495
496
|
return await this.save(blockGrid);
|
|
@@ -606,6 +607,13 @@ class DataTypeApiHelper {
|
|
|
606
607
|
.build();
|
|
607
608
|
return await this.save(blockGrid);
|
|
608
609
|
}
|
|
610
|
+
async getBlockGridAreaKeyFromBlock(blockGridName, elementTypeKey, areaAlias) {
|
|
611
|
+
const blockGrid = await this.getByName(blockGridName);
|
|
612
|
+
const blocksValue = blockGrid.values.find(value => value.alias === 'blocks');
|
|
613
|
+
const block = blocksValue.value.find(block => block.contentElementTypeKey === elementTypeKey);
|
|
614
|
+
const area = block.areas.find(area => area.alias === areaAlias);
|
|
615
|
+
return area.key;
|
|
616
|
+
}
|
|
609
617
|
async doesBlockEditorContainBlocksWithContentTypeIds(blockEditorName, elementTypeIds) {
|
|
610
618
|
if (!elementTypeIds || elementTypeIds.length === 0) {
|
|
611
619
|
return false;
|