@appdirect/sfb-toolkit 4.0.24 → 5.0.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.
Files changed (55) hide show
  1. package/bin/index.js +4 -4
  2. package/coverage/clover.xml +89 -80
  3. package/coverage/coverage-final.json +3 -3
  4. package/coverage/lcov-report/constants/customUserAttributesMock.js.html +1 -1
  5. package/coverage/lcov-report/constants/index.html +1 -1
  6. package/coverage/lcov-report/constants/pageUrls.js.html +1 -1
  7. package/coverage/lcov-report/constants/userMock.js.html +1 -1
  8. package/coverage/lcov-report/controllers/controllers-utils/assetsUtils.js.html +1 -1
  9. package/coverage/lcov-report/controllers/controllers-utils/index.html +1 -1
  10. package/coverage/lcov-report/controllers/data-filters/bootstrap-data-filter.js.html +1 -1
  11. package/coverage/lcov-report/controllers/data-filters/call-to-actions-filter.js.html +1 -1
  12. package/coverage/lcov-report/controllers/data-filters/index.html +1 -1
  13. package/coverage/lcov-report/controllers/index.html +15 -15
  14. package/coverage/lcov-report/controllers/index.js.html +15 -12
  15. package/coverage/lcov-report/front-end-utils/src/components/base/ResultItem.js.html +1 -1
  16. package/coverage/lcov-report/front-end-utils/src/components/base/SearchBar.js.html +1 -1
  17. package/coverage/lcov-report/front-end-utils/src/components/base/index.html +1 -1
  18. package/coverage/lcov-report/front-end-utils/src/components/base/item.js.html +1 -1
  19. package/coverage/lcov-report/front-end-utils/src/components/container.js.html +1 -1
  20. package/coverage/lcov-report/front-end-utils/src/components/data-view.js.html +1 -1
  21. package/coverage/lcov-report/front-end-utils/src/components/header-view.js.html +125 -71
  22. package/coverage/lcov-report/front-end-utils/src/components/index.html +14 -14
  23. package/coverage/lcov-report/front-end-utils/src/components/search.js.html +1 -1
  24. package/coverage/lcov-report/front-end-utils/src/constants/index.html +5 -5
  25. package/coverage/lcov-report/front-end-utils/src/constants/pageUrl.js.html +12 -6
  26. package/coverage/lcov-report/front-end-utils/src/constants/roleType.js.html +1 -1
  27. package/coverage/lcov-report/front-end-utils/src/constants/searchType.js.html +1 -1
  28. package/coverage/lcov-report/front-end-utils/src/utils/debounce.js.html +1 -1
  29. package/coverage/lcov-report/front-end-utils/src/utils/index.html +1 -1
  30. package/coverage/lcov-report/index.html +25 -25
  31. package/coverage/lcov-report/middlewares/config.js.html +1 -1
  32. package/coverage/lcov-report/middlewares/index.html +1 -1
  33. package/coverage/lcov-report/tools/index.html +1 -1
  34. package/coverage/lcov-report/tools/proxy-fetch.js.html +1 -1
  35. package/coverage/lcov.info +160 -144
  36. package/index.js +2 -0
  37. package/mockPages/admin/admin.html +4 -1
  38. package/mockPages/login/css/theme-index.css +353 -0
  39. package/mockPages/login/images/login.png +0 -0
  40. package/mockPages/login/login.html +43 -0
  41. package/npm-shrinkwrap.json +2 -2
  42. package/package.json +1 -1
  43. package/readme.md +16 -174
  44. package/src/api/cors.js +5 -2
  45. package/src/controllers/index.js +2 -1
  46. package/src/front-end-utils/dist/toolbar.bundle.js +1 -1
  47. package/src/front-end-utils/src/components/header-view.js +80 -62
  48. package/src/front-end-utils/src/constants/pageUrl.js +2 -1
  49. package/src/routes/cors.js +55 -31
  50. package/src/routes/index.js +45 -41
  51. package/src/routes/mockRoutes/marketplaceManager/bootstrapContext.js +109 -499
  52. package/src/routes/mockRoutes/user/bootstrapContext.js +26 -432
  53. package/src/tools/prompt-questions.js +16 -3
  54. package/src/tools/toolkit-components-add.js +1 -4
  55. package/src/tools/toolkit-import.js +1 -1
