UNPKG

@pega/custom-dx-components

Version:

Utility for building custom UI components

262 lines (247 loc) 7.45 kB
// cSpell:ignore words timeofday caseview casepreview objectview export const TASKS_CONFIG_JSON_FILENAME = 'tasks.config.json'; export const INPUT_CONFIG_JSON_FILENAME = 'input.config.json'; export const PACKAGE_JSON_FILENAME = 'package.json'; export const PACKAGE_LOCK_JSON_FILENAME = 'package-lock.json'; export const BUILD_CONFIG_JSON_FILENAME = 'build.config.json'; export const WEBPACK_CONFIG_JS_FILENAME = 'webpack.config.js'; export const WEBPACK_PATHS_JS_FILENAME = 'paths.js'; export const USE_PROMOTED_WEB_PACK = 'usePromotedWebPack'; export const COMPONENTS_DIRECTORY_PATH = 'components-directory-path'; export const IMPORT_RELATIVE_PATH = 'import-relative-path'; export const EXPORT_RELATIVE_PATH = 'export-relative-path'; export const COMPONENTS_PATH = 'component'; export const TOKEN_PATH = 'node_modules/@pega/custom-dx-components/.access_token'; export const OOTB_COMPONENTS = 'node_modules/@pega/custom-dx-components/.ootb_components'; export const LIBRARY_BASED = 'libraryMode'; export const LIBRARY_BASED_CL = 'libraryModeCL'; export const USE_INPUT_CONFIG = 'useInputConfig'; export const SHARED_DIRECTORY = 'shared'; export const SHOW_DEBUG = 'showDebug'; export const ARCHIVES_PATH = 'store'; export const BIN_ARCHIVES_PATH = 'bin-arch'; export const TEMP_PATH = 'store/temp'; export const COMPONENTS_CONFIG_FILE_NAME = 'componentsconfig.json'; export const MAX_RFT_CHARS = 64; /* REST end points */ export const PUBLISH_COMPONENT_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/publish_component'; export const LIST_COMPONENT_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/list_component'; export const OOTB_COMPONENT_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/ootb_component'; export const DELETE_COMPONENT_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/delete_component'; export const INF_TOKEN_URL_V1 = 'PRRestService/oauth2/v1/token'; export const INF_AUTHORIZE_URL_V1 = 'PRRestService/oauth2/v1/authorize'; export const LP_TOKEN_URL = 'uas/oauth/token'; export const LP_AUTHORIZE_URL = 'uas/oauth/authorize'; export const LP_LIST_COMPONENT_SERVICE_REST_ENDPOINT = 'pegalaunchpad/c11n/v103/app/appstudiox/componentslist?field0=type&value0={type}'; export const LP_PUBLISH_COMPONENT_SERVICE_REST_ENDPOINT = 'pegalaunchpad/c11n/isolations/{isolationId}/v102/assetsUpdate'; export const LP_DELETE_COMPONENT_SERVICE_REST_ENDPOINT = 'pegalaunchpad/c11n/isolations/{isolationId}/v102/assetsUpdate'; export const PUBLISH_COMPONENT_LIBRARY_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/publish_component_library'; export const PUBLISH_COMPONENT_LIBRARY_ARCHIVE_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/publish_component_library_archive'; export const LIST_COMPONENT_LIBRARIES_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/list_component_libraries'; export const LIST_COMPONENT_LIBRARY_ARCHIVES_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/list_component_library_archives'; export const DELETE_COMPONENT_LIBRARY_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/delete_component_library'; export const COMPONENT_LIBRARY_ARCHIVE_SERVICE_REST_ENDPOINT = 'PRRestService/dev/v1/component_library_archive'; export const FIELD_PATH = '/field'; export const TEMPLATE_PATH = '/template'; export const WIDGET_PATH = '/widget'; export const COMPONENT_PREFIX_FIELD_PATH = 'field/'; export const COMPONENT_PREFIX_TEMPLATE_PATH = 'template/'; export const COMPONENT_PREFIX_WIDGET_PATH = 'widget/'; export const BUILDER_INDEX_FILE_PATH = '../bundle/builder/index.js'; export const BUILDER_DIR_FILE_PATH = '../bundle/builder'; export const CATEGORY_CONSTELLATION = 'constellation'; export const BOOTSTRAP_CONFIG = 'PRRestService/api/application/v2/data_views/D_pxBootstrapConfig'; export const JEST_ASSETS_ORIGINAL_PATH = 'node_modules/@pega/custom-dx-components/tests/assets/original/components/'; export const JEST_ASSETS_LIBRARY_PATH = 'node_modules/@pega/custom-dx-components/tests/assets/library/components/'; export const JEST_TESTS_FUNCTIONAL_PATH = 'node_modules/@pega/custom-dx-components/tests/functional/'; export const JEST_CREATE_PATH = 'create/'; export const JEST_CREATE_ALL_CONSTELLATION_PATH = 'createAll/Constellation/'; export const JEST_CREATE_ALL_LAUNCHPAD_PATH = 'createAll/Launchpad'; export const AUTHENTICATE_DEFAULTS = { serverType: 'infinity', server: 'https://localhost:1080/prweb', clientId: '10095186356008396159', grantType: 'authCode', authService: 'pega', redirectUri: 'https://localhost:4010/' }; export const SHARED_FILE_NAMES = [ "suggestions-handler.ts", "PConnProps.d.ts", "create-nonce.ts" ]; export const AUTHENTICATE_SCHEMA = { serverType: [ { name: 'Infinity', value: 'infinity' }, { name: 'Launchpad', value: 'launchpad' } ], grantType: [ { name: 'Authorization code', value: 'authCode' }, { name: 'Password credentials', value: 'passwordCreds' }, { name: 'Client credentials', value: 'clientCreds' } ] }; export const COMPONENT_SCHEMA = { framework: [ { name: 'Constellation', value: 'Constellation' }, { name: 'SDK Angular', value: 'SDK-Angular' }, { name: 'SDK React', value: 'SDK-React' }, { name: 'SDK Web Components', value: 'SDK-WebComponents' } ], type: [ { name: 'Field', value: 'Field' }, { name: 'Layout template', value: 'Template' }, { name: 'Widget', value: 'Widget' } ], subtype: { field: [ { name: 'Text', value: 'Text' }, { name: 'Text Input', value: 'Text-Input' }, { name: 'Paragraph', value: 'Text-Paragraph' }, { name: 'Email', value: 'Text-Email' }, { name: 'Phone', value: 'Text-Phone' }, { name: 'URL', value: 'Text-URL' }, { name: 'Icon Button URL', value: 'Icon-Button-URL' }, { name: 'Integer', value: 'Integer' }, { name: 'Decimal', value: 'Decimal' }, { name: 'Currency', value: 'Decimal-Currency' }, { name: 'Percentage', value: 'Decimal-Percentage' }, { name: 'Boolean', value: 'Boolean' }, { name: 'Date', value: 'Date' }, { name: 'DateTime', value: 'DateTime' }, { name: 'TimeOfDay', value: 'TimeOfDay' }, { name: 'Picklist', value: 'Picklist' }, { name: 'Search box', value: 'Picklist-Autocomplete' }, { name: 'Radio buttons', value: 'Picklist-RadioButtons' } ], template: [ { name: 'DETAILS', value: 'DETAILS' }, { name: 'DETAILS region', value: 'DETAILS-region' }, { name: 'FORM', value: 'FORM' }, { name: 'FORM region', value: 'FORM-region' }, { name: 'PAGE', value: 'PAGE' } ], widget: [ { name: 'CASE', value: 'CASE' }, { name: 'PAGE', value: 'PAGE' }, { name: 'PAGE & CASE', value: ['PAGE', 'CASE'] } ] } };