@testsmith/testblocks 0.9.4 → 0.9.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/cli/index.js +4 -1
- package/dist/client/assets/index-B8OSvcUg.css +1 -0
- package/dist/client/assets/index-CMMJHs_d.js +2197 -0
- package/dist/client/assets/index-CMMJHs_d.js.map +1 -0
- package/dist/client/index.html +2 -2
- package/dist/core/blocks/api/ApiAssertBodyContainsBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiAssertBodyContainsBlock.js +40 -0
- package/dist/core/blocks/api/ApiAssertStatusBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiAssertStatusBlock.js +35 -0
- package/dist/core/blocks/api/ApiClearHeadersBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiClearHeadersBlock.js +25 -0
- package/dist/core/blocks/api/ApiDeleteBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiDeleteBlock.js +37 -0
- package/dist/core/blocks/api/ApiExtractBlock.d.ts +14 -0
- package/dist/core/blocks/api/ApiExtractBlock.js +40 -0
- package/dist/core/blocks/api/ApiExtractJsonPathBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiExtractJsonPathBlock.js +47 -0
- package/dist/core/blocks/api/ApiExtractXPathBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiExtractXPathBlock.js +70 -0
- package/dist/core/blocks/api/ApiGetBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiGetBlock.js +36 -0
- package/dist/core/blocks/api/ApiHeadersBlock.d.ts +14 -0
- package/dist/core/blocks/api/ApiHeadersBlock.js +44 -0
- package/dist/core/blocks/api/ApiJsonBodyBlock.d.ts +14 -0
- package/dist/core/blocks/api/ApiJsonBodyBlock.js +28 -0
- package/dist/core/blocks/api/ApiPatchBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiPatchBlock.js +47 -0
- package/dist/core/blocks/api/ApiPostBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiPostBlock.js +47 -0
- package/dist/core/blocks/api/ApiPutBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiPutBlock.js +47 -0
- package/dist/core/blocks/api/ApiSetHeaderBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiSetHeaderBlock.js +37 -0
- package/dist/core/blocks/api/ApiSetHeadersBlock.d.ts +13 -0
- package/dist/core/blocks/api/ApiSetHeadersBlock.js +41 -0
- package/dist/core/blocks/api/index.d.ts +25 -0
- package/dist/core/blocks/api/index.js +83 -0
- package/dist/core/blocks/base/Block.d.ts +59 -0
- package/dist/core/blocks/base/Block.js +151 -0
- package/dist/core/blocks/base/ContainerBlock.d.ts +14 -0
- package/dist/core/blocks/base/ContainerBlock.js +16 -0
- package/dist/core/blocks/base/ControlFlowBlock.d.ts +13 -0
- package/dist/core/blocks/base/ControlFlowBlock.js +17 -0
- package/dist/core/blocks/base/StatementBlock.d.ts +9 -0
- package/dist/core/blocks/base/StatementBlock.js +16 -0
- package/dist/core/blocks/base/ValueBlock.d.ts +12 -0
- package/dist/core/blocks/base/ValueBlock.js +16 -0
- package/dist/core/blocks/base/index.d.ts +5 -0
- package/dist/core/blocks/base/index.js +13 -0
- package/dist/core/blocks/data/DataCsvBlock.d.ts +14 -0
- package/dist/core/blocks/data/DataCsvBlock.js +51 -0
- package/dist/core/blocks/data/DataDefineBlock.d.ts +14 -0
- package/dist/core/blocks/data/DataDefineBlock.js +28 -0
- package/dist/core/blocks/data/DataForeachBlock.d.ts +13 -0
- package/dist/core/blocks/data/DataForeachBlock.js +37 -0
- package/dist/core/blocks/data/DataFromVariableBlock.d.ts +14 -0
- package/dist/core/blocks/data/DataFromVariableBlock.js +27 -0
- package/dist/core/blocks/data/DataGetCurrentBlock.d.ts +14 -0
- package/dist/core/blocks/data/DataGetCurrentBlock.js +34 -0
- package/dist/core/blocks/data/DataGetIndexBlock.d.ts +14 -0
- package/dist/core/blocks/data/DataGetIndexBlock.js +24 -0
- package/dist/core/blocks/data/DataGetNameBlock.d.ts +14 -0
- package/dist/core/blocks/data/DataGetNameBlock.js +24 -0
- package/dist/core/blocks/data/DataRangeBlock.d.ts +14 -0
- package/dist/core/blocks/data/DataRangeBlock.js +40 -0
- package/dist/core/blocks/data/DataRowBlock.d.ts +14 -0
- package/dist/core/blocks/data/DataRowBlock.js +33 -0
- package/dist/core/blocks/data/DataTableBlock.d.ts +14 -0
- package/dist/core/blocks/data/DataTableBlock.js +51 -0
- package/dist/core/blocks/data/index.d.ts +20 -0
- package/dist/core/blocks/data/index.js +57 -0
- package/dist/core/blocks/index.d.ts +66 -5
- package/dist/core/blocks/index.js +134 -35
- package/dist/core/blocks/lifecycle/LifecycleAfterAllBlock.d.ts +15 -0
- package/dist/core/blocks/lifecycle/LifecycleAfterAllBlock.js +27 -0
- package/dist/core/blocks/lifecycle/LifecycleAfterEachBlock.d.ts +15 -0
- package/dist/core/blocks/lifecycle/LifecycleAfterEachBlock.js +27 -0
- package/dist/core/blocks/lifecycle/LifecycleBeforeAllBlock.d.ts +15 -0
- package/dist/core/blocks/lifecycle/LifecycleBeforeAllBlock.js +28 -0
- package/dist/core/blocks/lifecycle/LifecycleBeforeEachBlock.d.ts +15 -0
- package/dist/core/blocks/lifecycle/LifecycleBeforeEachBlock.js +27 -0
- package/dist/core/blocks/lifecycle/LifecycleOnFailureBlock.d.ts +13 -0
- package/dist/core/blocks/lifecycle/LifecycleOnFailureBlock.js +25 -0
- package/dist/core/blocks/lifecycle/LifecycleRetryBlock.d.ts +13 -0
- package/dist/core/blocks/lifecycle/LifecycleRetryBlock.js +29 -0
- package/dist/core/blocks/lifecycle/LifecycleSetupBlock.d.ts +13 -0
- package/dist/core/blocks/lifecycle/LifecycleSetupBlock.js +27 -0
- package/dist/core/blocks/lifecycle/LifecycleSkipIfBlock.d.ts +13 -0
- package/dist/core/blocks/lifecycle/LifecycleSkipIfBlock.js +31 -0
- package/dist/core/blocks/lifecycle/LifecycleTeardownBlock.d.ts +13 -0
- package/dist/core/blocks/lifecycle/LifecycleTeardownBlock.js +27 -0
- package/dist/core/blocks/lifecycle/TestCaseBlock.d.ts +21 -0
- package/dist/core/blocks/lifecycle/TestCaseBlock.js +72 -0
- package/dist/core/blocks/lifecycle/TestCaseDataDrivenBlock.d.ts +21 -0
- package/dist/core/blocks/lifecycle/TestCaseDataDrivenBlock.js +102 -0
- package/dist/core/blocks/lifecycle/index.d.ts +21 -0
- package/dist/core/blocks/lifecycle/index.js +63 -0
- package/dist/core/blocks/logic/LogicArrayBlock.d.ts +14 -0
- package/dist/core/blocks/logic/LogicArrayBlock.js +28 -0
- package/dist/core/blocks/logic/LogicAssertBlock.d.ts +13 -0
- package/dist/core/blocks/logic/LogicAssertBlock.js +32 -0
- package/dist/core/blocks/logic/LogicBooleanBlock.d.ts +14 -0
- package/dist/core/blocks/logic/LogicBooleanBlock.js +26 -0
- package/dist/core/blocks/logic/LogicBooleanOpBlock.d.ts +14 -0
- package/dist/core/blocks/logic/LogicBooleanOpBlock.js +31 -0
- package/dist/core/blocks/logic/LogicCommentBlock.d.ts +13 -0
- package/dist/core/blocks/logic/LogicCommentBlock.js +26 -0
- package/dist/core/blocks/logic/LogicCompareBlock.d.ts +14 -0
- package/dist/core/blocks/logic/LogicCompareBlock.js +52 -0
- package/dist/core/blocks/logic/LogicFailBlock.d.ts +16 -0
- package/dist/core/blocks/logic/LogicFailBlock.js +30 -0
- package/dist/core/blocks/logic/LogicForeachBlock.d.ts +13 -0
- package/dist/core/blocks/logic/LogicForeachBlock.js +29 -0
- package/dist/core/blocks/logic/LogicGetVariableBlock.d.ts +14 -0
- package/dist/core/blocks/logic/LogicGetVariableBlock.js +27 -0
- package/dist/core/blocks/logic/LogicIfBlock.d.ts +13 -0
- package/dist/core/blocks/logic/LogicIfBlock.js +36 -0
- package/dist/core/blocks/logic/LogicLogBlock.d.ts +13 -0
- package/dist/core/blocks/logic/LogicLogBlock.js +30 -0
- package/dist/core/blocks/logic/LogicNotBlock.d.ts +14 -0
- package/dist/core/blocks/logic/LogicNotBlock.js +26 -0
- package/dist/core/blocks/logic/LogicNumberBlock.d.ts +14 -0
- package/dist/core/blocks/logic/LogicNumberBlock.js +26 -0
- package/dist/core/blocks/logic/LogicObjectBlock.d.ts +14 -0
- package/dist/core/blocks/logic/LogicObjectBlock.js +28 -0
- package/dist/core/blocks/logic/LogicRepeatBlock.d.ts +13 -0
- package/dist/core/blocks/logic/LogicRepeatBlock.js +27 -0
- package/dist/core/blocks/logic/LogicSetVariableBlock.d.ts +13 -0
- package/dist/core/blocks/logic/LogicSetVariableBlock.js +34 -0
- package/dist/core/blocks/logic/LogicTextBlock.d.ts +14 -0
- package/dist/core/blocks/logic/LogicTextBlock.js +27 -0
- package/dist/core/blocks/logic/LogicTryCatchBlock.d.ts +13 -0
- package/dist/core/blocks/logic/LogicTryCatchBlock.js +26 -0
- package/dist/core/blocks/logic/index.d.ts +28 -0
- package/dist/core/blocks/logic/index.js +95 -0
- package/dist/core/blocks/playwright/assertions/WebAssertAccessibleDescriptionBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertAccessibleDescriptionBlock.js +41 -0
- package/dist/core/blocks/playwright/assertions/WebAssertAccessibleNameBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertAccessibleNameBlock.js +41 -0
- package/dist/core/blocks/playwright/assertions/WebAssertAttachedBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertAttachedBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/WebAssertAttributeBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertAttributeBlock.js +44 -0
- package/dist/core/blocks/playwright/assertions/WebAssertCheckedBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertCheckedBlock.js +48 -0
- package/dist/core/blocks/playwright/assertions/WebAssertClassBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertClassBlock.js +43 -0
- package/dist/core/blocks/playwright/assertions/WebAssertCountBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertCountBlock.js +41 -0
- package/dist/core/blocks/playwright/assertions/WebAssertCssBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertCssBlock.js +44 -0
- package/dist/core/blocks/playwright/assertions/WebAssertDisabledBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertDisabledBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/WebAssertEditableBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertEditableBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/WebAssertEmptyBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertEmptyBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/WebAssertEnabledBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertEnabledBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/WebAssertFocusedBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertFocusedBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/WebAssertIdBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertIdBlock.js +41 -0
- package/dist/core/blocks/playwright/assertions/WebAssertInViewportBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertInViewportBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/WebAssertNotVisibleBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertNotVisibleBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/WebAssertRoleBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertRoleBlock.js +69 -0
- package/dist/core/blocks/playwright/assertions/WebAssertTextContainsBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertTextContainsBlock.js +41 -0
- package/dist/core/blocks/playwright/assertions/WebAssertTextEqualsBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertTextEqualsBlock.js +41 -0
- package/dist/core/blocks/playwright/assertions/WebAssertTitleContainsBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertTitleContainsBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/WebAssertTitleEqualsBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertTitleEqualsBlock.js +36 -0
- package/dist/core/blocks/playwright/assertions/WebAssertUrlContainsBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertUrlContainsBlock.js +40 -0
- package/dist/core/blocks/playwright/assertions/WebAssertUrlEqualsBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertUrlEqualsBlock.js +37 -0
- package/dist/core/blocks/playwright/assertions/WebAssertValueBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertValueBlock.js +43 -0
- package/dist/core/blocks/playwright/assertions/WebAssertValueContainsBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertValueContainsBlock.js +43 -0
- package/dist/core/blocks/playwright/assertions/WebAssertVisibleBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/assertions/WebAssertVisibleBlock.js +39 -0
- package/dist/core/blocks/playwright/assertions/index.d.ts +36 -0
- package/dist/core/blocks/playwright/assertions/index.js +127 -0
- package/dist/core/blocks/playwright/index.d.ts +16 -0
- package/dist/core/blocks/playwright/index.js +28 -3
- package/dist/core/blocks/playwright/interactions/WebCheckboxBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebCheckboxBlock.js +43 -0
- package/dist/core/blocks/playwright/interactions/WebClickBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebClickBlock.js +34 -0
- package/dist/core/blocks/playwright/interactions/WebDragAndDropBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebDragAndDropBlock.js +37 -0
- package/dist/core/blocks/playwright/interactions/WebFillBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebFillBlock.js +38 -0
- package/dist/core/blocks/playwright/interactions/WebFocusBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebFocusBlock.js +34 -0
- package/dist/core/blocks/playwright/interactions/WebHoverBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebHoverBlock.js +34 -0
- package/dist/core/blocks/playwright/interactions/WebPressKeyBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebPressKeyBlock.js +37 -0
- package/dist/core/blocks/playwright/interactions/WebScrollIntoViewBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebScrollIntoViewBlock.js +34 -0
- package/dist/core/blocks/playwright/interactions/WebSelectBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebSelectBlock.js +37 -0
- package/dist/core/blocks/playwright/interactions/WebTypeBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebTypeBlock.js +41 -0
- package/dist/core/blocks/playwright/interactions/WebUploadFileBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/interactions/WebUploadFileBlock.js +39 -0
- package/dist/core/blocks/playwright/interactions/index.d.ts +21 -0
- package/dist/core/blocks/playwright/interactions/index.js +56 -0
- package/dist/core/blocks/playwright/navigation/WebNavigateBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/navigation/WebNavigateBlock.js +36 -0
- package/dist/core/blocks/playwright/navigation/WebScreenshotBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/navigation/WebScreenshotBlock.js +36 -0
- package/dist/core/blocks/playwright/navigation/WebWaitBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/navigation/WebWaitBlock.js +32 -0
- package/dist/core/blocks/playwright/navigation/WebWaitForElementBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/navigation/WebWaitForElementBlock.js +37 -0
- package/dist/core/blocks/playwright/navigation/WebWaitForUrlBlock.d.ts +13 -0
- package/dist/core/blocks/playwright/navigation/WebWaitForUrlBlock.js +34 -0
- package/dist/core/blocks/playwright/navigation/index.d.ts +15 -0
- package/dist/core/blocks/playwright/navigation/index.js +32 -0
- package/dist/core/blocks/playwright/retrieval/WebCountElementsBlock.d.ts +16 -0
- package/dist/core/blocks/playwright/retrieval/WebCountElementsBlock.js +36 -0
- package/dist/core/blocks/playwright/retrieval/WebGetAttributeBlock.d.ts +16 -0
- package/dist/core/blocks/playwright/retrieval/WebGetAttributeBlock.js +42 -0
- package/dist/core/blocks/playwright/retrieval/WebGetInputValueBlock.d.ts +16 -0
- package/dist/core/blocks/playwright/retrieval/WebGetInputValueBlock.js +40 -0
- package/dist/core/blocks/playwright/retrieval/WebGetTextBlock.d.ts +16 -0
- package/dist/core/blocks/playwright/retrieval/WebGetTextBlock.js +40 -0
- package/dist/core/blocks/playwright/retrieval/WebGetTitleBlock.d.ts +16 -0
- package/dist/core/blocks/playwright/retrieval/WebGetTitleBlock.js +31 -0
- package/dist/core/blocks/playwright/retrieval/WebGetUrlBlock.d.ts +16 -0
- package/dist/core/blocks/playwright/retrieval/WebGetUrlBlock.js +31 -0
- package/dist/core/blocks/playwright/retrieval/index.d.ts +16 -0
- package/dist/core/blocks/playwright/retrieval/index.js +36 -0
- package/dist/core/blocks/playwright/types.d.ts +14 -0
- package/dist/core/blocks/procedures/ProcedureCallBlock.d.ts +13 -0
- package/dist/core/blocks/procedures/ProcedureCallBlock.js +66 -0
- package/dist/core/blocks/procedures/ProcedureCallWithReturnBlock.d.ts +14 -0
- package/dist/core/blocks/procedures/ProcedureCallWithReturnBlock.js +51 -0
- package/dist/core/blocks/procedures/ProcedureDefineBlock.d.ts +15 -0
- package/dist/core/blocks/procedures/ProcedureDefineBlock.js +59 -0
- package/dist/core/blocks/procedures/ProcedureFillFormBlock.d.ts +13 -0
- package/dist/core/blocks/procedures/ProcedureFillFormBlock.js +30 -0
- package/dist/core/blocks/procedures/ProcedureGetParamBlock.d.ts +14 -0
- package/dist/core/blocks/procedures/ProcedureGetParamBlock.js +33 -0
- package/dist/core/blocks/procedures/ProcedureInlineBlock.d.ts +14 -0
- package/dist/core/blocks/procedures/ProcedureInlineBlock.js +31 -0
- package/dist/core/blocks/procedures/ProcedureLoginBlock.d.ts +13 -0
- package/dist/core/blocks/procedures/ProcedureLoginBlock.js +37 -0
- package/dist/core/blocks/procedures/ProcedureMapBlock.d.ts +14 -0
- package/dist/core/blocks/procedures/ProcedureMapBlock.js +36 -0
- package/dist/core/blocks/procedures/ProcedureReturnBlock.d.ts +15 -0
- package/dist/core/blocks/procedures/ProcedureReturnBlock.js +28 -0
- package/dist/core/blocks/procedures/ProcedureWaitAndClickBlock.d.ts +13 -0
- package/dist/core/blocks/procedures/ProcedureWaitAndClickBlock.js +32 -0
- package/dist/core/blocks/procedures/index.d.ts +21 -0
- package/dist/core/blocks/procedures/index.js +62 -0
- package/dist/core/blocks/{procedures.d.ts → procedures/procedureRegistry.d.ts} +10 -2
- package/dist/core/blocks/procedures/procedureRegistry.js +27 -0
- package/dist/core/blocks/utils/apiUtils.d.ts +81 -0
- package/dist/core/blocks/utils/apiUtils.js +176 -0
- package/dist/core/blocks/utils/index.d.ts +2 -0
- package/dist/core/blocks/utils/index.js +16 -0
- package/dist/core/blocks/utils/variableUtils.d.ts +19 -0
- package/dist/core/blocks/utils/variableUtils.js +69 -0
- package/dist/server/index.js +117 -11
- package/dist/server/openApiParser.d.ts +82 -0
- package/dist/server/openApiParser.js +495 -0
- package/dist/server/startServer.d.ts +1 -0
- package/dist/server/startServer.js +164 -0
- package/package.json +4 -2
- package/dist/client/assets/index-BLBBQ6Rn.js +0 -2195
- package/dist/client/assets/index-BLBBQ6Rn.js.map +0 -1
- package/dist/client/assets/index-qjoPPl9y.css +0 -1
- package/dist/core/blocks/api.d.ts +0 -2
- package/dist/core/blocks/api.js +0 -607
- package/dist/core/blocks/data-driven.d.ts +0 -2
- package/dist/core/blocks/data-driven.js +0 -245
- package/dist/core/blocks/lifecycle.d.ts +0 -2
- package/dist/core/blocks/lifecycle.js +0 -201
- package/dist/core/blocks/logic.d.ts +0 -2
- package/dist/core/blocks/logic.js +0 -360
- package/dist/core/blocks/playwright/assertions.d.ts +0 -5
- package/dist/core/blocks/playwright/assertions.js +0 -311
- package/dist/core/blocks/playwright/interactions.d.ts +0 -5
- package/dist/core/blocks/playwright/interactions.js +0 -208
- package/dist/core/blocks/playwright/navigation.d.ts +0 -5
- package/dist/core/blocks/playwright/navigation.js +0 -131
- package/dist/core/blocks/playwright/retrieval.d.ts +0 -5
- package/dist/core/blocks/playwright/retrieval.js +0 -153
- package/dist/core/blocks/playwright.d.ts +0 -13
- package/dist/core/blocks/playwright.js +0 -17
- package/dist/core/blocks/procedures.js +0 -321
|
@@ -1,208 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.interactionBlocks = void 0;
|
|
4
|
-
const utils_1 = require("./utils");
|
|
5
|
-
/**
|
|
6
|
-
* User interaction blocks for Playwright (click, type, fill, etc.)
|
|
7
|
-
*/
|
|
8
|
-
exports.interactionBlocks = [
|
|
9
|
-
// Click Element
|
|
10
|
-
{
|
|
11
|
-
type: 'web_click',
|
|
12
|
-
category: 'Web',
|
|
13
|
-
color: '#E91E63',
|
|
14
|
-
tooltip: 'Click on an element (auto-waits for element to be visible and stable)',
|
|
15
|
-
inputs: [
|
|
16
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
17
|
-
],
|
|
18
|
-
previousStatement: true,
|
|
19
|
-
nextStatement: true,
|
|
20
|
-
execute: async (params, context) => {
|
|
21
|
-
const page = context.page;
|
|
22
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
23
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
24
|
-
context.logger.info(`Clicking: ${selector}`);
|
|
25
|
-
const locator = page.locator(selector);
|
|
26
|
-
// Wait for element to be visible and stable before clicking
|
|
27
|
-
await locator.waitFor({ state: 'visible', timeout });
|
|
28
|
-
// Scroll into view to ensure element is in viewport
|
|
29
|
-
await locator.scrollIntoViewIfNeeded({ timeout });
|
|
30
|
-
// Click with retry on intercept (handles overlays/animations)
|
|
31
|
-
await locator.click({ timeout });
|
|
32
|
-
return {
|
|
33
|
-
_summary: params.SELECTOR,
|
|
34
|
-
selector,
|
|
35
|
-
};
|
|
36
|
-
},
|
|
37
|
-
},
|
|
38
|
-
// Fill Input
|
|
39
|
-
{
|
|
40
|
-
type: 'web_fill',
|
|
41
|
-
category: 'Web',
|
|
42
|
-
color: '#E91E63',
|
|
43
|
-
tooltip: 'Fill an input field (clears existing value, auto-waits)',
|
|
44
|
-
inputs: [
|
|
45
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
46
|
-
{ name: 'VALUE', type: 'field', fieldType: 'text', required: true },
|
|
47
|
-
],
|
|
48
|
-
previousStatement: true,
|
|
49
|
-
nextStatement: true,
|
|
50
|
-
execute: async (params, context) => {
|
|
51
|
-
const page = context.page;
|
|
52
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
53
|
-
const rawValue = params.VALUE;
|
|
54
|
-
const value = (0, utils_1.resolveVariables)(rawValue, context);
|
|
55
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
56
|
-
context.logger.info(`Filling ${selector} with "${value}"`);
|
|
57
|
-
const locator = page.locator(selector);
|
|
58
|
-
await locator.fill(value, { timeout });
|
|
59
|
-
const displayValue = value.length > 30 ? value.substring(0, 30) + '...' : value;
|
|
60
|
-
return {
|
|
61
|
-
_summary: `${params.SELECTOR} = "${displayValue}"`,
|
|
62
|
-
selector,
|
|
63
|
-
value,
|
|
64
|
-
};
|
|
65
|
-
},
|
|
66
|
-
},
|
|
67
|
-
// Type Text
|
|
68
|
-
{
|
|
69
|
-
type: 'web_type',
|
|
70
|
-
category: 'Web',
|
|
71
|
-
color: '#E91E63',
|
|
72
|
-
tooltip: 'Type text character by character (auto-waits)',
|
|
73
|
-
inputs: [
|
|
74
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
75
|
-
{ name: 'TEXT', type: 'field', fieldType: 'text', required: true },
|
|
76
|
-
{ name: 'DELAY', type: 'field', fieldType: 'number', default: 50 },
|
|
77
|
-
],
|
|
78
|
-
previousStatement: true,
|
|
79
|
-
nextStatement: true,
|
|
80
|
-
execute: async (params, context) => {
|
|
81
|
-
const page = context.page;
|
|
82
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
83
|
-
const text = (0, utils_1.resolveVariables)(params.TEXT, context);
|
|
84
|
-
const delay = params.DELAY;
|
|
85
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
86
|
-
context.logger.info(`Typing "${text}" into ${selector}`);
|
|
87
|
-
const locator = page.locator(selector);
|
|
88
|
-
await locator.pressSequentially(text, { delay, timeout });
|
|
89
|
-
const displayText = text.length > 30 ? text.substring(0, 30) + '...' : text;
|
|
90
|
-
return {
|
|
91
|
-
_summary: `${params.SELECTOR} = "${displayText}"`,
|
|
92
|
-
selector,
|
|
93
|
-
text,
|
|
94
|
-
delay,
|
|
95
|
-
};
|
|
96
|
-
},
|
|
97
|
-
},
|
|
98
|
-
// Press Key
|
|
99
|
-
{
|
|
100
|
-
type: 'web_press_key',
|
|
101
|
-
category: 'Web',
|
|
102
|
-
color: '#E91E63',
|
|
103
|
-
tooltip: 'Press a keyboard key (auto-waits)',
|
|
104
|
-
inputs: [
|
|
105
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
106
|
-
{ name: 'KEY', type: 'field', fieldType: 'dropdown', options: [['Enter', 'Enter'], ['Tab', 'Tab'], ['Escape', 'Escape'], ['Backspace', 'Backspace'], ['ArrowUp', 'ArrowUp'], ['ArrowDown', 'ArrowDown'], ['ArrowLeft', 'ArrowLeft'], ['ArrowRight', 'ArrowRight']] },
|
|
107
|
-
],
|
|
108
|
-
previousStatement: true,
|
|
109
|
-
nextStatement: true,
|
|
110
|
-
execute: async (params, context) => {
|
|
111
|
-
const page = context.page;
|
|
112
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
113
|
-
const key = params.KEY;
|
|
114
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
115
|
-
context.logger.info(`Pressing ${key} on ${selector}`);
|
|
116
|
-
const locator = page.locator(selector);
|
|
117
|
-
await locator.press(key, { timeout });
|
|
118
|
-
return {
|
|
119
|
-
_summary: `${key} on ${params.SELECTOR}`,
|
|
120
|
-
selector,
|
|
121
|
-
key,
|
|
122
|
-
};
|
|
123
|
-
},
|
|
124
|
-
},
|
|
125
|
-
// Select Option
|
|
126
|
-
{
|
|
127
|
-
type: 'web_select',
|
|
128
|
-
category: 'Web',
|
|
129
|
-
color: '#E91E63',
|
|
130
|
-
tooltip: 'Select an option from a dropdown (auto-waits)',
|
|
131
|
-
inputs: [
|
|
132
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
133
|
-
{ name: 'VALUE', type: 'field', fieldType: 'text', required: true },
|
|
134
|
-
],
|
|
135
|
-
previousStatement: true,
|
|
136
|
-
nextStatement: true,
|
|
137
|
-
execute: async (params, context) => {
|
|
138
|
-
const page = context.page;
|
|
139
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
140
|
-
const value = (0, utils_1.resolveVariables)(params.VALUE, context);
|
|
141
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
142
|
-
context.logger.info(`Selecting "${value}" in ${selector}`);
|
|
143
|
-
const locator = page.locator(selector);
|
|
144
|
-
await locator.selectOption(value, { timeout });
|
|
145
|
-
return {
|
|
146
|
-
_summary: `${params.SELECTOR} = "${value}"`,
|
|
147
|
-
selector,
|
|
148
|
-
value,
|
|
149
|
-
};
|
|
150
|
-
},
|
|
151
|
-
},
|
|
152
|
-
// Check/Uncheck Checkbox
|
|
153
|
-
{
|
|
154
|
-
type: 'web_checkbox',
|
|
155
|
-
category: 'Web',
|
|
156
|
-
color: '#E91E63',
|
|
157
|
-
tooltip: 'Check or uncheck a checkbox (auto-waits)',
|
|
158
|
-
inputs: [
|
|
159
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
160
|
-
{ name: 'ACTION', type: 'field', fieldType: 'dropdown', options: [['Check', 'check'], ['Uncheck', 'uncheck']] },
|
|
161
|
-
],
|
|
162
|
-
previousStatement: true,
|
|
163
|
-
nextStatement: true,
|
|
164
|
-
execute: async (params, context) => {
|
|
165
|
-
const page = context.page;
|
|
166
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
167
|
-
const action = params.ACTION;
|
|
168
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
169
|
-
context.logger.info(`${action === 'check' ? 'Checking' : 'Unchecking'} ${selector}`);
|
|
170
|
-
const locator = page.locator(selector);
|
|
171
|
-
if (action === 'check') {
|
|
172
|
-
await locator.check({ timeout });
|
|
173
|
-
}
|
|
174
|
-
else {
|
|
175
|
-
await locator.uncheck({ timeout });
|
|
176
|
-
}
|
|
177
|
-
return {
|
|
178
|
-
_summary: `${action} ${params.SELECTOR}`,
|
|
179
|
-
selector,
|
|
180
|
-
action,
|
|
181
|
-
};
|
|
182
|
-
},
|
|
183
|
-
},
|
|
184
|
-
// Hover
|
|
185
|
-
{
|
|
186
|
-
type: 'web_hover',
|
|
187
|
-
category: 'Web',
|
|
188
|
-
color: '#E91E63',
|
|
189
|
-
tooltip: 'Hover over an element (auto-waits)',
|
|
190
|
-
inputs: [
|
|
191
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
192
|
-
],
|
|
193
|
-
previousStatement: true,
|
|
194
|
-
nextStatement: true,
|
|
195
|
-
execute: async (params, context) => {
|
|
196
|
-
const page = context.page;
|
|
197
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
198
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
199
|
-
context.logger.info(`Hovering over ${selector}`);
|
|
200
|
-
const locator = page.locator(selector);
|
|
201
|
-
await locator.hover({ timeout });
|
|
202
|
-
return {
|
|
203
|
-
_summary: params.SELECTOR,
|
|
204
|
-
selector,
|
|
205
|
-
};
|
|
206
|
-
},
|
|
207
|
-
},
|
|
208
|
-
];
|
|
@@ -1,131 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.navigationBlocks = void 0;
|
|
4
|
-
const utils_1 = require("./utils");
|
|
5
|
-
/**
|
|
6
|
-
* Navigation and waiting blocks for Playwright
|
|
7
|
-
*/
|
|
8
|
-
exports.navigationBlocks = [
|
|
9
|
-
// Navigate to URL
|
|
10
|
-
{
|
|
11
|
-
type: 'web_navigate',
|
|
12
|
-
category: 'Web',
|
|
13
|
-
color: '#E91E63',
|
|
14
|
-
tooltip: 'Navigate to a URL',
|
|
15
|
-
inputs: [
|
|
16
|
-
{ name: 'URL', type: 'field', fieldType: 'text', required: true },
|
|
17
|
-
{ name: 'WAIT_UNTIL', type: 'field', fieldType: 'dropdown', options: [['Load', 'load'], ['DOM Content Loaded', 'domcontentloaded'], ['Network Idle', 'networkidle']], default: 'load' },
|
|
18
|
-
],
|
|
19
|
-
previousStatement: true,
|
|
20
|
-
nextStatement: true,
|
|
21
|
-
execute: async (params, context) => {
|
|
22
|
-
const page = context.page;
|
|
23
|
-
const url = (0, utils_1.resolveVariables)(params.URL, context);
|
|
24
|
-
const waitUntil = params.WAIT_UNTIL;
|
|
25
|
-
context.logger.info(`Navigating to ${url}`);
|
|
26
|
-
await page.goto(url, { waitUntil });
|
|
27
|
-
return {
|
|
28
|
-
_summary: url,
|
|
29
|
-
url,
|
|
30
|
-
waitUntil,
|
|
31
|
-
};
|
|
32
|
-
},
|
|
33
|
-
},
|
|
34
|
-
// Wait for Element
|
|
35
|
-
{
|
|
36
|
-
type: 'web_wait_for_element',
|
|
37
|
-
category: 'Web',
|
|
38
|
-
color: '#9C27B0',
|
|
39
|
-
tooltip: 'Wait for an element to appear/disappear',
|
|
40
|
-
inputs: [
|
|
41
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
42
|
-
{ name: 'STATE', type: 'field', fieldType: 'dropdown', options: [['Visible', 'visible'], ['Hidden', 'hidden'], ['Attached', 'attached'], ['Detached', 'detached']] },
|
|
43
|
-
],
|
|
44
|
-
previousStatement: true,
|
|
45
|
-
nextStatement: true,
|
|
46
|
-
execute: async (params, context) => {
|
|
47
|
-
const page = context.page;
|
|
48
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
49
|
-
const state = params.STATE;
|
|
50
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
51
|
-
context.logger.info(`Waiting for ${selector} to be ${state}`);
|
|
52
|
-
await page.waitForSelector(selector, { state, timeout });
|
|
53
|
-
return {
|
|
54
|
-
_summary: `${params.SELECTOR} is ${state}`,
|
|
55
|
-
selector,
|
|
56
|
-
state,
|
|
57
|
-
};
|
|
58
|
-
},
|
|
59
|
-
},
|
|
60
|
-
// Wait for URL
|
|
61
|
-
{
|
|
62
|
-
type: 'web_wait_for_url',
|
|
63
|
-
category: 'Web',
|
|
64
|
-
color: '#9C27B0',
|
|
65
|
-
tooltip: 'Wait for URL to match',
|
|
66
|
-
inputs: [
|
|
67
|
-
{ name: 'URL', type: 'field', fieldType: 'text', required: true },
|
|
68
|
-
],
|
|
69
|
-
previousStatement: true,
|
|
70
|
-
nextStatement: true,
|
|
71
|
-
execute: async (params, context) => {
|
|
72
|
-
const page = context.page;
|
|
73
|
-
const url = (0, utils_1.resolveVariables)(params.URL, context);
|
|
74
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
75
|
-
context.logger.info(`Waiting for URL to match: ${url}`);
|
|
76
|
-
await page.waitForURL(url, { timeout });
|
|
77
|
-
return {
|
|
78
|
-
_summary: url,
|
|
79
|
-
url,
|
|
80
|
-
};
|
|
81
|
-
},
|
|
82
|
-
},
|
|
83
|
-
// Wait (pause)
|
|
84
|
-
{
|
|
85
|
-
type: 'web_wait',
|
|
86
|
-
category: 'Web',
|
|
87
|
-
color: '#9C27B0',
|
|
88
|
-
tooltip: 'Wait for a specified time',
|
|
89
|
-
inputs: [
|
|
90
|
-
{ name: 'MILLISECONDS', type: 'field', fieldType: 'number', default: 1000 },
|
|
91
|
-
],
|
|
92
|
-
previousStatement: true,
|
|
93
|
-
nextStatement: true,
|
|
94
|
-
execute: async (params, context) => {
|
|
95
|
-
const page = context.page;
|
|
96
|
-
const ms = params.MILLISECONDS;
|
|
97
|
-
context.logger.info(`Waiting ${ms}ms`);
|
|
98
|
-
await page.waitForTimeout(ms);
|
|
99
|
-
return {
|
|
100
|
-
_summary: `${ms}ms`,
|
|
101
|
-
milliseconds: ms,
|
|
102
|
-
};
|
|
103
|
-
},
|
|
104
|
-
},
|
|
105
|
-
// Take Screenshot
|
|
106
|
-
{
|
|
107
|
-
type: 'web_screenshot',
|
|
108
|
-
category: 'Web',
|
|
109
|
-
color: '#607D8B',
|
|
110
|
-
tooltip: 'Take a screenshot',
|
|
111
|
-
inputs: [
|
|
112
|
-
{ name: 'NAME', type: 'field', fieldType: 'text', default: 'screenshot' },
|
|
113
|
-
{ name: 'FULL_PAGE', type: 'field', fieldType: 'checkbox', default: false },
|
|
114
|
-
],
|
|
115
|
-
previousStatement: true,
|
|
116
|
-
nextStatement: true,
|
|
117
|
-
execute: async (params, context) => {
|
|
118
|
-
const page = context.page;
|
|
119
|
-
const name = params.NAME;
|
|
120
|
-
const fullPage = params.FULL_PAGE;
|
|
121
|
-
context.logger.info(`Taking screenshot: ${name}`);
|
|
122
|
-
const buffer = await page.screenshot({ fullPage });
|
|
123
|
-
return {
|
|
124
|
-
_summary: `${name}${fullPage ? ' (full page)' : ''}`,
|
|
125
|
-
name,
|
|
126
|
-
fullPage,
|
|
127
|
-
buffer: buffer.toString('base64'),
|
|
128
|
-
};
|
|
129
|
-
},
|
|
130
|
-
},
|
|
131
|
-
];
|
|
@@ -1,153 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.retrievalBlocks = void 0;
|
|
4
|
-
const utils_1 = require("./utils");
|
|
5
|
-
/**
|
|
6
|
-
* Data retrieval blocks for Playwright (get text, attributes, values)
|
|
7
|
-
*/
|
|
8
|
-
exports.retrievalBlocks = [
|
|
9
|
-
// Get Text Content
|
|
10
|
-
{
|
|
11
|
-
type: 'web_get_text',
|
|
12
|
-
category: 'Web',
|
|
13
|
-
color: '#2196F3',
|
|
14
|
-
tooltip: 'Get text content of an element (auto-waits)',
|
|
15
|
-
inputs: [
|
|
16
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
17
|
-
],
|
|
18
|
-
output: { type: 'String' },
|
|
19
|
-
execute: async (params, context) => {
|
|
20
|
-
const page = context.page;
|
|
21
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
22
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
23
|
-
const locator = page.locator(selector);
|
|
24
|
-
await locator.waitFor({ state: 'visible', timeout });
|
|
25
|
-
const text = await locator.textContent({ timeout });
|
|
26
|
-
context.logger.debug(`Text content of ${selector}: "${text}"`);
|
|
27
|
-
const displayText = text && text.length > 40 ? text.substring(0, 40) + '...' : text;
|
|
28
|
-
return {
|
|
29
|
-
_summary: `"${displayText}"`,
|
|
30
|
-
_value: text,
|
|
31
|
-
selector,
|
|
32
|
-
text,
|
|
33
|
-
};
|
|
34
|
-
},
|
|
35
|
-
},
|
|
36
|
-
// Get Attribute
|
|
37
|
-
{
|
|
38
|
-
type: 'web_get_attribute',
|
|
39
|
-
category: 'Web',
|
|
40
|
-
color: '#2196F3',
|
|
41
|
-
tooltip: 'Get attribute value of an element (auto-waits)',
|
|
42
|
-
inputs: [
|
|
43
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
44
|
-
{ name: 'ATTRIBUTE', type: 'field', fieldType: 'text', required: true },
|
|
45
|
-
],
|
|
46
|
-
output: { type: 'String' },
|
|
47
|
-
execute: async (params, context) => {
|
|
48
|
-
const page = context.page;
|
|
49
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
50
|
-
const attribute = params.ATTRIBUTE;
|
|
51
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
52
|
-
const locator = page.locator(selector);
|
|
53
|
-
await locator.waitFor({ state: 'attached', timeout });
|
|
54
|
-
const value = await locator.getAttribute(attribute, { timeout });
|
|
55
|
-
context.logger.debug(`Attribute ${attribute} of ${selector}: "${value}"`);
|
|
56
|
-
return {
|
|
57
|
-
_summary: `${attribute} = "${value}"`,
|
|
58
|
-
_value: value,
|
|
59
|
-
selector,
|
|
60
|
-
attribute,
|
|
61
|
-
value,
|
|
62
|
-
};
|
|
63
|
-
},
|
|
64
|
-
},
|
|
65
|
-
// Get Input Value
|
|
66
|
-
{
|
|
67
|
-
type: 'web_get_input_value',
|
|
68
|
-
category: 'Web',
|
|
69
|
-
color: '#2196F3',
|
|
70
|
-
tooltip: 'Get current value of an input field (auto-waits)',
|
|
71
|
-
inputs: [
|
|
72
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
73
|
-
],
|
|
74
|
-
output: { type: 'String' },
|
|
75
|
-
execute: async (params, context) => {
|
|
76
|
-
const page = context.page;
|
|
77
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
78
|
-
const timeout = (0, utils_1.getTimeout)(context);
|
|
79
|
-
const locator = page.locator(selector);
|
|
80
|
-
await locator.waitFor({ state: 'visible', timeout });
|
|
81
|
-
const value = await locator.inputValue({ timeout });
|
|
82
|
-
context.logger.debug(`Input value of ${selector}: "${value}"`);
|
|
83
|
-
const displayValue = value.length > 40 ? value.substring(0, 40) + '...' : value;
|
|
84
|
-
return {
|
|
85
|
-
_summary: `"${displayValue}"`,
|
|
86
|
-
_value: value,
|
|
87
|
-
selector,
|
|
88
|
-
value,
|
|
89
|
-
};
|
|
90
|
-
},
|
|
91
|
-
},
|
|
92
|
-
// Get Page Title
|
|
93
|
-
{
|
|
94
|
-
type: 'web_get_title',
|
|
95
|
-
category: 'Web',
|
|
96
|
-
color: '#2196F3',
|
|
97
|
-
tooltip: 'Get the page title',
|
|
98
|
-
inputs: [],
|
|
99
|
-
output: { type: 'String' },
|
|
100
|
-
execute: async (params, context) => {
|
|
101
|
-
const page = context.page;
|
|
102
|
-
const title = await page.title();
|
|
103
|
-
context.logger.debug(`Page title: "${title}"`);
|
|
104
|
-
return {
|
|
105
|
-
_summary: `"${title}"`,
|
|
106
|
-
_value: title,
|
|
107
|
-
title,
|
|
108
|
-
};
|
|
109
|
-
},
|
|
110
|
-
},
|
|
111
|
-
// Get Current URL
|
|
112
|
-
{
|
|
113
|
-
type: 'web_get_url',
|
|
114
|
-
category: 'Web',
|
|
115
|
-
color: '#2196F3',
|
|
116
|
-
tooltip: 'Get the current URL',
|
|
117
|
-
inputs: [],
|
|
118
|
-
output: { type: 'String' },
|
|
119
|
-
execute: async (params, context) => {
|
|
120
|
-
const page = context.page;
|
|
121
|
-
const url = page.url();
|
|
122
|
-
context.logger.debug(`Current URL: "${url}"`);
|
|
123
|
-
return {
|
|
124
|
-
_summary: url,
|
|
125
|
-
_value: url,
|
|
126
|
-
url,
|
|
127
|
-
};
|
|
128
|
-
},
|
|
129
|
-
},
|
|
130
|
-
// Count Elements
|
|
131
|
-
{
|
|
132
|
-
type: 'web_count_elements',
|
|
133
|
-
category: 'Web',
|
|
134
|
-
color: '#2196F3',
|
|
135
|
-
tooltip: 'Count the number of elements matching a selector',
|
|
136
|
-
inputs: [
|
|
137
|
-
{ name: 'SELECTOR', type: 'field', fieldType: 'text', required: true },
|
|
138
|
-
],
|
|
139
|
-
output: { type: 'Number' },
|
|
140
|
-
execute: async (params, context) => {
|
|
141
|
-
const page = context.page;
|
|
142
|
-
const selector = (0, utils_1.resolveSelector)(params, context);
|
|
143
|
-
const count = await page.locator(selector).count();
|
|
144
|
-
context.logger.debug(`Found ${count} elements matching ${selector}`);
|
|
145
|
-
return {
|
|
146
|
-
_summary: `${count} elements`,
|
|
147
|
-
_value: count,
|
|
148
|
-
selector,
|
|
149
|
-
count,
|
|
150
|
-
};
|
|
151
|
-
},
|
|
152
|
-
},
|
|
153
|
-
];
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Playwright blocks - Re-export from modular structure
|
|
3
|
-
*
|
|
4
|
-
* This file re-exports all Playwright blocks from the playwright/ directory
|
|
5
|
-
* for backwards compatibility. The blocks are now organized in:
|
|
6
|
-
* - playwright/navigation.ts - Navigate, wait, screenshot
|
|
7
|
-
* - playwright/interactions.ts - Click, fill, type, select, checkbox, hover
|
|
8
|
-
* - playwright/retrieval.ts - Get text, attributes, values, title, URL
|
|
9
|
-
* - playwright/assertions.ts - Visibility, text, value assertions
|
|
10
|
-
* - playwright/utils.ts - Shared utilities (resolveVariables, resolveSelector)
|
|
11
|
-
* - playwright/types.ts - TypeScript interfaces
|
|
12
|
-
*/
|
|
13
|
-
export { playwrightBlocks } from './playwright/index';
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Playwright blocks - Re-export from modular structure
|
|
4
|
-
*
|
|
5
|
-
* This file re-exports all Playwright blocks from the playwright/ directory
|
|
6
|
-
* for backwards compatibility. The blocks are now organized in:
|
|
7
|
-
* - playwright/navigation.ts - Navigate, wait, screenshot
|
|
8
|
-
* - playwright/interactions.ts - Click, fill, type, select, checkbox, hover
|
|
9
|
-
* - playwright/retrieval.ts - Get text, attributes, values, title, URL
|
|
10
|
-
* - playwright/assertions.ts - Visibility, text, value assertions
|
|
11
|
-
* - playwright/utils.ts - Shared utilities (resolveVariables, resolveSelector)
|
|
12
|
-
* - playwright/types.ts - TypeScript interfaces
|
|
13
|
-
*/
|
|
14
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.playwrightBlocks = void 0;
|
|
16
|
-
var index_1 = require("./playwright/index");
|
|
17
|
-
Object.defineProperty(exports, "playwrightBlocks", { enumerable: true, get: function () { return index_1.playwrightBlocks; } });
|