@@ -1,427 +1,26 @@
1
1
  const bootstrapContext = {
2
- metaDescription: "AppSmart allows you to use and manage business applications in one simple and secure platform, from anywhere.",
3
- metaKeywords: "AppSmart, saas, applications, marketplace, web-based apps, business apps",
4
- analyticsId: "UA-121599838-2",
5
- marketPlaceName: "AppSmart Marketplace",
6
- theme: "appsmart",
7
- variation: null,
8
- locale: "en-US",
9
- localeLanguage: "en",
10
- dateFormat: "MM/DD/YY",
11
- dateTimeFormat: "MM/DD/YY h:mm:ss a",
12
- defaultCurrency: "USD",
13
- defaultCountry: "US",
14
- appWiseUrl: "https://appwise.appdirect.com",
15
- hermesOnInstance: true,
16
- hermesOnPartner: true,
17
- hermesSettingsFlag: true,
18
- hasCustomPaymentGateway: false,
19
- devMode: false,
20
- urlProvisioned: true,
21
- sftpConfigured: false,
22
- externalReportingEnabled: true,
23
- gdprSelfServiceEnabled: false,
24
- companyGroupsEnabled: true,
25
- paymentConnectorConfigV2Enabled: false,
26
- accountPaymentsUiV2Enabled: false,
27
- adminPaymentsUiV2Enabled: false,
28
- accountPaymentMethodUIV2Enabled: false,
29
- segmentConditionsOnNotification: true,
30
- emailAttachmentsEnabled: true,
31
- capitalCardEnabled: false,
32
- capitalAdvanceEnabled: false,
33
- capitalTradeEnabled: false,
34
- rcSettingsEnabled: false,
35
- notificationsContinuousProcessingEnabled: true,
36
- displayV2NotificationsOnly: false,
37
- customerOnboardingEnabled: false,
38
- notificationsCustomAttributesSupport: true,
39
- opportunitiesInQuotesListingEnabled: false,
40
- networkProductCustomizationFFValue: true,
41
- currencyFormats: {
42
- USD: {
43
- symbol: "$",
44
- decimal: ".",
45
- thousand: ",",
46
- precision: 2,
47
- format: "%s%v"
48
- }
49
- },
50
- universalHeaderSignalsSocketEndpoint: "wss://signals.us.appdirect.com",
51
- universalHeaderOAuthClientId: "6wGGP5zZih",
52
- clientConfiguredCorrectlyForImplicitFlow: true,
53
2
  UserInfo: {
54
- profilePic: null,
55
- name: "{Username} LastName",
56
- email: "Username.lastname@email.com",
57
- verified: true,
58
- locale: "en_US",
59
- tester: false,
60
- currency: "USD",
61
- hasCustomerContract: false,
62
- showSetupGuide: true,
63
- customerContractEditionUuids: [],
64
- ownedPartners: [],
65
- user_id: "1290b26b-ab80-4971-a4a2-1d9f333416cc",
66
- given_name: "{Username}",
67
- family_name: "LastName",
68
- company_id: "1b0c65dc-d4a0-4e12-a2a0-042412500721",
69
- roles: [
70
- "USER"
71
- ],
72
- attributes: {
73
- HAS_CUSTOMER_CONTRACT: "false"
74
- },
75
- customUserAttributes: {},
76
- customUserAttributesIds: {}
77
- },
78
- CHANNEL_SETTINGS: {
79
- partner: "APPSMART",
80
- linkedPartnerUrl: null,
81
- companyName: "AppSmart",
82
- allowSalesAgentEnterPaymentDetails: true,
83
- accountInvoiceV2Enabled: true,
84
- invoiceTemplatesEnabled: true,
85
- resellerInvoiceTemplatesEnabled: false,
86
- commissionsImporterEnabled: true,
87
- invoicePdfArchivalEnabled: true,
88
- invoiceRetentionPeriod: 120,
89
- meteredUsageEnabled: false,
90
- meteredUsageV2Enabled: false,
91
- invoicePaymentTerms: true,
92
- adminInvoiceV2: true,
93
- accountPurchaseUIEnabled: true,
94
- adminPurchaseUIEnabled: true,
95
- resellerPurchaseUIEnabled: false,
96
- developerPurchaseUIEnabled: false,
97
- providerQuotesEnabled: true,
98
- resellerInvoiceV2Enabled: false,
99
- resellerInvoiceSettingsEnabled: false,
100
- accountPaymentMethodUIV2: false,
101
- invoiceCoreFeed: true,
102
- creditNotesEnabled: false,
103
- marketplaceInvoiceSequenceNumber: false,
104
- fulfillmentActionsEnabled: true,
105
- shippingCostEnabled: false,
106
- developerFulfillmentActionsEnabled: false,
107
- localizationServiceEnabled: true,
108
- subscriptionCustomAttributesEnabled: true,
109
- purchaseCustomAttributesEnabled: true,
110
- assignmentToInactiveUsersEnabled: true,
111
- allowDiscountCredit: true,
112
- configuratorAddToCartCTAEnabled: false,
113
- useCheckoutV2ForAllProducts: true,
114
- showTermsConditionsInCheckoutV2: false,
115
- approvesUserContent: true,
3
+ profilePic: null,
4
+ name: "Marketplace",
5
+ email: "Username.lastname@email.com",
6
+ verified: true,
7
+ locale: "en_US",
8
+ tester: false,
116
9
  currency: "USD",
117
- currencies: [
118
- "USD"
119
- ],
120
- hideAllUI: false,
121
- hideQuestions: true,
122
- hideSupportSection: false,
123
- supportRequired: false,
124
- featuresRequired: true,
125
- identityProvider: false,
126
- includeCaptchaInRegistration: false,
127
- localeTags: [
128
- "en-US"
129
- ],
130
- defaultLocale: "en-US",
131
- defaultLocaleCountry: "US",
132
- defaultLocaleCountryIso3: "USA",
133
- minimumReviewsForRating: 1,
134
- oneClickTrialEnabled: false,
135
- channelDecidesIfOnlyAdminsCanBuy: false,
136
- collectPurchaseRequestDetails: true,
137
- partnerName: "AppSmart",
138
- recaptchaPublicKey: null,
139
- reviewRequirePurchase: true,
140
- displayTaxBreakdown: false,
141
- displayTaxSubtotal: false,
142
- flatTaxRate: null,
143
- supportContactUrl: "https://support.appsmart.com/",
144
- supportUrl: "https://support.appsmart.com/",
145
- supportPhone: "866-456-3211",
146
- supportEmail: "help@appsmart.com",
147
- privacyPolicyUrl: "https://www.appsmart.com/legal",
148
- legalDetailsUrl: null,
149
- termsUrl: "https://www.appsmart.com/legal",
150
- trustedProviders: [],
151
- agreeToTermsForOneClickBuy: false,
152
- importAppsEnabled: true,
153
- cmsCurrencies: [
154
- "USD"
155
- ],
156
- hideSignupLinks: true,
157
- appUserSyncBaseUrl: "https://prod-app-sync.cfapps.io",
158
- capabilities: [
159
- "DEVELOPER",
160
- "USER_MANAGEMENT",
161
- "CUSTOMER_APPLICATION_MANAGEMENT",
162
- "RESELLER",
163
- "CHANNEL_PAYMENT_GATEWAY",
164
- "RESELLER_SIGNUP",
165
- "CHANNEL_MANAGEMENT",
166
- "PRODUCT_PURCHASE",
167
- "QUESTIONS_AND_ANSWERS",
168
- "CHECKOUT",
169
- "CUSTOMER_BILLING_MANAGEMENT",
170
- "NETWORK_CATALOG",
171
- "STORE_FRONT",
172
- "SECURITY_SETTINGS",
173
- "FULL_PRODUCT_INTEGRATION",
174
- "MIGRATION",
175
- "PRODUCT_BUNDLES",
176
- "HOSTED_CHECKOUT",
177
- "DEVELOPER_NETWORK"
178
- ],
179
- boostEnabled: false,
180
- hideCustomerInfoFromDevelopers: false,
181
- developerDocsUrl: "https://docs.appdirect.com/developer/distribution",
182
- manualPaymentsOnly: false,
183
- hideBillingInfoShortcut: false,
184
- showInvoicePage: true,
185
- showPaymentPage: true,
186
- manualPaymentsEnabled: true,
187
- selfManagedCompanyStructure: false,
188
- externallyManagedRoles: false,
189
- guideProgresses: {
190
- CHANNEL: 1000,
191
- BILLING: 1000
192
- },
193
- integrationProvider: false,
194
- manualEventRecoveryEnabled: true,
195
- salesOpportunitiesEnabled: true,
196
- sendActivationEmailFromOpportunitiesEnabled: true,
197
- canFinalizeOpportunityWithInactiveUserEnabled: false,
198
- cannotSubmitOpportunityWithErrorsEnabled: true,
199
- salesLeadsEnabled: true,
200
- developerLeadsFlowEnabled: false,
201
- apiAndIntegrationEventsEnabled: false,
202
- developerCanSelectApplicationCountries: false,
203
- allowCheckoutV1FlowOnAssistedSale: true,
204
- developerCanSelectApplicationCurrencies: false,
205
- betaLeadsV2Enabled: true,
206
- betaLeadToOrderMultiProductEnabled: false,
207
- betaResellerDashboardEnabled: true,
208
- betaResellerDashboardChartsEnabled: true,
209
- resellerDashboardCreditMetricsEnabled: false,
210
- managePaymentsOfBehalfOfEnabled: true,
211
- domainsResellerEditionId: 480780,
212
- showProfiles: true,
213
- hideChannelUserInfoFromCustomers: true,
214
- resellerTermsUrl: "",
215
- resellerLeadsTermsUrl: "",
216
- showSocialMediaLinks: true,
217
- hidePricingsFromUnauthenticatedUserEnabled: false,
218
- showV2HomePageTheme: true,
219
- myAppsAfterLogin: true,
220
- showV2ListingPageTheme: true,
221
- showBillingCycleDay: false,
222
- showV2ProfilePageTheme: true,
223
- showV2CheckoutPageTheme: false,
224
- marketplaceEdition: "STORE",
225
- marketplaceName: "AppSmart Marketplace",
226
- customLogo: "https://d3bql97l1ytoxn.cloudfront.net/marketplace_logo/img7112784765708265925.jpg?f7ac0610eb204b73007248f09f36a0e9",
227
- customFavicon: "https://d3bql97l1ytoxn.cloudfront.net/marketplace_favicon/img7689238228774973938.jpg?69392dd2bff884a0931f8be7adda50bb",
228
- taxIncludedInPrices: false,
229
- taxExemptionCodeNotRestricted: false,
230
- useExternalIdForApi: false,
231
- buyingDeskEnabled: false,
232
- purchaseRemoteApprovalV2Enabled: false,
233
- accountStatus: "PAID",
234
- trialExpirationDate: null,
235
- baseSupportUrl: null,
236
- accountEdition: null,
237
- marketplaceAccount: null,
238
- autoUpgradeToPaid: true,
239
- autoPay: true,
240
- usePaymentService: true,
241
- flowThroughPaymentService: false,
242
- usePaymentsFramework: false,
243
- editionLevelOverride: true,
244
- termsForAllProductPurchasesRequired: false,
245
- termsForAllProductPurchasesUrl: null,
246
- usersCanCompleteOwnQuotes: true,
247
- oneClickMigrationEnabled: false,
248
- oneClickProvisioningEnabled: false,
249
- twoFactorEnabled: true,
250
- twoFactorTrustedDeviceEnabled: true,
251
- twoFactorTrustedDeviceForDaysCount: 14,
252
- smsGatewayType: "TWILIO",
253
- supportedProductTypes: [
254
- "STATIC",
255
- "WEB_APP",
256
- "EXTERNAL",
257
- "EMBEDDED_VIDEO",
258
- "WEB_APP_MANUAL_SETUP",
259
- "DOMAIN_RESELLER",
260
- "HARDWARE_SERVICE",
261
- "WEB_APP_STACKED",
262
- "CLOUD_SERVICES",
263
- "PHYSICAL_PRODUCT",
264
- "DOWNLOAD_WITH_FULL_PROFILE"
265
- ],
266
- changeOwnershipRequestEmail: null,
267
- domainReactivationEmail: null,
268
- reportsEmail: null,
269
- marketplaceCreditEnabled: false,
270
- smsNotificationsEnabled: false,
271
- walkMeEnabled: true,
272
- hasSampleContent: false,
273
- betaWholesaleQuotesEnabled: true,
274
- alwaysUseManualPaymentForCustomerOrders: false,
275
- allowChannelAdminToVoidInvoice: true,
276
- versionManagementApiClientId: null,
277
- passwordPolicy: "password.policy",
278
- passwordPolicyRegex: "(?=.{8,})((?=.*\d)|(?=.*\W))((?=.*[A-Z])|(?=.*[a-z])).*",
279
- selfServiceRestrictionEnabled: false,
280
- devicePlatformsEnabled: false,
281
- productVersionsEnabled: false,
282
- webAccessibleProductVersionsEnabled: false,
283
- deviceGroupsEnabled: false,
284
- betaShippingSettingsEnabled: true,
285
- channelPlatformManagementEnabled: true,
286
- channelDeviceManagementEnabled: true,
287
- deviceBrowsingEnabled: false,
288
- pushDistributionsEnabled: false,
289
- productVersionsBaseUrl: null,
290
- odsaBaseUrl: null,
291
- odsaRoleRestricted: true,
292
- betaAppleDepEnabled: false,
293
- webhookProxyInfo: {
294
- webhookProxyEnabled: false,
295
- webhookProxyUrl: null,
296
- webhookProxySecurityKey: null,
297
- webhookProxySecuritySecret: null
298
- },
299
- docCenterBaseLandingUrl: "https://ad.docs.appdirect.com/redirect/login?openid=",
300
- channelCanonicalBaseUrl: "https://marketplace.appsmart.com",
301
- showV2AppAssignments: true,
302
- showV2GroupAppAssignments: true,
303
- showV2RolesManagement: true,
304
- betaResellerProfileV2Enabled: true,
305
- reportingEnabled: false,
306
- demoFeatures: false,
307
- companyWideBilling: true,
308
- docCenterProvisioned: true,
309
- notificationsEnabled: true,
310
- advancedNotificationSystemState: "V1_V2_MERGED",
311
- resellerProfilesEnabled: true,
312
- genericUserSyncEnabled: true,
313
- dataConnectorsEnabled: true,
314
- fullAzureSyncEnabled: false,
315
- migrationVendorValidationEnabled: true,
316
- preAuthorizePayment: false,
317
- universalHeaderEnabled: true,
318
- universalHeaderForBusinessUnitsEnabled: true,
319
- fetchAccessTokenOnLoginEnabled: false,
320
- bundleProductsFromMultipleVendors: true,
321
- canExitCheckoutFlow: true,
322
- checkoutV2Enabled: true,
323
- useCompanyNameInBOBO: false,
324
- showFAQInBOBO: true,
325
- canDownloadOrderPDFInBOBO: true,
326
- countryDropdownConfigurable: false,
327
- supportedCountries: [],
328
- vatMandatoryCountries: [],
329
- defaultCountry: null,
330
- paymentSettingsV2: false,
331
- betaReferralCompaniesEnabled: true,
332
- baseChannel: false,
333
- developerReportCenterEnabled: false,
334
- companyAdminReportCenterEnabled: true,
335
- corporateAdminReportCenterEnabled: false,
336
- resellerReportCenterEnabled: true,
337
- resellerManagerReportCenterEnabled: true,
338
- reportCenterTemplatesEnabled: true,
339
- enhancedEcommerceAnalyticsEnabled: false,
340
- customizeThemeLinkEnabled: true,
341
- storefrontBuilderEnabled: true,
342
- storefrontBuilderPublishedThemeEnabled: true,
343
- storefrontBuilderLayoutEditorEnabled: false,
344
- allowNativeLogin: false,
345
- googleInboundConnectorEnabled: true,
346
- autoAddProductToResellerCatalog: false,
347
- allowNonUniqueEmailAddress: false,
348
- betaCompanyListV2Enabled: true,
349
- betaUserListV2Enabled: true,
350
- betaCompanyV2Enabled: true,
351
- managedUsersEnabled: true,
352
- betaUserV2Enabled: true,
353
- showCompanyExternalIdOnList: false,
354
- heapAnalyticsEnabled: false,
355
- phoneNumberRequired: false,
356
- allowExternalReferenceCode: false,
357
- betaPurchaseSetupEnabled: true,
358
- betaOpportunitiesEnabled: true,
359
- betaOnboardCspEnabled: true,
360
- addonStoreIntegrationEnabled: true,
361
- addonStoreUrl: "https://addons.appdirect.com",
362
- purchaseRemoteApprovalEnabled: false,
363
- delayInvoicingForCombinedPurchase: false,
364
- defaultSalePriceToMarketplaceSalePrice: false,
365
- showProductMarketplaceSalePrice: false,
366
- showWholesalePriceForMarketplace: false,
367
- allowDailyPurchaseLimitCompanyOverride: false,
368
- allowThirtyDaysPurchaseLimitCompanyOverride: false,
369
- reconciliationFundTransfersEnabled: true,
370
- bulkResellerReconciliationTransfersEnabled: true,
371
- paymentMethodPermissionsEnabled: true,
372
- taxIdentificationNumberValidationEnabled: false,
373
- disableCSRCSVDownload: false,
374
- disableSSRCSVDownload: false,
375
- companyBookmarkEnabled: false,
376
- checkoutV2UIEnabled: true,
377
- publishMicrosoftOrderEventsAsyncEnabled: false,
378
- syndicationToCspTransitionMenuLinkVisible: false,
379
- syncSettingsMenuLinkVisible: true,
380
- collectBillingAddressForOffPlatformPaymentMethodEnabled: false,
381
- hideSystemManagedGroups: false,
382
- gracefulBlockingEnabled: false,
383
- adpCustomizedErrorPageUrl: null,
384
- allowCreateCompaniesByUI: true,
385
- cartLockingEnabled: false,
386
- ownerBaseUrlMap: {
387
- APPDIRECT2: "https://store.appdirect.com"
10
+ hasCustomerContract: false,
11
+ showSetupGuide: true,
12
+ customerContractEditionUuids: [],
13
+ ownedPartners: [],
14
+ user_id: "9dda461e-e7cc-4137-85dd-fbe8b9f7e94e",
15
+ given_name: "John",
16
+ family_name: "Smith",
17
+ company_id: "1df65377-7269-4368-b671-1d129d966b4e",
18
+ roles: ["USER"],
19
+ attributes: {
20
+ HAS_CUSTOMER_CONTRACT: "false",
388
21
  },
389
- betaAccountActivationV2Enabled: true,
390
- licenseManagementEnabled: false,
391
- betaUserMembershipActivationV2Enabled: true,
392
- betaUserLoginV2Enabled: true,
393
- resellersTransferMethodPlatformType: "STRIPE",
394
- billingRelationshipsConfigurationEnabled: true,
395
- spreedlyConfigured: false,
396
- selfserveMarketplace: false,
397
- buyAlwaysRequiresBillingInfo: false,
398
- buyFreeTrialRequiresBillingInfo: true,
399
- buyFullyDiscountedRequiresBillingInfo: false,
400
- onlyAdminsCanBuy: true,
401
- alwaysUseManualPaymentForSalesAgentOrders: false,
402
- companyNotesEnabled: true,
403
- offOrderChargeEnabled: true,
404
- manageCompanyOnBehalfOf: true,
405
- resellerCatalogSecondaryNavItem: true,
406
- resellerAppSmartPortalChanges: true,
407
- enableDomainVerification: true,
408
- paymentFirstEnabled: false,
409
- usageReadersEnabled: false,
410
- externalUrlMap: {},
411
- canEnableSSRMigrationCompanyAccess: false,
412
- hideOriginalPriceToCustomer: false,
413
- networkProductCustomizationEnabled: true,
414
- exportReconciliationLinesEnabled: true,
415
- ldapSyncEnabled: false,
416
- listingOnly: false,
417
- test: false,
418
- cmsEnabled: true,
419
- baas: false,
420
- emailBasedIdp: false,
421
- inviteMarketplace: true,
422
- integrationConfigurationReadOnly: false,
423
- quoteConfiguredForResellers: true,
424
- salesAgentPurchaseApproved: false
22
+ customUserAttributes: {},
23
+ customUserAttributesIds: {},
425
24
  },
426
25
  CompanyInfo: {
427
26
  uuid: "3dc98547-47dd-47bb-9b01-4569be3412e6",
@@ -434,7 +33,7 @@ const bootstrapContext = {
434
33
  state: "NC",
435
34
  zip: "27604",
436
35
  country: "US",
437
- phone: "866-456-3211"
36
+ phone: "866-456-3211",
438
37
  },
439
38
  salesOpportunitiesEnabled: false,
440
39
  salesLeadsEnabled: false,
@@ -443,13 +42,14 @@ const bootstrapContext = {
443
42
  needsBoostMosiTerms: false,
444
43
  externalIdentifier: "2bc11cc0-f07f-e8b0-3b1f-5728e1e81fba",
445
44
  passwordPolicy: "password.policy",
446
- passwordPolicyRegex: "(?=.{8,})((?=.*\d)|(?=.*\W))((?=.*[A-Z])|(?=.*[a-z])).*",
45
+ passwordPolicyRegex:
46
+ "(?=.{8,})((?=.*d)|(?=.*W))((?=.*[A-Z])|(?=.*[a-z])).*",
447
47
  onlyAdminsCanBuy: false,
448
48
  importAppsEnabled: true,
449
49
  companyWideBilling: false,
450
50
  channelAdmin: true,
451
51
  vendor: true,
452
- reseller: false
52
+ reseller: false,
453
53
  },
454
54
  CurrentUser: {
455
55
  id: 10597822,
@@ -483,14 +83,8 @@ const bootstrapContext = {
483
83
  isReferral: false,
484
84
  isSysAdmin: false,
485
85
  isImpersonated: false,
486
- isSuperuser: false
86
+ isSuperuser: false,
487
87
  },
488
- WEBSHIM_PATH: "https://d6r6ulbtqyuv7.cloudfront.net/wicket/resource/com.appdirect.wicket.resources.Resource/common/js/vendor/webshim/js-webshim/minified/shims/",
489
- ACE_PATH: "https://d6r6ulbtqyuv7.cloudfront.net/wicket/resource/com.appdirect.wicket.resources.Resource/common/js/vendor/ace/src-min/",
490
- IMG_BASE: "https://d3bql97l1ytoxn.cloudfront.net",
491
- CONTEXT_PATH: "",
492
- SERVER_TIME_ZONE: "-04:00",
493
- DATE_PICKER_FORMAT: "mm/dd/yy"
494
- }
88
+ };
495
89
 
496
- module.exports = bootstrapContext
90
+ module.exports = bootstrapContext;
@@ -9,7 +9,7 @@ const {
9
9
  } = require("./toolkit-common-vars");
10
10
 
11
11
  const {
12
- PAGE_NAME_AND_ORDERABLE_TYPE_PROMPT,
12
+ PAGE_NAME_AND_ORDERABLE_TYPE_PROMPT
13
13
  } = require("./toolkit-common-vars-namespace");
14
14
 
15
15
  const {
@@ -18,6 +18,10 @@ const {
18
18
  getSfbThemeComponentsList,
19
19
  } = require("./toolkit-components-fun");
20
20
 
21
+ const {
22
+ FEATURE_AVAILABLE_SINCE_SFB_THEME_VERSION
23
+ } = require("./toolkit-components-vars");
24
+
21
25
  // small function to check if item has been defined
22
26
  const isDefined = (answer) => !!answer;
23
27
 
@@ -131,7 +135,7 @@ const licenseText = ` In order to use this software, please type 'agree' to acce
131
135
  const customComponentsHints = () => {
132
136
  const { overridesJavaScript, overridesSass } = getCustomComponentsInfo();
133
137
  return overridesJavaScript.length || overridesSass.length
134
- ? `\nSee below a list (none exhaustive) of custom components that should be ` +
138
+ ? `\nSee below a list (non exhaustive) of custom components that should be ` +
135
139
  `tested after changing the ${chalk.cyan(
136
140
  "@appdirect/sfb-theme-components"
137
141
  )} version:${
@@ -162,6 +166,15 @@ const isValidThemeFilePath = (toTest) => {
162
166
  return true;
163
167
  };
164
168
 
169
+ const getPageOptions = () => {
170
+ const sfbThemeCompVersion = getSfbThemeComponentsVersion().replace('^', '');
171
+ const pageOptions = PAGE_NAME_AND_ORDERABLE_TYPE_PROMPT.filter(page => {
172
+ // orderable option only available for sfb-theme-components@0.0.352 or newer
173
+ return sfbThemeCompVersion >= FEATURE_AVAILABLE_SINCE_SFB_THEME_VERSION || page?.value?.orderable !== true;
174
+ });
175
+ return pageOptions;
176
+ };
177
+
165
178
  // list of default questions that could be prompt to user
166
179
  const QUESTIONS = [
167
180
  {
@@ -286,7 +299,7 @@ const QUESTIONS = [
286
299
  {
287
300
  type: "list",
288
301
  name: "PageNameAndOrderableType",
289
- choices: PAGE_NAME_AND_ORDERABLE_TYPE_PROMPT,
302
+ choices: getPageOptions(),
290
303
  message: `Please select the page you wish to add the component to:`,
291
304
  },
292
305
  {
@@ -282,10 +282,7 @@ const addComponentFromBoilerplate = (
282
282
  if (page === "undefined") {
283
283
  console.log(`You can optionally add the component to a page as orderable or non-orderable.
284
284
  \nFor more information, please see our documentation:
285
- \u2022 Orderable: ${chalk.underline.bold(
286
- "https://developer.appdirect.com/storefront/how-tos/components/storefront-custom-components-layout"
287
- )}
288
- \u2022 Non-orderable: ${chalk.underline.bold(
285
+ \u2022 ${chalk.underline.bold(
289
286
  "https://developer.appdirect.com/storefront/how-tos/components/storefront-custom-components-add"
290
287
  )}\n`);
291
288
 
@@ -3,7 +3,7 @@ const extract = require('extract-zip');
3
3
  const path = require('path');
4
4
  const { spawnSync } = require("child_process");
5
5
  const { shouldBeProjectFolder, getAvailableFolderWithPrompt } = require("./toolkit-common-fun");
6
- const { CURRENT_PATH, PAGE_OBJECTS_SUFFIX, COMMAND_PARAM } = require("./toolkit-common-vars");
6
+ const { CURRENT_PATH, PAGE_OBJECTS_SUFFIX } = require("./toolkit-common-vars");
7
7
  const chalk = require("chalk");
8
8
  const prompt = require("./prompt-questions");
9
9
  const { LOCAL_CONFIG } = require("./toolkit-config");