From c97497b43f4be7e6567a701bfa463a1ac757967a Mon Sep 17 00:00:00 2001 From: Chris Date: Fri, 30 Jan 2026 09:01:00 -0800 Subject: [PATCH 1/2] refactor(athosify): rebrand everything to athos, link all docs to amc --- .../workflows/scripts/generatePatchFile.js | 4 +- 404.html | 2 +- CODE_OF_CONDUCT.md | 2 +- CONTRIBUTING.md | 2 +- LICENSE | 2 +- README.md | 2 +- SECURITY.md | 2 +- docs/ABOUT.md | 14 +- docs/ACCESSIBILITY_STATEMENT.md | 4 +- docs/BUILD_DEPLOY.md | 34 +- docs/BUILD_DEPLOY_INTEGRATION.md | 18 +- docs/BUILD_DEPLOY_INTEGRATION_BIGCOMMERCE.md | 96 +- docs/BUILD_DEPLOY_INTEGRATION_MAGENTO2.md | 118 +- docs/BUILD_DEPLOY_INTEGRATION_SHOPIFY.md | 128 +- docs/BUILD_DEPLOY_PERFORMANCE_OPTIMIZATION.md | 16 +- docs/REFERENCE_CONFIGURATION.md | 6 +- docs/REFERENCE_CONFIGURATION_MIDDLEWARE.md | 16 +- docs/REFERENCE_CONFIGURATION_TARGETERS.md | 4 +- docs/REFERENCE_CUSTOM_BADGE_TEMPLATES.md | 12 +- ...FERENCE_CUSTOM_RECOMMENDATION_TEMPLATES.md | 8 +- docs/SNAP_AUTOCOMPLETE.md | 6 +- docs/SNAP_BACKGROUND_FILTERS.md | 4 +- docs/SNAP_BADGES.md | 4 +- docs/SNAP_CLIENT.md | 16 +- docs/SNAP_FINDER.md | 12 +- docs/SNAP_OVERVIEW.md | 10 +- docs/SNAP_RECOMMENDATIONS.md | 20 +- docs/SNAP_RECOMMENDATIONS_INTEGRATION.md | 4 +- docs/SNAP_RECOMMENDATIONS_LEGACY.md | 4 +- docs/SNAP_SEARCH.md | 34 +- docs/SNAP_SETUP.md | 4 +- docs/SNAP_TRACKING.md | 44 +- docs/TEMPLATES_ABOUT.md | 6 +- docs/TEMPLATES_CONFIG.md | 16 +- docs/TEMPLATES_THEMING.md | 2 +- index.html | 2 +- package-lock.json | 31552 ++++++++-------- package.json | 4 +- packages/snap-client/README.md | 18 +- packages/snap-client/package.json | 6 +- .../snap-client/src/Client/Client.test.ts | 4 +- packages/snap-client/src/Client/Client.ts | 2 +- .../Client/NetworkCache/NetworkCache.test.ts | 4 +- .../src/Client/NetworkCache/NetworkCache.ts | 2 +- .../snap-client/src/Client/apis/Abstract.ts | 2 +- .../src/Client/apis/Hybrid.test.ts | 4 +- .../snap-client/src/Client/apis/Hybrid.ts | 2 +- .../src/Client/apis/Legacy.test.ts | 2 +- .../src/Client/apis/Recommend.test.ts | 2 +- .../snap-client/src/Client/apis/Recommend.ts | 2 +- .../src/Client/integration.node.test.ts | 2 +- .../src/Client/integration.test.ts | 18 +- .../src/Client/transforms/searchResponse.ts | 2 +- packages/snap-client/src/types.ts | 2 +- packages/snap-controller/README.md | 2 +- packages/snap-controller/package.json | 20 +- .../src/Abstract/AbstractController.test.ts | 18 +- .../src/Abstract/AbstractController.ts | 20 +- .../AutocompleteController.test.ts | 16 +- .../Autocomplete/AutocompleteController.ts | 8 +- .../src/Autocomplete/README.md | 2 +- .../src/Finder/FinderController.test.ts | 14 +- .../src/Finder/FinderController.ts | 6 +- packages/snap-controller/src/Finder/README.md | 2 +- .../src/Recommendation/README.md | 2 +- .../RecommendationController.test.ts | 14 +- .../RecommendationController.ts | 8 +- packages/snap-controller/src/Search/README.md | 4 +- .../src/Search/SearchController.test.ts | 16 +- .../src/Search/SearchController.ts | 8 +- packages/snap-controller/src/types.ts | 14 +- .../src/utils/getParams.test.ts | 2 +- .../snap-controller/src/utils/getParams.ts | 2 +- .../src/utils/isClickWithinProductLink.ts | 2 +- packages/snap-event-manager/package.json | 4 +- packages/snap-logger/package.json | 6 +- packages/snap-logger/src/Logger.test.ts | 4 +- packages/snap-logger/src/Logger.ts | 2 +- packages/snap-platforms/bigcommerce/README.md | 6 +- .../bigcommerce/src/addToCart.test.ts | 20 +- .../bigcommerce/src/addToCart.ts | 2 +- .../pluginBigcommerceAddToCart.test.ts | 16 +- .../src/plugins/pluginBigcommerceAddToCart.ts | 6 +- ...pluginBigcommerceBackgroundFilters.test.ts | 16 +- .../pluginBigcommerceBackgroundFilters.ts | 6 +- packages/snap-platforms/common/README.md | 22 +- .../src/plugins/pluginAddToCart.test.ts | 16 +- .../common/src/plugins/pluginAddToCart.ts | 6 +- .../plugins/pluginBackgroundFilters.test.ts | 16 +- .../src/plugins/pluginBackgroundFilters.ts | 4 +- .../common/src/plugins/pluginLogger.test.ts | 16 +- .../common/src/plugins/pluginLogger.ts | 2 +- .../src/plugins/pluginScrollToTop.test.ts | 16 +- .../common/src/plugins/pluginScrollToTop.ts | 2 +- packages/snap-platforms/common/src/types.ts | 2 +- packages/snap-platforms/magento2/README.md | 4 +- .../magento2/src/addToCart.test.ts | 18 +- .../snap-platforms/magento2/src/addToCart.ts | 2 +- .../snap-platforms/magento2/src/getFormKey.ts | 2 +- .../plugins/pluginMagento2AddToCart.test.ts | 16 +- .../src/plugins/pluginMagento2AddToCart.ts | 6 +- .../pluginMagento2BackgroundFilters.test.ts | 16 +- .../pluginMagento2BackgroundFilters.ts | 6 +- packages/snap-platforms/package.json | 10 +- packages/snap-platforms/shopify/README.md | 10 +- .../shopify/src/addToCart.test.ts | 18 +- .../snap-platforms/shopify/src/addToCart.ts | 2 +- .../plugins/pluginShopifyAddToCart.test.ts | 16 +- .../src/plugins/pluginShopifyAddToCart.ts | 6 +- .../pluginShopifyBackgroundFilters.test.ts | 16 +- .../plugins/pluginShopifyBackgroundFilters.ts | 6 +- .../pluginShopifyMutateResults.test.ts | 16 +- .../src/plugins/pluginShopifyMutateResults.ts | 6 +- packages/snap-preact-demo/package.json | 6 +- packages/snap-preact-demo/public/index.html | 2 +- .../snap-preact-demo/public/snap/bundle.html | 6 +- .../snap-preact-demo/public/snap/cart.html | 6 +- .../public/snap/category.html | 8 +- .../snap-preact-demo/public/snap/email.html | 4 +- .../snap-preact-demo/public/snap/finder.html | 6 +- .../snap-preact-demo/public/snap/index.html | 8 +- .../snap-preact-demo/public/snap/order.html | 6 +- .../snap-preact-demo/public/snap/product.html | 6 +- .../public/snap/recommendations.html | 6 +- .../public/templates/base.html | 4 +- .../public/templates/bundle.html | 6 +- .../public/templates/email.html | 4 +- .../public/templates/index.html | 8 +- .../public/templates/product.html | 6 +- .../public/templates/recommendations.html | 6 +- .../components/Autocomplete/Autocomplete.tsx | 4 +- .../snap/src/components/Content/Content.tsx | 4 +- .../snap/src/components/Content/Skel.tsx | 2 +- .../FilterSummary/FilterSummary.tsx | 2 +- .../snap/src/components/Header/Header.tsx | 2 +- .../Recommendations/Bundles/Bundles.tsx | 2 +- .../Recommendations/Email/Email.tsx | 2 +- .../components/Recommendations/Recs/Recs.tsx | 2 +- .../snap/src/components/Results/Results.tsx | 2 +- .../snap/src/components/Sidebar/Sidebar.tsx | 2 +- .../snap/src/components/Sidebar/Skel.tsx | 2 +- .../snap/src/components/Toolbar/PerPage.tsx | 2 +- .../snap/src/components/Toolbar/SortBy.tsx | 2 +- .../snap/src/components/Toolbar/Toolbar.tsx | 2 +- packages/snap-preact-demo/snap/src/index.ts | 22 +- .../snap/src/middleware/plugins/afterStore.ts | 2 +- packages/snap-preact-demo/snap/src/modern.ts | 4 +- .../snap-preact-demo/snap/src/universal.ts | 8 +- .../snap/webpack.universal.js | 2 +- .../templates/src/components/Result.tsx | 6 +- .../snap-preact-demo/templates/src/index.ts | 6 +- .../snap-preact-demo/templates/src/modern.ts | 4 +- .../templates/src/universal.ts | 8 +- .../templates/webpack.universal.js | 2 +- .../e2e/autocomplete/autocomplete.cy.js | 4 +- .../cypress/e2e/core/branchOverride.cy.js | 8 +- .../templates/autocomplete/autocomplete.cy.js | 8 +- .../e2e/templates/core/branchOverride.cy.js | 8 +- .../cypress/e2e/templates/search/query.cy.js | 4 +- .../templates/searchHorizontal/query.cy.js | 4 +- .../tests/cypress/support/commands.js | 18 +- .../tests/cypress/support/e2e.js | 2 +- .../tests/lighthouse/public/lighthouse.html | 2 +- packages/snap-preact-demo/types.ts | 10 +- packages/snap-preact-demo/webpack.common.js | 2 +- packages/snap-preact-demo/webpack.dev.js | 4 +- packages/snap-preact/README.md | 22 +- .../{searchspringTheme.ts => AthosTheme.ts} | 2 +- .../components/.storybook/manager.ts | 6 +- .../components/.storybook/preview-head.html | 2 +- .../src/components/Atoms/BadgeImage/readme.md | 2 +- .../src/components/Atoms/BadgePill/readme.md | 2 +- .../components/Atoms/BadgeRectangle/readme.md | 2 +- .../src/components/Atoms/BadgeText/readme.md | 2 +- .../Atoms/Breadcrumbs/Breadcrumbs.tsx | 2 +- .../components/Atoms/Breadcrumbs/readme.md | 2 +- .../src/components/Atoms/Button/readme.md | 2 +- .../src/components/Atoms/Dropdown/readme.md | 2 +- .../Atoms/FormattedNumber/FormattedNumber.tsx | 2 +- .../Atoms/FormattedNumber/readme.md | 4 +- .../src/components/Atoms/Icon/readme.md | 2 +- .../src/components/Atoms/Image/Image.test.tsx | 2 +- .../src/components/Atoms/Image/readme.md | 2 +- .../src/components/Atoms/Loading/readme.md | 2 +- .../Merchandising/Banner/Banner.stories.tsx | 2 +- .../Merchandising/Banner/Banner.test.tsx | 4 +- .../Atoms/Merchandising/Banner/Banner.tsx | 4 +- .../Atoms/Merchandising/Banner/readme.md | 4 +- .../InlineBanner/InlineBanner.stories.tsx | 4 +- .../InlineBanner/InlineBanner.test.tsx | 4 +- .../InlineBanner/InlineBanner.tsx | 2 +- .../Merchandising/InlineBanner/readme.md | 2 +- .../src/components/Atoms/Overlay/readme.md | 2 +- .../PaginationInfo/PaginationInfo.stories.tsx | 2 +- .../PaginationInfo/PaginationInfo.test.tsx | 6 +- .../Atoms/PaginationInfo/PaginationInfo.tsx | 4 +- .../src/components/Atoms/Price/Price.tsx | 2 +- .../src/components/Atoms/Price/readme.md | 4 +- .../SearchHeader/SearchHeader.stories.tsx | 2 +- .../Atoms/SearchHeader/SearchHeader.test.tsx | 6 +- .../Atoms/SearchHeader/SearchHeader.tsx | 4 +- .../src/components/Atoms/Skeleton/readme.md | 2 +- .../Atoms/TemplateSelect/TemplateSelect.tsx | 2 +- .../CalloutBadge/CalloutBadge.stories.tsx | 4 +- .../CalloutBadge/CalloutBadge.test.tsx | 6 +- .../Molecules/CalloutBadge/CalloutBadge.tsx | 2 +- .../Molecules/CalloutBadge/readme.md | 8 +- .../Molecules/Carousel/Carousel.test.tsx | 4 +- .../components/Molecules/Carousel/readme.md | 2 +- .../components/Molecules/Checkbox/readme.md | 2 +- .../ErrorHandler/ErrorHandler.stories.tsx | 2 +- .../ErrorHandler/ErrorHandler.test.tsx | 2 +- .../Molecules/ErrorHandler/ErrorHandler.tsx | 4 +- .../Molecules/ErrorHandler/readme.md | 8 +- .../FacetGridOptions.stories.tsx | 2 +- .../FacetGridOptions.test.tsx | 4 +- .../FacetGridOptions/FacetGridOptions.tsx | 2 +- .../Molecules/FacetGridOptions/readme.md | 2 +- .../FacetHierarchyOptions.stories.tsx | 2 +- .../FacetHierarchyOptions.test.tsx | 6 +- .../FacetHierarchyOptions.tsx | 2 +- .../Molecules/FacetHierarchyOptions/readme.md | 2 +- .../FacetListOptions.stories.tsx | 2 +- .../FacetListOptions.test.tsx | 6 +- .../FacetListOptions/FacetListOptions.tsx | 2 +- .../Molecules/FacetListOptions/readme.md | 2 +- .../FacetPaletteOptions.stories.tsx | 2 +- .../FacetPaletteOptions.test.tsx | 4 +- .../FacetPaletteOptions.tsx | 4 +- .../Molecules/FacetPaletteOptions/readme.md | 2 +- .../FacetSlider/FacetSlider.stories.tsx | 2 +- .../FacetSlider/FacetSlider.test.tsx | 4 +- .../Molecules/FacetSlider/FacetSlider.tsx | 2 +- .../Molecules/FacetSlider/readme.md | 2 +- .../FacetToggle/FacetToggle.stories.tsx.nope | 2 +- .../FacetToggle/FacetToggle.test.tsx.nope | 4 +- .../FacetToggle/FacetToggle.tsx.nope | 2 +- .../Molecules/Filter/Filter.stories.tsx | 2 +- .../Molecules/Filter/Filter.test.tsx | 6 +- .../components/Molecules/Filter/Filter.tsx | 4 +- .../src/components/Molecules/Filter/readme.md | 2 +- .../src/components/Molecules/Grid/Grid.tsx | 2 +- .../src/components/Molecules/Grid/readme.md | 2 +- .../Molecules/List/List.stories.tsx | 2 +- .../src/components/Molecules/List/List.tsx | 2 +- .../src/components/Molecules/List/readme.md | 2 +- .../Molecules/LoadMore/LoadMore.stories.tsx | 2 +- .../Molecules/LoadMore/LoadMore.test.tsx | 6 +- .../Molecules/LoadMore/LoadMore.tsx | 4 +- .../src/components/Molecules/Modal/Modal.tsx | 2 +- .../OverlayBadge/OverlayBadge.stories.tsx | 4 +- .../OverlayBadge/OverlayBadge.test.tsx | 6 +- .../Molecules/OverlayBadge/OverlayBadge.tsx | 4 +- .../Molecules/OverlayBadge/readme.md | 8 +- .../Pagination/Pagination.stories.tsx | 2 +- .../Molecules/Pagination/Pagination.test.tsx | 6 +- .../Molecules/Pagination/Pagination.tsx | 4 +- .../components/Molecules/Pagination/readme.md | 2 +- .../Molecules/PerPage/PerPage.stories.tsx | 2 +- .../Molecules/PerPage/PerPage.test.tsx | 6 +- .../components/Molecules/PerPage/PerPage.tsx | 4 +- .../Molecules/RadioList/RadioList.stories.tsx | 2 +- .../Molecules/Result/Result.stories.tsx | 4 +- .../Molecules/Result/Result.test.tsx | 6 +- .../components/Molecules/Result/Result.tsx | 6 +- .../src/components/Molecules/Result/readme.md | 2 +- .../Molecules/SearchInput/readme.md | 2 +- .../Molecules/Select/Select.stories.tsx | 2 +- .../src/components/Molecules/Select/readme.md | 2 +- .../components/Molecules/Slideout/readme.md | 2 +- .../Molecules/SortBy/SortBy.stories.tsx | 2 +- .../Molecules/SortBy/SortBy.test.tsx | 6 +- .../components/Molecules/SortBy/SortBy.tsx | 4 +- .../Molecules/Swatches/Swatches.tsx | 2 +- .../components/Molecules/Swatches/readme.md | 2 +- .../TemplatesEditor/TemplatesEditor.tsx | 2 +- .../Molecules/Terms/Terms.stories.tsx | 6 +- .../components/Molecules/Terms/Terms.test.tsx | 14 +- .../src/components/Molecules/Terms/Terms.tsx | 6 +- .../VariantSelection.stories.tsx | 4 +- .../VariantSelection/VariantSelection.tsx | 4 +- .../Molecules/VariantSelection/readme.md | 2 +- .../Autocomplete/Autocomplete.stories.tsx | 2 +- .../Autocomplete/Autocomplete.test.tsx | 69 +- .../Organisms/Autocomplete/Autocomplete.tsx | 8 +- .../Organisms/Autocomplete/readme.md | 2 +- .../AutocompleteLayout.stories.tsx | 2 +- .../AutocompleteLayout.test.tsx | 34 +- .../AutocompleteLayout/AutocompleteLayout.tsx | 4 +- .../Organisms/BranchOverride/readme.md | 6 +- .../Organisms/Facet/Facet.stories.tsx | 2 +- .../components/Organisms/Facet/Facet.test.tsx | 6 +- .../src/components/Organisms/Facet/Facet.tsx | 4 +- .../src/components/Organisms/Facet/readme.md | 2 +- .../Organisms/Facets/Facets.stories.tsx | 2 +- .../Organisms/Facets/Facets.test.tsx | 2 +- .../components/Organisms/Facets/Facets.tsx | 4 +- .../src/components/Organisms/Facets/readme.md | 2 +- .../FacetsHorizontal.stories.tsx | 2 +- .../FacetsHorizontal.test.tsx | 2 +- .../FacetsHorizontal/FacetsHorizontal.tsx | 4 +- .../FilterSummary/FilterSummary.stories.tsx | 2 +- .../FilterSummary/FilterSummary.test.tsx | 6 +- .../Organisms/FilterSummary/FilterSummary.tsx | 4 +- .../Organisms/FilterSummary/readme.md | 2 +- .../components/Organisms/Layout/Layout.tsx | 4 +- .../MobileSidebar/MobileSidebar.stories.tsx | 2 +- .../MobileSidebar/MobileSidebar.test.tsx | 16 +- .../Organisms/MobileSidebar/MobileSidebar.tsx | 2 +- .../Organisms/NoResults/NoResults.tsx | 6 +- .../Organisms/Results/Results.stories.tsx | 2 +- .../Organisms/Results/Results.test.tsx | 18 +- .../components/Organisms/Results/Results.tsx | 6 +- .../components/Organisms/Results/readme.md | 2 +- .../Organisms/Sidebar/Sidebar.stories.tsx | 2 +- .../Organisms/Sidebar/Sidebar.test.tsx | 16 +- .../components/Organisms/Sidebar/Sidebar.tsx | 2 +- .../Organisms/TermsList/TermsList.stories.tsx | 6 +- .../Organisms/TermsList/TermsList.test.tsx | 10 +- .../Organisms/TermsList/TermsList.tsx | 2 +- .../Organisms/Toolbar/Toolbar.stories.tsx | 2 +- .../Organisms/Toolbar/Toolbar.test.tsx | 16 +- .../components/Organisms/Toolbar/Toolbar.tsx | 2 +- .../AutocompleteFixed.stories.tsx | 2 +- .../AutocompleteFixed.test.tsx | 26 +- .../AutocompleteFixed/AutocompleteFixed.tsx | 4 +- .../AutocompleteModal.stories.tsx | 2 +- .../AutocompleteModal.test.tsx | 22 +- .../AutocompleteModal/AutocompleteModal.tsx | 2 +- .../AutocompleteSlideout.stories.tsx | 2 +- .../AutocompleteSlideout.test.tsx | 22 +- .../AutocompleteSlideout.tsx | 2 +- .../Recommendation/Recommendation.stories.tsx | 6 +- .../Recommendation/Recommendation.test.tsx | 16 +- .../Recommendation/Recommendation.tsx | 4 +- .../Templates/Recommendation/readme.md | 2 +- .../RecommendationBundle/BundleCTA.tsx | 2 +- .../RecommendationBundle.stories.tsx | 8 +- .../RecommendationBundle.test.tsx | 16 +- .../RecommendationBundle.tsx | 4 +- .../Templates/RecommendationBundle/readme.md | 2 +- .../RecommendationBundleEasyAdd.stories.tsx | 8 +- .../RecommendationBundleList.stories.tsx | 8 +- .../RecommendationBundleVertical.stories.tsx | 8 +- .../RecommendationEmail.stories.tsx | 6 +- .../RecommendationEmail.test.tsx | 16 +- .../RecommendationEmail.tsx | 4 +- .../RecommendationGrid.stories.tsx | 2 +- .../RecommendationGrid.test.tsx | 16 +- .../RecommendationGrid/RecommendationGrid.tsx | 4 +- .../Templates/Search/Search.stories.tsx | 2 +- .../Templates/Search/Search.test.tsx | 16 +- .../components/Templates/Search/Search.tsx | 4 +- .../SearchBoca/SearchBoca.stories.tsx | 2 +- .../Templates/SearchBoca/SearchBoca.tsx | 2 +- .../SearchHorizontal.stories.tsx | 2 +- .../SearchHorizontal/SearchHorizontal.tsx | 2 +- .../SearchSnapnco/SearchSnapco.stories.tsx | 2 +- .../Templates/SearchSnapnco/SearchSnapnco.tsx | 2 +- .../SearchSnappy/SearchSnappy.stories.tsx | 2 +- .../Templates/SearchSnappy/SearchSnappy.tsx | 2 +- .../RecommendationProfileTracker.tsx | 2 +- .../ResultTracker/ResultTracker.stories.tsx | 4 +- .../ResultTracker/ResultTracker.test.tsx | 16 +- .../Trackers/ResultTracker/ResultTracker.tsx | 4 +- .../Trackers/ResultTracker/readme.md | 2 +- .../src/documentation/About/About.md | 4 +- .../src/documentation/Theme/Theme.md | 2 +- .../src/documentation/Usage/Usage.md | 8 +- .../hooks/createRecommendationTemplate.tsx | 2 +- .../src/hooks/useAcRenderedInput.tsx | 2 +- .../src/hooks/useControllerStorage.tsx | 2 +- .../src/hooks/useCreateController.tsx | 2 +- .../src/hooks/useDisplaySettings.tsx | 2 +- .../components/src/hooks/useTracking.tsx | 4 +- .../components/src/providers/controller.tsx | 2 +- .../components/src/providers/store.tsx | 2 +- .../components/src/providers/withTracking.tsx | 4 +- packages/snap-preact/components/src/types.ts | 6 +- .../components/src/utilities/parseProps.tsx | 2 +- .../components/src/utilities/snapify.ts | 22 +- .../molecules/bundleRecommendation.cy.tsx | 16 +- .../component/molecules/recommendation.cy.tsx | 16 +- .../molecules/variantSelection.cy.tsx | 16 +- .../tests/cypress/support/commands.js | 15 +- packages/snap-preact/package.json | 24 +- .../snap-preact/src/Instantiators/README.md | 2 +- .../RecommendationInstantiator.test.tsx | 12 +- .../RecommendationInstantiator.tsx | 26 +- packages/snap-preact/src/Snap.test.tsx | 60 +- packages/snap-preact/src/Snap.tsx | 91 +- .../src/Templates/SnapTemplates.test.tsx | 2 +- .../src/Templates/SnapTemplates.tsx | 24 +- .../src/Templates/Stores/LibraryStore.ts | 2 +- .../src/Templates/Stores/TargetStore.test.ts | 2 +- .../TemplateEditor/TemplateEditorStore.ts | 4 +- .../autocompleteControllerUI.ts | 2 +- .../TemplateEditor/uiAbstractions/configUI.ts | 2 +- .../uiAbstractions/searchControllerUI.ts | 2 +- .../TemplateEditor/uiAbstractions/themeUI.ts | 2 +- .../src/Templates/Stores/TemplateStore.ts | 16 +- .../src/Templates/Stores/ThemeStore.test.ts | 4 +- .../src/Templates/Stores/ThemeStore.tsx | 2 +- .../Templates/Stores/library/languages/es.ts | 2 +- .../Templates/Stores/library/languages/fr.ts | 2 +- .../plugins/bigCommerce/pluginAddToCart.ts | 2 +- .../bigCommerce/pluginBackgroundFilters.ts | 2 +- .../library/plugins/common/pluginAddToCart.ts | 2 +- .../plugins/common/pluginBackgroundFilters.ts | 2 +- .../library/plugins/common/pluginLogger.ts | 2 +- .../plugins/common/pluginScrollToTop.ts | 2 +- .../plugins/magento2/pluginAddToCart.ts | 2 +- .../magento2/pluginBackgroundFilters.ts | 2 +- .../plugins/shopify/pluginAddToCart.ts | 2 +- .../shopify/pluginBackgroundFilters.ts | 2 +- .../plugins/shopify/pluginMutateResults.ts | 2 +- .../createAutocompleteController.test.ts | 18 +- .../create/createAutocompleteController.ts | 16 +- .../src/create/createFinderController.test.ts | 18 +- .../src/create/createFinderController.ts | 16 +- .../createRecommendationController.test.ts | 18 +- .../create/createRecommendationController.ts | 16 +- .../src/create/createSearchController.test.ts | 18 +- .../src/create/createSearchController.ts | 16 +- .../getBundleDetails/getBundleDetails.test.ts | 4 +- .../getInitialUrlState.test.ts | 2 +- .../getInitialUrlState/getInitialUrlState.ts | 2 +- packages/snap-preact/src/integration.test.tsx | 12 +- packages/snap-preact/src/setupEvents.test.tsx | 4 +- packages/snap-preact/src/setupEvents.ts | 10 +- packages/snap-preact/src/types.ts | 19 +- .../configureSnapFeatures.ts | 4 +- packages/snap-preact/toolbox/src/index.ts | 2 +- packages/snap-profiler/package.json | 4 +- packages/snap-shared/package.json | 6 +- .../snap-shared/src/MockClient/MockClient.ts | 2 +- packages/snap-shared/src/MockData/MockData.ts | 5 +- packages/snap-store-mobx/README.md | 2 +- packages/snap-store-mobx/package.json | 12 +- .../snap-store-mobx/src/Abstract/README.md | 2 +- .../Autocomplete/AutocompleteStore.test.ts | 6 +- .../src/Autocomplete/AutocompleteStore.ts | 4 +- .../src/Autocomplete/README.md | 6 +- .../Stores/AutocompleteFacetStore.test.ts | 4 +- .../Stores/AutocompleteHistoryStore.test.ts | 2 +- .../Stores/AutocompleteQueryStore.test.ts | 6 +- .../Stores/AutocompleteQueryStore.ts | 2 +- .../Stores/AutocompleteStateStore.test.ts | 2 +- .../Stores/AutocompleteStateStore.ts | 2 +- .../Stores/AutocompleteTermStore.test.ts | 6 +- .../Stores/AutocompleteTermStore.ts | 2 +- .../Stores/AutocompleteTrendingStore.test.ts | 4 +- .../Stores/AutocompleteTrendingStore.ts | 2 +- .../src/Cart/CartStore.test.ts | 2 +- .../snap-store-mobx/src/Cart/CartStore.ts | 4 +- .../src/Finder/FinderStore.test.ts | 4 +- .../snap-store-mobx/src/Finder/FinderStore.ts | 4 +- packages/snap-store-mobx/src/Finder/README.md | 6 +- .../Stores/FinderSelectionStore.test.ts | 4 +- .../src/Meta/MetaStore.test.ts | 2 +- packages/snap-store-mobx/src/Meta/README.md | 2 +- .../src/Recommendation/README.md | 8 +- .../RecommendationStore.test.ts | 4 +- .../src/Recommendation/RecommendationStore.ts | 2 +- .../Stores/RecommendationProfileStore.test.ts | 4 +- .../Stores/RecommendationProfileStore.ts | 2 +- packages/snap-store-mobx/src/Search/README.md | 16 +- .../src/Search/SearchStore.test.ts | 4 +- .../Search/Stores/SearchFacetStore.test.ts | 4 +- .../src/Search/Stores/SearchFacetStore.ts | 2 +- .../Search/Stores/SearchFilterStore.test.ts | 4 +- .../src/Search/Stores/SearchFilterStore.ts | 4 +- .../Search/Stores/SearchHistoryStore.test.ts | 2 +- .../src/Search/Stores/SearchHistoryStore.ts | 2 +- .../Stores/SearchMerchandisingStore.test.ts | 2 +- .../Stores/SearchPaginationStore.test.ts | 4 +- .../Search/Stores/SearchPaginationStore.ts | 2 +- .../Search/Stores/SearchQueryStore.test.ts | 4 +- .../src/Search/Stores/SearchQueryStore.ts | 4 +- .../Search/Stores/SearchResultStore.test.ts | 2 +- .../Search/Stores/SearchSortingStore.test.ts | 4 +- .../src/Search/Stores/SearchSortingStore.ts | 2 +- .../snap-store-mobx/src/Storage/README.md | 2 +- .../src/Storage/StorageStore.ts | 2 +- packages/snap-store-mobx/src/types.ts | 4 +- packages/snap-toolbox/README.md | 4 +- packages/snap-toolbox/package.json | 4 +- .../snap-toolbox/src/DomTargeter/README.md | 4 +- .../snap-toolbox/src/charsParams/README.md | 2 +- packages/snap-toolbox/src/cookies/README.md | 2 +- packages/snap-toolbox/src/debounce/README.md | 2 +- .../snap-toolbox/src/featureFlags/README.md | 2 +- packages/snap-toolbox/src/filters/README.md | 2 +- .../snap-toolbox/src/getContext/README.md | 12 +- .../src/getContext/getContext.test.ts | 35 +- .../snap-toolbox/src/getContext/getContext.ts | 17 +- packages/snap-toolbox/src/until/README.md | 2 +- packages/snap-toolbox/src/url/README.md | 2 +- packages/snap-toolbox/src/version/version.ts | 2 +- packages/snap-tracker/package.json | 8 +- packages/snap-tracker/src/Tracker.ts | 23 +- packages/snap-tracker/src/types.ts | 3 +- packages/snap-url-manager/README.md | 2 +- packages/snap-url-manager/package.json | 4 +- .../src/Translators/QueryString/README.md | 4 +- .../src/Translators/README.md | 2 +- .../src/Translators/Url/README.md | 8 +- packages/snapps/README.md | 2 +- tsconfig.json | 3 +- 509 files changed, 17757 insertions(+), 17315 deletions(-) rename packages/snap-preact/components/.storybook/{searchspringTheme.ts => AthosTheme.ts} (88%) diff --git a/.github/workflows/scripts/generatePatchFile.js b/.github/workflows/scripts/generatePatchFile.js index 2f61729333..1bd8a8a3f6 100644 --- a/.github/workflows/scripts/generatePatchFile.js +++ b/.github/workflows/scripts/generatePatchFile.js @@ -28,8 +28,8 @@ steps: - update: properties: "dependencies": { - "@searchspring/snap-${args.framework}": "${args.version}", - "@searchspring/snap-${args.framework}-components": "${args.version}" + "@athoscommerce/snap-${args.framework}": "${args.version}", + "@athoscommerce/snap-${args.framework}-components": "${args.version}" } `.trim(); diff --git a/404.html b/404.html index d02aeace3f..fb37f5ac88 100644 --- a/404.html +++ b/404.html @@ -24,7 +24,7 @@ - +
diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index f409046620..5072d05a4b 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -1,3 +1,3 @@ # Citizen Code of Conduct -Reference Searchspring's community [CODE_OF_CONDUCT.md](https://github.com/searchspring/community/blob/main/CODE_OF_CONDUCT.md) \ No newline at end of file +Reference Athos's community [CODE_OF_CONDUCT.md](https://github.com/searchspring/community/blob/main/CODE_OF_CONDUCT.md) \ No newline at end of file diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index ba817f60b3..a2d2cc529d 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,3 +1,3 @@ # Contributing -Reference Searchspring's community [CONTRIBUTING.md](https://github.com/searchspring/community/blob/main/CONTRIBUTING.md) \ No newline at end of file +Reference Athos's community [CONTRIBUTING.md](https://github.com/searchspring/community/blob/main/CONTRIBUTING.md) \ No newline at end of file diff --git a/LICENSE b/LICENSE index 95b5725ef3..41fdc87d56 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2022 Searchspring +Copyright (c) 2022 Athos Commerce Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 38b803eec3..fe070e3bf8 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ # Snap 1.0 -Welcome to Snap - Searchspring's SDK for integrating into front end web apps. We invite your participation through issues, discussions and pull requests! Please reference Searchspring's [Community Contribution Guidelines](https://github.com/searchspring/community/blob/main/CONTRIBUTING.md). +Welcome to Snap - Athos Commerce's SDK for integrating into front end web apps. We invite your participation through issues, discussions and pull requests! Please reference Athos's [Community Contribution Guidelines](https://github.com/searchspring/community/blob/main/CONTRIBUTING.md). Please reference the [Snap Documentation](https://searchspring.github.io/snap/) to get started using Snap to build applications. diff --git a/SECURITY.md b/SECURITY.md index e28c6f73a0..bb66002e96 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -1,4 +1,4 @@ # Security Policy -Reference Searchspring's community [SECURITY.md](https://github.com/searchspring/community/blob/main/SECURITY.md) +Reference Athos's community [SECURITY.md](https://github.com/searchspring/community/blob/main/SECURITY.md) diff --git a/docs/ABOUT.md b/docs/ABOUT.md index 00dd1118be..4aeffeea34 100644 --- a/docs/ABOUT.md +++ b/docs/ABOUT.md @@ -1,8 +1,8 @@ # Snap Documentation -Snap is not an acronym! Snap is an open source SDK for building e-commerce experiences powered by Searchspring. +Snap is not an acronym! Snap is an open source SDK for building e-commerce experiences powered by Athos. -The SDK includes multiple core packages published to npm that in combination with each other, provide the complete front-end tooling for building e-commerce experiences with Searchspring. However to simplify usage, the `@searchspring/snap-preact` package is an abstraction that combines all core packages into a single dependency in combination with Preact to render the UI. This documentation is primarily focused on the usage of this package. +The SDK includes multiple core packages published to npm that in combination with each other, provide the complete front-end tooling for building e-commerce experiences with Athos. However to simplify usage, the `@athoscommerce/snap-preact` package is an abstraction that combines all core packages into a single dependency in combination with Preact to render the UI. This documentation is primarily focused on the usage of this package. ## Getting Started @@ -14,7 +14,7 @@ Additionally, the Reference section contains the most comprehensive and technica ### Snap Integration -A "Snap Integration" is a project that uses the `Snap` export from the `@searchspring/snap-preact` package to build a storefront integration. It provides the ability to create multiple controllers, custom plugins, and full custom markup to match the storefront markup and inherit styles. It is the most flexible and powerful way to integrate Searchspring into your storefront. +A "Snap Integration" is a project that uses the `Snap` export from the `@athoscommerce/snap-preact` package to build a storefront integration. It provides the ability to create multiple controllers, custom plugins, and full custom markup to match the storefront markup and inherit styles. It is the most flexible and powerful way to integrate Athos into your storefront. An example Snap Integration project can be found [here](https://github.com/searchspring-implementations/demo.shopify). @@ -22,15 +22,15 @@ Continue by referencing the [Snap Setup](https://searchspring.github.io/snap/sna ### Snap Templates Integration -A "Snap Templates Integration" is a project that uses the `SnapTemplates` export from the `@searchspring/snap-preact` package to build a storefront integration. It is an abstraction of the `Snap` integration that limits the available configuration and does not provide access to the entire project markup. +A "Snap Templates Integration" is a project that uses the `SnapTemplates` export from the `@athoscommerce/snap-preact` package to build a storefront integration. It is an abstraction of the `Snap` integration that limits the available configuration and does not provide access to the entire project markup. -Instead, it is based on choosing an optimimzed and prebuilt template and theme while only customizing slight layout changes, theme variables, result card markup, and general style declarations. This integration type allows for a rapid integration of Searchspring to your storefront. +Instead, it is based on choosing an optimimzed and prebuilt template and theme while only customizing slight layout changes, theme variables, result card markup, and general style declarations. This integration type allows for a rapid integration of Athos to your storefront. Continue by referencing the [Snap Templates Integration](https://searchspring.github.io/snap/templates-about) documentation. ### API Integration -An "API Integration" is a project that utilizes the Searchspring APIs directly to integrate into your custom storefront project. Although not required, we recommend using just the `@searchspring/snap-client` package to fetch data from Searchspring APIs. +An "API Integration" is a project that utilizes the Athos APIs directly to integrate into your custom storefront project. Although not required, we recommend using just the `@athoscommerce/snap-client` package to fetch data from Athos APIs. Continue by referencing the [API Integration](https://searchspring.github.io/snap/snap-client) section. @@ -41,4 +41,4 @@ Snap is open source! The repository can be found on [Github](https://github.com/ We invite your participation through Github issues, discussions and pull requests! -Please reference Searchspring's [Community Contribution Guidelines](https://github.com/searchspring/community/blob/main/CONTRIBUTING.md) before contributing. +Please reference Athos's [Community Contribution Guidelines](https://github.com/searchspring/community/blob/main/CONTRIBUTING.md) before contributing. diff --git a/docs/ACCESSIBILITY_STATEMENT.md b/docs/ACCESSIBILITY_STATEMENT.md index d0e5e82ac9..af931c486e 100644 --- a/docs/ACCESSIBILITY_STATEMENT.md +++ b/docs/ACCESSIBILITY_STATEMENT.md @@ -1,8 +1,8 @@ -![Logo of Searchspring, a division of Athos Commerce](https://raw.githubusercontent.com/searchspring/snap/main/images/division-of-athos.png) +![Logo of Athos](https://raw.githubusercontent.com/searchspring/snap/main/images/division-of-athos.png) # Accessibility Statement -Searchspring, a division of Athos Commerce, is committed to providing accessible digital experiences for people with disabilities. We are actively working to identify and remove barriers to access in accordance with recognized accessibility standards and our internal [Accessibility Policy](https://athoscommerce.com/wp-content/uploads/2025/06/Athos-Commerce-Accessibility-Policy.pdf). +Athos is committed to providing accessible digital experiences for people with disabilities. We are actively working to identify and remove barriers to access in accordance with recognized accessibility standards and our internal [Accessibility Policy](https://athoscommerce.com/wp-content/uploads/2025/06/Athos-Commerce-Accessibility-Policy.pdf). ## Compliance Status diff --git a/docs/BUILD_DEPLOY.md b/docs/BUILD_DEPLOY.md index 099d97bb70..b69120b99c 100644 --- a/docs/BUILD_DEPLOY.md +++ b/docs/BUILD_DEPLOY.md @@ -25,25 +25,25 @@ To host your own build files follow the below steps in your project. -## Deploy to Searchspring CDN +## Deploy to Athos CDN -**Deploying to Searchspring CDN is only possible if the repository is managed by the Searchspring [Github organization](https://github.com/searchspring-implementations)**. Repositories in this organization are typically managed by the Searchspring professional services team and deployed via a CI/CD pipeline using the [snap-action](https://github.com/searchspring/snap-action) Github Action. An invitation can be requested for collaboration. +**Deploying to Athos CDN is only possible if the repository is managed by the Athos [Github organization](https://github.com/searchspring-implementations)**. Repositories in this organization are typically managed by the Athos professional services team and deployed via a CI/CD pipeline using the [snap-action](https://github.com/searchspring/snap-action) Github Action. An invitation can be requested for collaboration. Github action runs triggered on the default branch `production` will build and deploy bundle files to this URL: -`https://snapui.searchspring.io/[your_site_id]/bundle.js` +`https://snapui.athoscommerce.io/[your_site_id]/bundle.js` Builds on different branch names will be deployed to: -`https://snapui.searchspring.io/[your_site_id]/[branch]/bundle.js` +`https://snapui.athoscommerce.io/[your_site_id]/[branch]/bundle.js` ### Github Repository Requirements -- Repository must be managed by the Searchspring [Github organization](https://github.com/searchspring-implementations) +- Repository must be managed by the Athos [Github organization](https://github.com/searchspring-implementations) - Repository must have a default branch named `production` - Repository must have repository secrets for each siteId in the repository. Found at `https://github.com/[owner]/[repository]/settings/secrets/actions` - - Secret Key Name: `WEBSITE_SECRET_KEY_[SITEID]` where `[SITEID]` should be replaced with the 6 character alphanumeric siteId found in the [Searchspring Management Console](https://manage.searchspring.net). For example: `WEBSITE_SECRET_KEY_ABC123` - - Value: `secretKey` located adjacent to the siteId in the [Searchspring Management Console](https://manage.searchspring.net) + - Secret Key Name: `WEBSITE_SECRET_KEY_[SITEID]` where `[SITEID]` should be replaced with the 6 character alphanumeric siteId found in the [Athos Search & Product Discovery Console](https://console.athoscommerce.net). For example: `WEBSITE_SECRET_KEY_ABC123` + - Value: `secretKey` located adjacent to the siteId in the [Athos Search & Product Discovery Console](https://console.athoscommerce.net) - Repository must have a `snap-action` workflow file in the `.github/workflows` directory. See section below. - Repository must have a `package.json` file that contains all siteIds associated with this project. See section below. @@ -65,7 +65,7 @@ jobs: uses: actions/checkout@v2 with: repository: searchspring/snap-action - - name: Run @searchspring/snap-action + - name: Run @athoscommerce/snap-action uses: ./ ``` @@ -110,19 +110,19 @@ Multi siteId example: ### Branch Overrides -This functionality is only currently possible with Searchspring managed Snap repositories (https://github.com/searchspring-implementations). +This functionality is only currently possible with Athos managed Snap repositories (https://github.com/searchspring-implementations). -While browsing a page that contains a Snap integration, appending the `?searchspring-preview=[branchname]` query parameter to the URL will stop the execution of the existing script, and load the build from the `[branchname]` branch `https://snapui.searchspring.io/[siteid]/[branchname]/bundle.js` +While browsing a page that contains a Snap integration, appending the `?athos-preview=[branchname]` query parameter to the URL will stop the execution of the existing script, and load the build from the `[branchname]` branch `https://snapui.athoscommerce.io/[siteid]/[branchname]/bundle.js` You will see an interface overlay on the bottom right of the viewport indicating if successful and details of the build. -This will also be persisted across page navigation. To stop previewing a branch build, you must click the `Stop Preview` button in the interface or clear the `ssBranch` cookie. The interface can also be minimized. +This will also be persisted across page navigation. To stop previewing a branch build, you must click the `Stop Preview` button in the interface or clear the `athosBranch` cookie. The interface can also be minimized. ## Modern vs Universal Builds -If your project is hosted in Searchspring's Github organization, we'll automatically handle serving the appropriate version of the build files for you. However if you are hosting your own build files, you can either: +If your project is hosted in Athos' Github organization, we'll automatically handle serving the appropriate version of the build files for you. However if you are hosting your own build files, you can either: - only serve the modern build to all users, however this will break functionallity for IE11. - change the build targets, although this may impact core web vitals negatively. @@ -132,20 +132,20 @@ Always serve the build to modern browsers and the universal build only to legacy ```html - + - + ``` The modern build is used for projects targeting the latest browsers supporting the latest JavaScript features (ES6 and above). Example modern build files: `bundle.js` & `bundle.chunk.[hash].js` -A browser is considered modern based on the [@searchspring/browserslist-config-snap modern](https://github.com/searchspring/browserslist-config-snap/blob/main/modern/index.js) rules and is included in the preconfigured scaffold. +A browser is considered modern based on the [@athoscommerce/browserslist-config-snap modern](https://github.com/searchspring/browserslist-config-snap/blob/main/modern/index.js) rules and is included in the preconfigured scaffold. The universal build is used for projects targeting legacy browsers and will transpile any usage of modern JavaScript to ES5 as well as polyfill any missing browser features. If you are not targeting legacy browsers, you can omit deploying the universal built files that are prefixed with `universal.` - Example: `universal.bundle.js` and `universal.bundle.chunk.[hash].js` -A browser is considered legacy based on the [@searchspring/browserslist-config-snap universal](https://github.com/searchspring/browserslist-config-snap/blob/main/universal/index.js) rules and is included in the preconfigured scaffold. +A browser is considered legacy based on the [@athoscommerce/browserslist-config-snap universal](https://github.com/searchspring/browserslist-config-snap/blob/main/universal/index.js) rules and is included in the preconfigured scaffold. However, if you are targeting legacy browsers, it is not recommended to always serve the universal build files to all browsers—including modern browsers—as this will impact Core Web Vitals and performance negatively. @@ -168,7 +168,7 @@ module.exports = /((CPU[ +]OS|iPhone[ +]OS|CPU[ +]iPhone|CPU IPhone OS)[ +]+(14| Webpack is the default choice of build tooling that all Snapfu templates include and will be preconfigured. -If you are integrating `@searchspring/snap-preact` using other build tools, you may require certain plugins to ensure preact compatibility. +If you are integrating `@athoscommerce/snap-preact` using other build tools, you may require certain plugins to ensure preact compatibility. We hope to maintain this page with the most common build tools and their respective plugins as we discover them. diff --git a/docs/BUILD_DEPLOY_INTEGRATION.md b/docs/BUILD_DEPLOY_INTEGRATION.md index 2aadc0a09b..dc24f97ab0 100644 --- a/docs/BUILD_DEPLOY_INTEGRATION.md +++ b/docs/BUILD_DEPLOY_INTEGRATION.md @@ -4,7 +4,7 @@ After building the project and uploading the build files to your CDN or hosting ```html - ``` @@ -21,12 +21,12 @@ The bundle should be included in the tag, ideally near the top of the nod Snap Integration Example - -
+
``` @@ -44,7 +44,7 @@ There are a few core context variables utilized by Snap, `shopper`, `merchandisi | shopper.id | logged in user unique identifier | all | required for personalization functionality | | shopper.cart | array of cart objects, each object in the array can contain `uid` (required), `childUid`, `sku`, `childSku`, `price`, `qty` | all | current cart contents, required if checkout process does not contain a dedicated cart page (ie. slideout cart) | | currency.code | currency code string, ie. 'EUR' (ISO 4217) | all | currency code of the shopper's cart contents or order confirmation. Used for beacon events containing pricing data | -| merchandising.segments | array of strings used for merchandising | any | segmented merchandising allows for custom control over products returned on search requests and must also be setup within the Searchspring Management Console (SMC) | +| merchandising.segments | array of strings used for merchandising | any | segmented merchandising allows for custom control over products returned on search requests and must also be setup within the Athos Search & Product Discovery Console (ASD) | | config | object containing Snap configurations | any | advanced usage of Snap (not recommended for standard integrations) | | page.type | 'search' (default) or 'category' | PLP | explicitly indicate the page type (category or search). This is used to differentiate category and search beacon events. If not provided, the page type will be inferred as 'category' if a common category background filter is present. | @@ -53,7 +53,7 @@ There are a few core context variables utilized by Snap, `shopper`, `merchandisi The custom variable example below shows a custom context being added for 'page'. The value would typically be assigned server side using template logic. This would be used to possibly toggle the siteId utilized by the client (to fetch different catalog data) or to modify text or currency displays. ```html - ``` @@ -61,7 +61,7 @@ The custom variable example below shows a custom context being added for 'page'. When used, shopper context should always include at least an `id`; the `cart` contents can optionally be provided to ensure personalization is applied on every page. Standard Snap integrations will automatically take this context data and apply it for personalization. ```html - -{{!-- END: Searchspring Integration code --}} +{{!-- END: Athos Integration code --}} ``` #### Search, Category, and Brand @@ -106,39 +106,39 @@ Next we'll integrate Searchspring into the theme. - Replace the `>` character in the breadcrumb trail if the data is using a different delimiter. ```handlebars -{{!-- START: Searchspring Integration code --}} +{{!-- START: Athos Integration code --}} {{!-- define initial variables --}} -{{assignVar 'ss_site_id' 'REPLACE_WITH_YOUR_SITE_ID'}} -{{assignVar 'ss_search_url' '/shop/'}} -{{assignVar 'ss_page_type' 'other'}} -{{assignVar 'ss_is_loaded' 'false'}} +{{assignVar 'athos_site_id' 'REPLACE_WITH_YOUR_SITE_ID'}} +{{assignVar 'athos_search_url' '/shop/'}} +{{assignVar 'athos_page_type' 'other'}} +{{assignVar 'athos_is_loaded' 'false'}} {{!-- check if results should load --}} {{#or category brand}} - {{assignVar 'ss_is_loaded' 'true'}} + {{assignVar 'athos_is_loaded' 'true'}} {{/or}} {{!-- check if on search page --}} {{#if category}} - {{#contains category.url (getVar 'ss_search_url')}}{{assignVar 'ss_page_type' 'search'}}{{else}}{{assignVar 'ss_page_type' 'category'}}{{/contains}} + {{#contains category.url (getVar 'athos_search_url')}}{{assignVar 'athos_page_type' 'search'}}{{else}}{{assignVar 'athos_page_type' 'category'}}{{/contains}} {{else if brand}} - {{assignVar 'ss_page_type' 'brand'}} + {{assignVar 'athos_page_type' 'brand'}} {{/if}} {{!-- create integration script --}} - -{{!-- END: Searchspring Integration code --}} +{{!-- END: Athos Integration code --}} ``` ### Body Class Name @@ -148,18 +148,18 @@ Next we'll integrate Searchspring into the theme. If `body` tag has no `class` attribute: ```handlebars - + ``` If `body` tag has a `class` attribute, ensure to keep the existing class names and append the `ss-shop` class name to the existing list of class names: ```handlebars - + ``` ## Category and Brand Page Edits -Next we'll add our target element(s) to the category and brand pages. This is where the Searchspring elements will be injected into, typically two elements are added for a two-column layout: one for content, and one for facets. +Next we'll add our target element(s) to the category and brand pages. This is where the Athos elements will be injected into, typically two elements are added for a two-column layout: one for content, and one for facets. Targets are defined in your Snap configuration and will only be injected into if they exist on the page. @@ -167,15 +167,15 @@ Targets are defined in your Snap configuration and will only be injected into if - Storefront > My Themes > [theme name] > "..." icon > Edit Theme Files > templates > pages > category.html. - `category.html` is a standard BigCommerce template, but this may not be the file to edit. Look for includes which will tell you where to go, for example: `{{> thing/parent/child}}`. This says that there's additional code for the category page located in another file that has the name "child". -- Once the correct file is found, ensure that all of your search controller targets are added to the category template. Use theme comments to hide the store's default product grid, thus speeding up load time for Searchspring. +- Once the correct file is found, ensure that all of your search controller targets are added to the category template. Use theme comments to hide the store's default product grid, thus speeding up load time for Athos. ```handlebars -
+
{{!-- --}} -
+
{{!-- --}} @@ -199,15 +199,15 @@ Show an element only when on the `shop` category: - Storefront > My Themes > [theme name] > "..." icon > Edit Theme Files > templates > pages > brand.html. - Make sure you are within `brand.html` as `brands.html` file contains the listing of all brands. - `brand.html` is a standard BigCommerce template, but this may not be the file to edit. Look for includes which will tell you where to go, for example: `{{> thing/parent/child}}`. This says that there's additional code for the brand page located in another file that has the name "child". -- Once the correct file is found, ensure that all of your search controller targets are added to the brand template. Use theme comments to hide the store's default product grid, thus speeding up load time for Searchspring. +- Once the correct file is found, ensure that all of your search controller targets are added to the brand template. Use theme comments to hide the store's default product grid, thus speeding up load time for Athos. ```handlebars -
+
{{!-- --}} -
+
{{!-- --}} @@ -245,7 +245,7 @@ In your form copy, update the following details: ## Integration Code -Up until this point, we've added the Searchspring integration to the theme and category/brand pages. +Up until this point, we've added the Athos integration to the theme and category/brand pages. Now we'll ensure our integration code captures the context variables and sets up the necessary configuration. @@ -255,9 +255,9 @@ For tracking shopper data used in personalization features, we need to include c ```js // src/index.js -/* searchspring imports */ -import { Snap } from '@searchspring/snap-preact'; -import { getContext } from '@searchspring/snap-toolbox'; +/* athos imports */ +import { Snap } from '@athoscommerce/snap-preact'; +import { getContext } from '@athoscommerce/snap-toolbox'; /* context from script tag */ const context = getContext(['shopper', 'siteId']); @@ -414,7 +414,7 @@ const snap = new Snap({ }, targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', component: async () => { return (await import('./components/Content/Content')).Content; }, @@ -431,27 +431,27 @@ const snap = new Snap({ ## Additional Targets (Optional) -In addition to having two targets for a two-column layout, you may want to inject content into other sections of the page such above the content and sidebar to display information such as the search query. Note the addition of `ss-shop` class before `searchspring-header` to ensure the content is only injected on the search page. +In addition to having two targets for a two-column layout, you may want to inject content into other sections of the page such above the content and sidebar to display information such as the search query. Note the addition of `ss-shop` class before `athos-header` to ensure the content is only injected on the search page. ```js // src/index.js targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', component: async () => { return (await import('./content/content/Content')).Content; }, hideTarget: true, }, { - selector: '#searchspring-sidebar', + selector: '#athos-sidebar', component: async () => { return (await import('./sidebar/sidebar/Sidebar')).Sidebar; }, hideTarget: true, }, { - selector: '.ss-shop #searchspring-header', + selector: '.ss-shop #athos-header', component: async () => { return (await import('./content/header/Header')).Header; }, diff --git a/docs/BUILD_DEPLOY_INTEGRATION_MAGENTO2.md b/docs/BUILD_DEPLOY_INTEGRATION_MAGENTO2.md index 19a7570d1a..df8efde403 100644 --- a/docs/BUILD_DEPLOY_INTEGRATION_MAGENTO2.md +++ b/docs/BUILD_DEPLOY_INTEGRATION_MAGENTO2.md @@ -1,10 +1,10 @@ # Magento2 Integration -## Searchspring Management Console Actions +## Athos Search & Product Discovery Console Actions ### Update Field Settings -On the [Field Settings page](https://manage.searchspring.net/management/field-settings/display-fields), make sure the following fields are updated: +On the [Field Settings page](https://console.athoscommerce.net/data-configurations/field-settings), make sure the following fields are updated: **For Search Only Integration:** @@ -19,7 +19,7 @@ On the [Field Settings page](https://manage.searchspring.net/management/field-se | visibility | Text | , | ✓ | | category_hierarchy | Text | \| | ✓ | -If settings are changed, perform an [Update Index](https://manage.searchspring.net/management/index/status). +If settings are changed, perform an [Update Index](https://console.athoscommerce.net/data-sync). ## Add IntelliSuggest Tracking @@ -53,7 +53,7 @@ Notify the client which site id to use for the section "How to Install", step 4, ## Theme Integration -Next we'll integrate Searchspring into the theme. +Next we'll integrate Athos into the theme. > [!NOTE] > If possible, have the site owner enable Template Path Hints. This will make it easier to find which files need to be changed. @@ -77,24 +77,24 @@ Next we'll integrate Searchspring into the theme. ```php get('Magento\Framework\Registry')->registry('current_category'); + $athos_object_manager = \Magento\Framework\App\ObjectManager::getInstance(); + $athos_category = $athos_object_manager->get('Magento\Framework\Registry')->registry('current_category'); // Update defer if on search category - if (isset($ss_category) && $ss_category->getId() == 000000) { - $ss_defer_config = ''; + if (isset($athos_category) && $athos_category->getId() == 000000) { + $athos_defer_config = ''; } ?> - - + + ``` @@ -102,52 +102,52 @@ Next we'll integrate Searchspring into the theme. - Replace `REPLACE_WITH_YOUR_SITE_ID` with the correct site id. - Replace `000000` with the search category id that was noted when creating the category page. -- (Optional) If the category path attribute has a parent level you want to exclude, add to the `$ss_category_exclude` array. +- (Optional) If the category path attribute has a parent level you want to exclude, add to the `$athos_category_exclude` array. ```php get('Magento\Framework\Registry')->registry('current_category'); + $athos_object_manager = \Magento\Framework\App\ObjectManager::getInstance(); + $athos_category = $athos_object_manager->get('Magento\Framework\Registry')->registry('current_category'); // Update details if on category - if (isset($ss_category)) { - $ss_category_id = $ss_category->getId(); - $ss_category_name = str_replace($ss_find, $ss_replace, $ss_category->getName()); - $ss_category_copy = $ss_category; - $ss_category_array = array(); - $ss_category_exclude = array('Default Category', 'Root Catalog'); + if (isset($athos_category)) { + $athos_category_id = $athos_category->getId(); + $athos_category_name = str_replace($athos_find, $athos_replace, $athos_category->getName()); + $athos_category_copy = $athos_category; + $athos_category_array = array(); + $athos_category_exclude = array('Default Category', 'Root Catalog'); // Build category path and trim characters - while (!in_array($ss_category_copy->getName(), $ss_category_exclude)) { - $ss_category_array[] = trim(htmlspecialchars($ss_category_copy->getName())); - $ss_category_copy = $ss_category_copy->getParentCategory(); + while (!in_array($athos_category_copy->getName(), $athos_category_exclude)) { + $athos_category_array[] = trim(htmlspecialchars($athos_category_copy->getName())); + $athos_category_copy = $athos_category_copy->getParentCategory(); } - $ss_category_join = implode('>', array_reverse($ss_category_array)); - $ss_category_path = str_replace($ss_find, $ss_replace, $ss_category_join); + $athos_category_join = implode('>', array_reverse($athos_category_array)); + $athos_category_path = str_replace($athos_find, $athos_replace, $athos_category_join); // Update defer if on category - $ss_defer_config = ''; + $athos_defer_config = ''; // Add category filter (but not on search category) - if ($ss_category_id != 000000) { - $ss_category_config = 'category = { id : "' . $ss_category_id . '", name : "' . $ss_category_name . '", path : "' . $ss_category_path . '" };'; + if ($athos_category_id != 000000) { + $athos_category_config = 'category = { id : "' . $athos_category_id . '", name : "' . $athos_category_name . '", path : "' . $athos_category_path . '" };'; } } ?> - - ``` @@ -158,7 +158,7 @@ Magento automatically adds a class based on the name of the page to the body, so ## Category Page Edits -Next we'll add our target element(s) to the category page. This is where the Searchspring elements will be injected into, typically two elements are added for a two-column layout: one for content, and one for facets. +Next we'll add our target element(s) to the category page. This is where the Athos elements will be injected into, typically two elements are added for a two-column layout: one for content, and one for facets. Targets are defined in your Snap configuration and will only be injected into if they exist on the page. @@ -173,7 +173,7 @@ Targets are defined in your Snap configuration and will only be injected into if - Some category templates will only display sidebar or results content if products are assigned to the category. Look for conditions that may be checking for product count and adjust as needed (likely altering the product count conditional). ```php -
+
``` ### Category Sidebar @@ -186,7 +186,7 @@ Targets are defined in your Snap configuration and will only be injected into if - Once the correct file is found, ensure that all of your search controller targets are added to the category sidebar. ```php -
+
``` ## Search Form Updates @@ -198,16 +198,16 @@ Next we'll update the search form to submit to the search results category page > [!CAUTION] > If this file doesn't exist, find the root file of the same, make a copy, and upload it to the path above. Try looking in: vendor > magento > magento-search > view > frontend > templates > form.mini.phtml. Do not edit the root files directly because if the client updates Magento, this could erase the changes and break the integration. -- Above the form, add a php flag to enable and disable Searchspring: +- Above the form, add a php flag to enable and disable Athos: ```php - + ``` -- Create a copy of the form which you will edit and comment out the old form. This will allow us to retain Magento's default functionality for when Searchspring is disabled. +- Create a copy of the form which you will edit and comment out the old form. This will allow us to retain Magento's default functionality for when Athos is disabled. ```php - + @@ -226,7 +226,7 @@ In your form copy, update the following details: ## Integration Code -Up until this point, we've added the Searchspring integration to the theme and category page. +Up until this point, we've added the Athos integration to the theme and category page. Now we'll ensure our integration code captures the context variables and sets up the necessary configuration. @@ -236,7 +236,7 @@ In the `src/scripts` folder, create a plugin called `magento2.js` and add the be ```js // src/scripts/magento2.js -import { cookies } from '@searchspring/snap-toolbox'; +import { cookies } from '@athoscommerce/snap-toolbox'; export const magento2 = (controller) => { // get shopper id from magento cache @@ -343,7 +343,7 @@ const snap = new Snap({ }, targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', component: async () => { return (await import('./components/Content')).Content; }, @@ -383,7 +383,7 @@ Back in `src/index.js`, adjust context to grab additional values for category in ```js // src/index.js /* context from script tag */ -import { getContext } from '@searchspring/snap-toolbox'; +import { getContext } from '@athoscommerce/snap-toolbox'; const context = getContext(['category']); ``` @@ -454,7 +454,7 @@ const snap = new Snap({ }, targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', component: async () => { return (await import('./components/Content')).Content; }, @@ -490,27 +490,27 @@ const snap = new Snap({ ## Additional Targets (Optional) -In addition to having two targets for a two-column layout, you may want to inject content into other sections of the page such above the content and sidebar to display information such as the search query. Note the addition of `category-shop` class before `searchspring-header` to ensure the content is only injected on the search page. +In addition to having two targets for a two-column layout, you may want to inject content into other sections of the page such above the content and sidebar to display information such as the search query. Note the addition of `category-shop` class before `athos-header` to ensure the content is only injected on the search page. ```js // src/index.js targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', component: async () => { return (await import('./components/Content')).Content; }, hideTarget: true, }, { - selector: '#searchspring-sidebar', + selector: '#athos-sidebar', component: async () => { return (await import('./components/Sidebar')).Sidebar; }, hideTarget: true, }, { - selector: '.category-shop #searchspring-header', + selector: '.category-shop #athos-header', component: async () => { return (await import('./content/header/Header')).Header; }, diff --git a/docs/BUILD_DEPLOY_INTEGRATION_SHOPIFY.md b/docs/BUILD_DEPLOY_INTEGRATION_SHOPIFY.md index 66635cac0a..dc017c23b6 100644 --- a/docs/BUILD_DEPLOY_INTEGRATION_SHOPIFY.md +++ b/docs/BUILD_DEPLOY_INTEGRATION_SHOPIFY.md @@ -1,17 +1,17 @@ # Shopify Integration -## Searchspring Management Console Actions +## Athos Search & Product Discovery Console Actions -Log into the Searchspring Management Console (SMC) and perform the following actions: +Log into the Athos Search & Product Discovery Console (ASD) and perform the following actions: ### Add IntelliSuggest Tracking -Shopify sites now add IntelliSuggest tracking through "Web Pixel Tracking". In the SMC, check the [Data Feed page](https://manage.searchspring.net/management/data-feed) and ensure this feature is enabled. If it's not, speak with the Solutions team member who setup the account. +Shopify sites now add IntelliSuggest tracking through "Web Pixel Tracking". In the ASD, check the [Data Feed page](https://console.athoscommerce.net/data-connectors/data-sources) and ensure this feature is enabled. If it's not, speak with the Solutions team member who setup the account. ### Update Field Settings -On the [Field Settings page](https://manage.searchspring.net/management/field-settings/display-fields), make sure the following fields are updated: +On the [Field Settings page](https://console.athoscommerce.net/data-configurations/field-settings), make sure the following fields are updated: | Field | Type | Multi-Valued | Display | Display In Recs | |---|---|:---:|:---:|:---:| @@ -21,11 +21,11 @@ On the [Field Settings page](https://manage.searchspring.net/management/field-se | vendor | Text | No | ✓ | | | product_type | Text | No | ✓ | | -If settings are changed, perform an [Update Index](https://manage.searchspring.net/management/index/status). +If settings are changed, perform an [Update Index](https://console.athoscommerce.net/data-sync). ### "All" Collection Page (Optional) -Most if not all Shopify sites have an "All" collection page located at `[domain]/collections/all`. Typically, products are automatically assigned to this collection and then fed back into our data feed. There have been occasions where this is not true and we don't have the `collection_handle` > `all` assignment in our data feed. If this happens, please inquire with Searchspring support to have this added. +Most if not all Shopify sites have an "All" collection page located at `[domain]/collections/all`. Typically, products are automatically assigned to this collection and then fed back into our data feed. There have been occasions where this is not true and we don't have the `collection_handle` > `all` assignment in our data feed. If this happens, please inquire with Athos support to have this added. ## Create a Collection Search Page @@ -50,7 +50,7 @@ To add a search results page, we'll need to create a new collection in Shopify. ## Theme Integration -Next we'll integrate Searchspring into the theme. +Next we'll integrate Athos into the theme. - Create a copy of the current theme to integrate on. It is recommended to do so rather than integrating directly on the live theme initially to allow for testing prior to going live. - Online Store > Themes > Live theme > ... > Duplicate @@ -58,44 +58,44 @@ Next we'll integrate Searchspring into the theme. ### Theme Settings -Next, we'll add the Searchspring theme settings. Theme settings are defined to provide an interface for defining variables that are used in liquid code. See [Shopify Setting Types](https://shopify.dev/themes/architecture/settings#setting-types) for more information. These theme settings are then accessed by going to Online Store > Themes > [theme name] > Customize button. Click on "Theme settings" in the lower left navigation and on the right side, there should be a "Searchspring" section. +Next, we'll add the Athos theme settings. Theme settings are defined to provide an interface for defining variables that are used in liquid code. See [Shopify Setting Types](https://shopify.dev/themes/architecture/settings#setting-types) for more information. These theme settings are then accessed by going to Online Store > Themes > [theme name] > Customize button. Click on "Theme settings" in the lower left navigation and on the right side, there should be a "Athos" section. - Online Store > Themes > [theme name] > ... > Edit code > Config > `settings_schema.json`. - At the end of the file, find a closing square bracket `]` on the last line. -- Before this closing bracket, add code for Searchspring theme settings. The opening comma is needed if there is another configuration before your code paste. +- Before this closing bracket, add code for Athos theme settings. The opening comma is needed if there is another configuration before your code paste. ```json { - "name": "Searchspring", + "name": "Athos Commerce", "settings": [ { "type": "checkbox", - "id": "ss_enable", - "label": "Enable Searchspring", + "id": "athos_enable", + "label": "Enable Athos", "default": true }, { "type": "text", - "id": "ss_site_id", + "id": "athos_site_id", "label": "Site ID", "default": "REPLACE_WITH_YOUR_SITE_ID" }, { "type": "text", - "id": "ss_collection_handle", + "id": "athos_collection_handle", "label": "Search collection handle", "default": "shop" }, { "type": "text", - "id": "ss_branch_name", + "id": "athos_branch_name", "label": "Branch Name" } ] } ``` -- Replace `REPLACE_WITH_YOUR_SITE_ID` on line 15 with the correct siteId found in the Searchspring Management Console. +- Replace `REPLACE_WITH_YOUR_SITE_ID` on line 15 with the correct siteId found in the Athos Search & Product Discovery Console. - (if applicable) Replace `shop` on line 21 with the search collection handle if it was not `shop`. @@ -103,9 +103,9 @@ Next, we'll add the Searchspring theme settings. Theme settings are defined to p Liquid template snippets are used to store code that is used in multiple templates. -Create a new snippet which will be used to store the Searchspring integration script code. +Create a new snippet which will be used to store the Athos integration script code. -- Online Store > Themes > [theme name] > ... > Edit code > Snippets > Add a new snippet > `ss-script`. +- Online Store > Themes > [theme name] > ... > Edit code > Snippets > Add a new snippet > `athos-script`. ### Search Only @@ -113,93 +113,93 @@ Create a new snippet which will be used to store the Searchspring integration sc > If you are only integrating Search page functionality, you can use the following snippet. Otherwise skip this section and continue below to install both search and collections functionality. ```liquid -{%- if settings.ss_branch_name != blank -%} - {% capture ss_branch_name %}/{{ settings.ss_branch_name }}{% endcapture %} +{%- if settings.athos_branch_name != blank -%} + {% capture athos_branch_name %}/{{ settings.athos_branch_name }}{% endcapture %} {%- endif -%} {%- if customer -%} - {% capture ss_shopper_config %} + {% capture athos_shopper_config %} shopper = { id: "{{ customer.id }}" }; {% endcapture %} {%- endif -%} -{% assign ss_defer_config = ' defer' %} -{%- if collection.handle and template contains 'collection' and collection.handle == settings.ss_collection_handle -%} - {% assign ss_defer_config = '' %} +{% assign atho_defer_config = ' defer' %} +{%- if collection.handle and template contains 'collection' and collection.handle == settings.athos_collection_handle -%} + {% assign atho_defer_config = '' %} {%- endif -%} {%- if template -%} - {% capture ss_template_config %} + {% capture athos_template_config %} template = "{{ template }}"; {% endcapture -%} {%- endif -%} -{% capture ss_money_config %} +{% capture athos_money_config %} format = "{{ shop.money_format }}"; {% endcapture %} -{% comment %}Searchspring Script{% endcomment %} - ``` ### Search and Collections ```liquid -{%- if settings.ss_branch_name != blank -%} - {% capture ss_branch_name %}/{{ settings.ss_branch_name }}{% endcapture %} +{%- if settings.athos_branch_name != blank -%} + {% capture athos_branch_name %}/{{ settings.athos_branch_name }}{% endcapture %} {%- endif -%} {%- if customer -%} - {% capture ss_shopper_config %} + {% capture athos_shopper_config %} shopper = { id: "{{ customer.id }}" }; {% endcapture %} {%- endif -%} -{% assign ss_defer_config = ' defer' %} +{% assign atho_defer_config = ' defer' %} {%- if collection.handle and template contains 'collection' -%} - {% assign ss_defer_config = '' %} - {%- if collection.handle != settings.ss_collection_handle -%} - {% capture ss_collection_config %} + {% assign atho_defer_config = '' %} + {%- if collection.handle != settings.athos_collection_handle -%} + {% capture athos_collection_config %} collection = { id: "{{ collection.id }}", name: "{{ collection.title | replace: '"', '"' }}", handle: "{{ collection.handle }}" }; {% endcapture %} {%- endif -%} {%- endif -%} {%- if current_tags -%} - {% capture ss_tags_config %} + {% capture athos_tags_config %} tags = {{ current_tags | json }}; {% endcapture %} {%- endif -%} {%- if template -%} - {% capture ss_template_config %} + {% capture athos_template_config %} template = "{{ template }}"; {% endcapture -%} {%- endif -%} -{% capture ss_money_config %} +{% capture athos_money_config %} format = "{{ shop.money_format }}"; {% endcapture %} -{% comment %}Searchspring Script{% endcomment %} - ``` ### Snippet Installation -Next, we'll integrate the `ss-script` snippet into the theme. We'll have to add the snippet to the theme.liquid file such that it is included on every page. +Next, we'll integrate the `athos-script` snippet into the theme. We'll have to add the snippet to the theme.liquid file such that it is included on every page. It is recommended to install the snippet in the `head` tag so that the script is loaded as soon as possible. - Online Store > Themes > [theme name] > ... > Edit code > Layout > `theme.liquid`. - Before the closing `` tag, add the following code: ```liquid -{% if settings.ss_enable %} - {% render 'ss-script' %} +{% if settings.athos_enable %} + {% render 'athos-script' %} {% endif %} ``` @@ -210,34 +210,34 @@ It is recommended to install the snippet in the `head` tag so that the script is If `body` tag has no `class` attribute: ```liquid - + ``` If `body` tag has a `class` attribute, ensure to keep the existing class names and append the `ss-shop` class name to the existing list of class names: ```liquid - + ``` ## Collection Page Edits -Next we'll add our target element(s) to the collection page. This is where the Searchspring elements will be injected into, typically two elements are added for a two-column layout: one for content, and one for facets. +Next we'll add our target element(s) to the collection page. This is where the Athos elements will be injected into, typically two elements are added for a two-column layout: one for content, and one for facets. Targets are defined in your Snap configuration and will only be injected into if they exist on the page. - Online Store > Themes > [theme name] > ... > Edit code > Templates > `collection.liquid`. - `collection.liquid` is a standard Shopify template, but this may not be the file to edit depending on your theme. Look for includes which will tell you where to go, for example: `{% section 'collection-main' %}`. This says that there's additional code for the collection page located in the section file that has the name "collection-main". -- Once the correct file is found, ensure that all of your search controller targets are added to the collection template. By using the `ss_enable` condition, we can retain Shopify's default functionality for when Searchspring is disabled via the theme settings. +- Once the correct file is found, ensure that all of your search controller targets are added to the collection template. By using the `athos_enable` condition, we can retain Shopify's default functionality for when Athos is disabled via the theme settings. ```liquid -{% if settings.ss_enable %} -
+{% if settings.athos_enable %} +
{% else %} {% endif %} -{% if settings.ss_enable %} -
+{% if settings.athos_enable %} +
{% else %} {% endif %} @@ -249,12 +249,12 @@ Next we'll update the search form to submit to the search results collection pag - Online Store > Themes > [theme name] > ... > Edit code > Layout > `theme.liquid`. - Check for the search form. It may not be in this file, but check for its approximate location and then look in includes such as snippets or sections for its actual location. Other possible file names might be `form-search.liquid`, `header.liquid`, etc. -- Create a copy of the form which you will edit and comment out the old form. This will allow us to retain Shopify's default functionality for when Searchspring is disabled via the theme settings. +- Create a copy of the form which you will edit and comment out the old form. This will allow us to retain Shopify's default functionality for when Athos is disabled via the theme settings. ```liquid -{% if settings.ss_enable %} -
- +{% if settings.athos_enable %} + +
{% else %} @@ -266,13 +266,13 @@ In your form copy, update the following details: | Element | Attribute | Value | |---|---|---| | form | method | get | -| form | action | `{{ routes.collections_url }}/{{ settings.ss_collection_handle }}` | +| form | action | `{{ routes.collections_url }}/{{ settings.athos_collection_handle }}` | | input[type="hidden"] | | remove any hidden inputs | ## Integration Code -Up until this point, we've added the Searchspring integration to the theme and collection page. +Up until this point, we've added the Athos integration to the theme and collection page. Now we'll ensure our integration code captures the context variables. @@ -372,7 +372,7 @@ const snap = new Snap({ }, targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', component: async () => { return (await import('./components/Content/Content')).Content; }, @@ -434,27 +434,27 @@ export const sharedPlugin = (controller, page) => { ## Additional Targets (Optional) -In addition to having two targets for a two-column layout, you may want to inject content into other sections of the page such above the content and sidebar to display information such as the search query. Note the addition of `ss-shop` class before `searchspring-header` to ensure the content is only injected on the search page. +In addition to having two targets for a two-column layout, you may want to inject content into other sections of the page such above the content and sidebar to display information such as the search query. Note the addition of `ss-shop` class before `athos-header` to ensure the content is only injected on the search page. ```js // src/index.js targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', component: async () => { return (await import('./content/content/Content')).Content; }, hideTarget: true, }, { - selector: '#searchspring-sidebar', + selector: '#athos-sidebar', component: async () => { return (await import('./sidebar/sidebar/Sidebar')).Sidebar; }, hideTarget: true, }, { - selector: '.ss-shop #searchspring-header', + selector: '.ss-shop #athos-header', component: async () => { return (await import('./content/header/Header')).Header; }, diff --git a/docs/BUILD_DEPLOY_PERFORMANCE_OPTIMIZATION.md b/docs/BUILD_DEPLOY_PERFORMANCE_OPTIMIZATION.md index ea4a140db4..fb892fb464 100644 --- a/docs/BUILD_DEPLOY_PERFORMANCE_OPTIMIZATION.md +++ b/docs/BUILD_DEPLOY_PERFORMANCE_OPTIMIZATION.md @@ -15,15 +15,15 @@ For other pages that only contain Recommendations, Autocomplete, or Finders (non ### Resource Hints -Use link tags with `preconnect` and `dns-prefetch` attributes to establish early connections to Snap CDN and Searchspring API domains: +Use link tags with `preconnect` and `dns-prefetch` attributes to establish early connections to Snap CDN and Athos API domains: ```html - - + + - + @@ -105,7 +105,7 @@ controller.on('beforeSearch', ({ controller, request }, next) => { By adding a `min-height` to elements that are being targeted by Snap components, you can always reserve space for Snap components to prevent layout shifts. This is especially important for elements that are above the fold. By default, the `min-height` style will automatically be removed when the component is rendered. ```html -
+
``` @@ -115,7 +115,7 @@ By adding a `min-height` to elements that are being targeted by Snap components, We recommended using server-side rendered skeletons inside the target elements for the best LCP performance. If this is the case, also set the `renderAfterSearch` property to `true`. ```html -
+
@@ -124,7 +124,7 @@ We recommended using server-side rendered skeletons inside the target elements f ``` ```jsx -import { Snap } from '@searchspring/snap-preact'; +import { Snap } from '@athos/snap-preact'; const config = { controllers: { @@ -133,7 +133,7 @@ const config = { id: 'search', }, targeters: [{ - selector: '#searchspring-content', + selector: '#athos-content', component: () => import('./Search'), renderAfterSearch: true, // Render the skeleton after search is ready }] diff --git a/docs/REFERENCE_CONFIGURATION.md b/docs/REFERENCE_CONFIGURATION.md index 26af4ec684..1e57484b6e 100644 --- a/docs/REFERENCE_CONFIGURATION.md +++ b/docs/REFERENCE_CONFIGURATION.md @@ -4,12 +4,12 @@ This configuration refers to the object passed to the `new Snap()` constructor. ## Client -Required. Config object that is passed to the core `@searchspring/snap-client` package. This service handles the network requests to Searchspring APIs to retrieve data to be displayed. +Required. Config object that is passed to the core `@athoscommerce/snap-client` package. This service handles the network requests to Athos APIs to retrieve data to be displayed. | Option | Type | Description | |---|---|---| -| client.globals | `Partial` | Base query parameters to the API; these are parameters that will ALWAYS be included on every request. At the bare minimum, `siteId` is required and can be obtained in the [Searchspring Management Console](https://manage.searchspring.net/). See [Snap client](https://github.com/searchspring/snap/tree/main/packages/snap-client) for more information. | +| client.globals | `Partial` | Base query parameters to the API; these are parameters that will ALWAYS be included on every request. At the bare minimum, `siteId` is required and can be obtained in the [Athos Search & Product Discovery Console](https://console.athoscommerce.net). See [Snap client](https://github.com/searchspring/snap/tree/main/packages/snap-client) for more information. | | client.config | `ClientConfig` | Optional. See [Snap client](https://github.com/searchspring/snap/tree/main/packages/snap-client) for more information. | @@ -30,7 +30,7 @@ Optional Context object to be used to set the global context. If no context is p ## URL -Optional. [`UrlTranslator` config](https://github.com/searchspring/snap/tree/main/packages/snap-url-manager/src/Translators/Url/README.md) object that is passed to the core `@searchspring/snap-url-manager` package used by all controllers. This parameter configuration will be applied to all controllers created via Snap, but can be specified per controller for specific customization. +Optional. [`UrlTranslator` config](https://github.com/searchspring/snap/tree/main/packages/snap-url-manager/src/Translators/Url/README.md) object that is passed to the core `@athoscommerce/snap-url-manager` package used by all controllers. This parameter configuration will be applied to all controllers created via Snap, but can be specified per controller for specific customization. | Option | Type | Description | |---|---|---| diff --git a/docs/REFERENCE_CONFIGURATION_MIDDLEWARE.md b/docs/REFERENCE_CONFIGURATION_MIDDLEWARE.md index 9f0b433732..fd258495b5 100644 --- a/docs/REFERENCE_CONFIGURATION_MIDDLEWARE.md +++ b/docs/REFERENCE_CONFIGURATION_MIDDLEWARE.md @@ -63,7 +63,7 @@ const config = { The `plugins` property is an array of arrays of functions and optional function parameters that are used to attach functionality to controllers. Parameters can optionally be passed to the functions as shown with the `paramPlugin` below: ```js -import { Snap } from '@searchspring/snap-preact'; +import { Snap } from '@athoscommerce/snap-preact'; const plugin = (controller) => { controller.on('init', async(eventData, next) => { @@ -110,7 +110,7 @@ We can attach events to our controllers after they have been created by a Snap i Let's use the `config` from above. Since our search controller has an `id` of `'search'`, we can reference it as follows: ```js -import { Snap } from '@searchspring/snap-preact'; +import { Snap } from '@athoscommerce/snap-preact'; const snap = new Snap(config); snap.getController('search').then((search) => { @@ -123,7 +123,7 @@ We can now attach middleware events in the following methods: ### controller.on ```js -import { Snap } from '@searchspring/snap-preact'; +import { Snap } from '@athoscommerce/snap-preact'; snap.getController('search').then((search) => { search.on('afterSearch', async(eventData, next) => { @@ -136,7 +136,7 @@ snap.getController('search').then((search) => { ### controller.plugin ```js -import { Snap } from '@searchspring/snap-preact'; +import { Snap } from '@athoscommerce/snap-preact'; snap.getController('search').then((search) => { search.plugin((controller) => { @@ -152,7 +152,7 @@ snap.getController('search').then((search) => { Next we will attach a plugin that takes additional parameters. This could be useful for sending contextual data into your plugin. ```js -import { Snap } from '@searchspring/snap-preact'; +import { Snap } from '@athoscommerce/snap-preact'; const paramPlugin = (controller, ...params) => { // params = [ 'param1', 'param2' ] @@ -170,15 +170,15 @@ snap.getController('search').then((search) => { ## Global Events -We can attach global events to the `window.searchspring` object via the event-manager created by the Snap instance. These events can be listened for or fired via the `on` and `fire` methods. +We can attach global events to the `window.athos` object via the event-manager created by the Snap instance. These events can be listened for or fired via the `on` and `fire` methods. Example: ```js - window.searchspring.on('myEvent', (data) => { + window.athos.on('myEvent', (data) => { console.log('myEvent happened!', data); }) - window.searchspring.fire('myEvent', data); + window.athos.fire('myEvent', data); ``` ## Provided Global Events diff --git a/docs/REFERENCE_CONFIGURATION_TARGETERS.md b/docs/REFERENCE_CONFIGURATION_TARGETERS.md index 28d8b49a06..62bd811095 100644 --- a/docs/REFERENCE_CONFIGURATION_TARGETERS.md +++ b/docs/REFERENCE_CONFIGURATION_TARGETERS.md @@ -71,8 +71,8 @@ A `skeleton` component can be defined to render inside the target until search i A [Skeleton component](https://searchspring.github.io/snap/preact-components?params=%3Fpath%3D%2Fstory%2Fatoms-skeleton--default) is available in the components package. ```jsx -import { Snap } from '@searchspring/snap-preact'; -import { Skeleton } from '@searchspring/snap-preact-components'; +import { Snap } from '@athoscommerce/snap-preact'; +import { Skeleton } from '@athoscommerce/snap-preact-components'; const ContentSkeleton = () => { return (); diff --git a/docs/REFERENCE_CUSTOM_BADGE_TEMPLATES.md b/docs/REFERENCE_CUSTOM_BADGE_TEMPLATES.md index 575f647b71..c5417e75ec 100644 --- a/docs/REFERENCE_CUSTOM_BADGE_TEMPLATES.md +++ b/docs/REFERENCE_CUSTOM_BADGE_TEMPLATES.md @@ -1,6 +1,6 @@ # Custom Badge Templates -Custom Badge Templates can be created and sync to the Searchspring Management Console using the Snapfu CLI. See [Welcome > Setup](https://searchspring.github.io/snap/snap-setup) for installing Snapfu +Custom Badge Templates can be created and sync to the Athos Search & Product Discovery Console using the Snapfu CLI. See [Welcome > Setup](https://searchspring.github.io/snap/snap-setup) for installing Snapfu ## Initialize Custom Badges @@ -60,7 +60,7 @@ export const CustomBadge = observer((props) => { ## Syncing Custom Badges -Next we'll sync our custom badge - registering it to the Searchspring Management Console +Next we'll sync our custom badge - registering it to the Athos Search & Product Discovery Console ```sh snapfu badges sync [badgename] @@ -102,7 +102,7 @@ The `componentMap` prop can also be used to overwrite the default badge componen |-------|----------|-------------| | `type` | ✔️ | Should not be changed. It is utilized by the Snapfu CLI when syncing | | `name` | ✔️ | Unique badge template identifier | -| `label` | ✔️ | Label that is displayed when selecting this badge template within the Searchspring Management Console | +| `label` | ✔️ | Label that is displayed when selecting this badge template within the Athos Search & Product Discovery Console | | `description` | ✔️ | Badge template description | | `component` | ✔️ | Component name this badge template should use. It should line up with the mapping provided to the `componentMap` props. See `Using Custom Badges` section above | | `locations` | ✔️ | A list of template locations this badge template can be placed in. This can be used to restrict certain badges to certain locations. See `Custom Badge Locations` section below for adding locations. See `Badge Template Locations` section below for possible values | @@ -148,7 +148,7 @@ Badge template parameters is an array of objects. Each object is a template para |-------|----------|------|-------------| | `name` | ✔️ | string | Unique badge parameter identifier | | `type` | ✔️ | string | Parameter value type. Available types: `array`, `string`, `color`, `url`, `integer`, `decimal`, `boolean`, `checkbox`, `toggle`. See example below for example usage of each type | -| `label` | ✔️ | string | Label that is displayed when selecting this badge parameter within the Searchspring Management Console | +| `label` | ✔️ | string | Label that is displayed when selecting this badge parameter within the Athos Search & Product Discovery Console | | `description` | ✔️ | string | Badge parameter description | | `options` | ✔️* | string[] | Required only if `type` is `array`. Define an array of strings containing dropdown value options | | `defaultValue` | ➖ | string | Default value that will be used unless specified when configuring a new badge rule. Must be a string regardless of different `type` options | @@ -243,7 +243,7 @@ Badge template parameters is an array of objects. Each object is a template para ## Custom Badge Locations -Custom Badge Locations can be created and synced to the Searchspring Management Console using the Snapfu CLI. See [Welcome > Setup](https://searchspring.github.io/snap/snap-setup) for installing Snapfu +Custom Badge Locations can be created and synced to the Athos Search & Product Discovery Console using the Snapfu CLI. See [Welcome > Setup](https://searchspring.github.io/snap/snap-setup) for installing Snapfu Custom overlay and callout locations can be created by defining a `locations.json` file in the project. It is recommended to create it at: `src/components/Badges/locations.json` @@ -256,7 +256,7 @@ Custom overlay and callout locations can be created by defining a `locations.jso `['left' | 'right' | 'callout'].tag` - unique badge location identifier -`['left' | 'right' | 'callout'].name` - badge location name that is displayed when selecting this location within the Searchspring Management Console +`['left' | 'right' | 'callout'].name` - badge location name that is displayed when selecting this location within the Athos Search & Product Discovery Console > [!IMPORTANT] > It is strongly recommended to keep the default location tags (ie. `left[0].tag="left"`, `right[0].tag="right"`, `callout[0].tag="callout"`) to ensure any existing badges are backwards compatible with additional locations diff --git a/docs/REFERENCE_CUSTOM_RECOMMENDATION_TEMPLATES.md b/docs/REFERENCE_CUSTOM_RECOMMENDATION_TEMPLATES.md index d35bd36c5f..e757502adc 100644 --- a/docs/REFERENCE_CUSTOM_RECOMMENDATION_TEMPLATES.md +++ b/docs/REFERENCE_CUSTOM_RECOMMENDATION_TEMPLATES.md @@ -4,7 +4,7 @@ Let's look at how to setup a custom recommendation template using the Snapfu CLI There are three steps required for adding recommendations: - Creating the local template files -- Syncing the template to the Searchspring Management Console +- Syncing the template to the Athos Search & Product Discovery Console - Updating our Snap config (see instantiator config above) ### Creating a new recommendation template @@ -19,10 +19,10 @@ In this example, we'll create a new template with a name of "DefaultRecommendati This will generate three files which should be committed to your repository: - The `.jsx` file (/src/components/Recommendations/Default.jsx) is the template itself containing our component. - The `.scss` file (/src/components/Recommendations/DefaultRecommendations.scss) is imported by the `.jsx` template file and optional CSS styling can be defined here. -- The `.json` file (/src/components/Recommendations/DefaultRecommendations.json) contains various meta data for this template and is used when running `snapfu recs sync` to sync this template to Searchspring's Management Console API. See syncing documentation below. +- The `.json` file (/src/components/Recommendations/DefaultRecommendations.json) contains various meta data for this template and is used when running `snapfu recs sync` to sync this template to Athos' Search & Product Discovery API. See syncing documentation below. #### `.json` file parameters -The `.json` file allows template parameters to be specified. Template parameters are returned in the Recommendations API and accessible in your recommendation components via `controller.store.profile.display.templateParameters`. Template parameters can be set in the Searchspring Management Console after the template has been synced. +The `.json` file allows template parameters to be specified. Template parameters are returned in the Recommendations API and accessible in your recommendation components via `controller.store.profile.display.templateParameters`. Template parameters can be set in the Athos Search & Product Discovery Console after the template has been synced. Example: ```json @@ -48,7 +48,7 @@ At this point, you can customize the `.jsx` template to your requirements. By de ### Syncing Templates -Syncing custom templates to Searchspring's Management Console is required before they can be used. This is due to the recommendations API that returns the template's component name defined for the profile we set in the `.json` file above. +Syncing custom templates to Athos' Search & Product Discovery Console is required before they can be used. This is due to the recommendations API that returns the template's component name defined for the profile we set in the `.json` file above. Templates also support branching. For production-ready templates, please ensure you are on the repository's default branch (typically `production`) before running `snapfu recs sync` diff --git a/docs/SNAP_AUTOCOMPLETE.md b/docs/SNAP_AUTOCOMPLETE.md index 0b1e712c57..f37325e456 100644 --- a/docs/SNAP_AUTOCOMPLETE.md +++ b/docs/SNAP_AUTOCOMPLETE.md @@ -14,7 +14,7 @@ However in our example, since they are both the same value, the Autocomplete com ```js // src/index.js -import { Snap } from '@searchspring/snap-preact'; +import { Snap } from '@athoscommerce/snap-preact'; const snap = new Snap({ client: { @@ -42,7 +42,7 @@ const snap = new Snap({ selector: 'header input[type="search"]', hideTarget: true, component: async () => { - return (await import('@searchspring/snap-preact-components')).Autocomplete; + return (await import('@athoscommerce/snap-preact-components')).Autocomplete; }, }, ], @@ -56,7 +56,7 @@ const snap = new Snap({ ## Autocomplete Store -It is recommended to utilizing the [Autocomplete](https://searchspring.github.io/snap/preact-components?params=?path=/story/organisms-autocomplete--default) component from `@searchspring/snap-preact-components` to display Autocomplete. +It is recommended to utilizing the [Autocomplete](https://searchspring.github.io/snap/preact-components?params=?path=/story/organisms-autocomplete--default) component from `@athoscommerce/snap-preact-components` to display Autocomplete. The following properties are specific to an Autocomplete Store via an Autocomplete Controller. diff --git a/docs/SNAP_BACKGROUND_FILTERS.md b/docs/SNAP_BACKGROUND_FILTERS.md index 3ac004f007..11e297dabc 100644 --- a/docs/SNAP_BACKGROUND_FILTERS.md +++ b/docs/SNAP_BACKGROUND_FILTERS.md @@ -14,7 +14,7 @@ Background filters allow a page to be refined without displaying the active filt In this example, we'll retrieve the `collection` object from the context and apply it as a category background filter for our search controller. ```html - ``` -The [`RecommendationInstantiator`](https://searchspring.github.io/snap/reference-snap-preact-instantiators) will look for these elements on the page and attempt to inject components based on the `profile` specified in the script attribute. In the example above, the profile specified is the `recently-viewed` profile, and would typically be setup to display the last products viewed by the shopper. These profiles must be setup in the Searchspring Management Console (SMC). +The [`RecommendationInstantiator`](https://searchspring.github.io/snap/reference-snap-preact-instantiators) will look for these elements on the page and attempt to inject components based on the `profile` specified in the script attribute. In the example above, the profile specified is the `recently-viewed` profile, and would typically be setup to display the last products viewed by the shopper. These profiles must be setup in the Athos Search & Product Discovery Console (ASD). ## Recommendation Context Variables @@ -91,7 +91,7 @@ Alternatively, a profile can be placed in it's own batch via the `batched: false ## Additional Examples -The examples below assume that profiles used have been setup in the Searchspring Management Console (SMC), and that a Snap `bundle.js` script exists on the page and has been configured with a [`RecommendationInstantiator`](https://searchspring.github.io/snap/reference-snap-preact-instantiators). +The examples below assume that profiles used have been setup in the Athos Search & Product Discovery Console (ASD), and that a Snap `bundle.js` script exists on the page and has been configured with a [`RecommendationInstantiator`](https://searchspring.github.io/snap/reference-snap-preact-instantiators). A typical "similar" profile that would display products similar to the product passed in via the `product` context variable. diff --git a/docs/SNAP_SEARCH.md b/docs/SNAP_SEARCH.md index e4903baa05..9317207037 100644 --- a/docs/SNAP_SEARCH.md +++ b/docs/SNAP_SEARCH.md @@ -6,7 +6,7 @@ To set up Search using Snap, we'll need to define a search controller in our Sna ```js // src/index.js -import { Snap } from '@searchspring/snap-preact'; +import { Snap } from '@athoscommerce/snap-preact'; const snap = new Snap({ client: { @@ -56,7 +56,7 @@ For example, if a global variable `snapConfig` exists on the page (must be defin ```js // src/index.js -import { Snap } from '@searchspring/snap-preact'; +import { Snap } from '@athoscommerce/snap-preact'; const backgroundFilters = []; if (snapConfig?.category) { @@ -98,12 +98,12 @@ const snap = new Snap({ ## Search Store -This section covers the properties available on the Search Store via a Search Controller with examples of how to implement common custom components. Alternatively, equivalent and additional components are available in the `@searchspring/snap-preact-components` package. See [Preact Component Library](https://searchspring.github.io/snap/preact-components) for all available components and their usage. +This section covers the properties available on the Search Store via a Search Controller with examples of how to implement common custom components. Alternatively, equivalent and additional components are available in the `@athoscommerce/snap-preact-components` package. See [Preact Component Library](https://searchspring.github.io/snap/preact-components) for all available components and their usage. ### SearchController.store.merchandising -The `merchandising` property contains merchandising redirects and banner content. It is recommended to utilize the `` component from `@searchspring/snap-preact-components` to display the various merchandising banners. +The `merchandising` property contains merchandising redirects and banner content. It is recommended to utilize the `` component from `@athoscommerce/snap-preact-components` to display the various merchandising banners. The available banner types include: `header`, `banner`, `footer`, `left`, `inline` @@ -114,7 +114,7 @@ For inline banners, the `` component should be used instead. An e import { h } from 'preact'; import { observer } from 'mobx-react'; -import { ControllerProvider, Banner, Pagination } from '@searchspring/snap-preact-components'; +import { ControllerProvider, Banner, Pagination } from '@athoscommerce/snap-preact-components'; import { Results } from '../Results/Results'; import { NoResults } from '../NoResults/NoResults'; import { SearchHeader } from '../SearchHeader/SearchHeader'; @@ -150,7 +150,7 @@ The `search` property contains information about the current query, typically di import { h } from 'preact'; import { observer } from 'mobx-react'; -import { withController } from '@searchspring/snap-preact-components'; +import { withController } from '@athoscommerce/snap-preact-components'; export const SearchHeader = withController(observer((props) => { const { controller } = props; @@ -208,7 +208,7 @@ The `pagination` property is not only used for information about the current que import { h } from 'preact'; import { observer } from 'mobx-react'; -import { withController } from '@searchspring/snap-preact-components'; +import { withController } from '@athoscommerce/snap-preact-components'; export const Pagination = withController(observer((props) => { const { controller } = props; @@ -250,14 +250,14 @@ export const Pagination = withController(observer((props) => { The `sorting` property contains sorting options applicable to the current query. Typically used to render a ``; + document.body.innerHTML = ``; const acConfig = { ...baseConfig, @@ -976,7 +976,7 @@ describe('Snap Preact', () => { it(`creates targeter provided in config`, async () => { const baseConfig = generateBaseConfig(); - document.body.innerHTML = ``; + document.body.innerHTML = ``; const acConfig = { ...baseConfig, @@ -1012,7 +1012,7 @@ describe('Snap Preact', () => { const baseConfig = generateBaseConfig(); const onTarget = jest.fn(); - document.body.innerHTML = ``; + document.body.innerHTML = ``; const acConfig = { ...baseConfig, @@ -1045,7 +1045,7 @@ describe('Snap Preact', () => { it(`sets integratedSpellCorrection feature flag`, async () => { const baseConfig = generateBaseConfig(); - document.body.innerHTML = ``; + document.body.innerHTML = ``; const acConfig = { ...baseConfig, @@ -1086,7 +1086,7 @@ describe('Snap Preact', () => { it(`preserves controller integratedSpellCorrection setting when feature flag is set`, async () => { const baseConfig = generateBaseConfig(); - document.body.innerHTML = ``; + document.body.innerHTML = ``; const acConfig = { ...baseConfig, @@ -1201,7 +1201,7 @@ describe('Snap Preact', () => { it(`logs an error when targeter has invalid configuration`, async () => { const baseConfig = generateBaseConfig(); - document.body.innerHTML = `
`; + document.body.innerHTML = `
`; const finderConfig = { ...baseConfig, @@ -1255,7 +1255,7 @@ describe('Snap Preact', () => { it(`creates targeter provided in config`, async () => { const baseConfig = generateBaseConfig(); - document.body.innerHTML = `
`; + document.body.innerHTML = `
`; const finderConfig = { ...baseConfig, @@ -1295,7 +1295,7 @@ describe('Snap Preact', () => { const baseConfig = generateBaseConfig(); const onTarget = jest.fn(); - document.body.innerHTML = `
`; + document.body.innerHTML = `
`; const finderConfig = { ...baseConfig, @@ -1390,7 +1390,7 @@ describe('Snap Preact', () => { it(`logs an error when targeter has invalid configuration`, async () => { const baseConfig = generateBaseConfig(); - document.body.innerHTML = ``; + document.body.innerHTML = ``; const recommendationConfig = { ...baseConfig, @@ -1437,7 +1437,7 @@ describe('Snap Preact', () => { it(`creates targeter provided in config`, async () => { const baseConfig = generateBaseConfig(); - document.body.innerHTML = ``; + document.body.innerHTML = ``; const recommendationConfig = { ...baseConfig, @@ -1471,7 +1471,7 @@ describe('Snap Preact', () => { const baseConfig = generateBaseConfig(); const onTarget = jest.fn(); - document.body.innerHTML = ``; + document.body.innerHTML = ``; const recommendationConfig = { ...baseConfig, @@ -1512,8 +1512,8 @@ describe('Snap Preact', () => { expect(snap.eventManager.fire).toBeDefined(); expect(snap.eventManager.on).toBeDefined(); - expect(window.searchspring.on).toBeDefined(); - expect(window.searchspring.fire).toBeDefined(); + expect(window.athos.on).toBeDefined(); + expect(window.athos.fire).toBeDefined(); const func = jest.fn(); diff --git a/packages/snap-preact/src/Snap.tsx b/packages/snap-preact/src/Snap.tsx index be560670d7..4805b8b224 100644 --- a/packages/snap-preact/src/Snap.tsx +++ b/packages/snap-preact/src/Snap.tsx @@ -3,16 +3,16 @@ import deepmerge from 'deepmerge'; import { isPlainObject } from 'is-plain-object'; import { configure as configureMobx } from 'mobx'; -import { Client } from '@searchspring/snap-client'; -import { Logger } from '@searchspring/snap-logger'; -import { Tracker } from '@searchspring/snap-tracker'; -import { AppMode, version, getContext, DomTargeter, url, cookies, featureFlags } from '@searchspring/snap-toolbox'; -import { ControllerTypes } from '@searchspring/snap-controller'; -import { EventManager } from '@searchspring/snap-event-manager'; +import { Client } from '@athoscommerce/snap-client'; +import { Logger } from '@athoscommerce/snap-logger'; +import { Tracker } from '@athoscommerce/snap-tracker'; +import { AppMode, version, getContext, DomTargeter, url, cookies, featureFlags } from '@athoscommerce/snap-toolbox'; +import { ControllerTypes } from '@athoscommerce/snap-controller'; +import { EventManager } from '@athoscommerce/snap-event-manager'; import { getInitialUrlState } from './getInitialUrlState/getInitialUrlState'; -import type { ClientConfig, ClientGlobals } from '@searchspring/snap-client'; +import type { ClientConfig, ClientGlobals } from '@athoscommerce/snap-client'; import type { Controllers, AbstractController, @@ -23,10 +23,10 @@ import type { RecommendationControllerConfig, ControllerConfigs, ContextVariables, -} from '@searchspring/snap-controller'; -import type { TrackerConfig, TrackerGlobals, TrackErrorEvent } from '@searchspring/snap-tracker'; -import type { Target, OnTarget } from '@searchspring/snap-toolbox'; -import type { UrlTranslatorConfig } from '@searchspring/snap-url-manager'; +} from '@athoscommerce/snap-controller'; +import type { TrackerConfig, TrackerGlobals, TrackErrorEvent } from '@athoscommerce/snap-tracker'; +import type { Target, OnTarget } from '@athoscommerce/snap-toolbox'; +import type { UrlTranslatorConfig } from '@athoscommerce/snap-url-manager'; import { default as createSearchController } from './create/createSearchController'; import { RecommendationInstantiator, RecommendationInstantiatorConfig } from './Instantiators/RecommendationInstantiator'; @@ -38,10 +38,10 @@ import type { TemplatesStore } from './Templates/Stores/TemplateStore'; // configure MobX configureMobx({ useProxies: 'never', isolateGlobalState: true, enforceActions: 'never' }); -export const BRANCH_COOKIE = 'ssBranch'; -export const BRANCH_PARAM = 'searchspring-preview'; -export const DEV_COOKIE = 'ssDev'; -export const STYLESHEET_CLASSNAME = 'ss-snap-bundle-styles'; +export const BRANCH_COOKIE = 'athosBranch'; +export const BRANCH_PARAM = 'athos-preview'; +export const DEV_COOKIE = 'athos-Dev'; +export const STYLESHEET_CLASSNAME = 'athos-snap-bundle-styles'; export type ExtendedTarget = Target & { name?: string; @@ -105,7 +105,7 @@ This usually happens when you pass a JSX Element, and not a function that return targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', hideTarget: true, component: , }, @@ -115,7 +115,7 @@ This usually happens when you pass a JSX Element, and not a function that return targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', hideTarget: true, component: Content, }, @@ -125,7 +125,7 @@ This usually happens when you pass a JSX Element, and not a function that return targeters: [ { - selector: '#searchspring-content', + selector: '#athos-content', hideTarget: true, component: () => Content }, @@ -220,8 +220,8 @@ export class Snap { const creationFunc: (config: SnapControllerConfig, services: SnapControllerServices) => Controllers = (await importPromise).default; if (!this.controllers[config.id]) { - window.searchspring.controller = window.searchspring.controller || {}; - window.searchspring.controller[config.id] = this.controllers[config.id] = creationFunc( + window.athos.controller = window.athos.controller || {}; + window.athos.controller[config.id] = this.controllers[config.id] = creationFunc( { mode: this.mode, url: deepmerge(this.config.url || {}, urlConfig || {}), @@ -303,7 +303,11 @@ export class Snap { error: (event: ErrorEvent): void => { try { const { filename } = event; - if (filename.includes('snapui.searchspring.io') && filename.endsWith('.js') && this.tracker.track.error) { + if ( + (filename.includes('snapui.searchspring.io') || filename.includes('snapui.athoscommerce.io')) && + filename.endsWith('.js') && + this.tracker.track.error + ) { const { colno, lineno, @@ -451,7 +455,7 @@ export class Snap { }); } - const initiatorPrefix = window?.searchspring?.managed ? `managed/` : ''; + const initiatorPrefix = window?.athos?.managed ? `managed/` : ''; const trackerConfig = deepmerge(this.config.tracker?.config || {}, { framework: `${initiatorPrefix}snap/preact`, mode: this.mode }); this.tracker = services?.tracker || new Tracker(trackerGlobals, trackerConfig); @@ -474,13 +478,20 @@ export class Snap { } // get the path and siteId from the current bundle script in case its not the same as the client config - let path = `https://snapui.searchspring.io/${this.config.client?.globals?.siteId}/`; - const script: HTMLScriptElement | null = document.querySelector('script[src*="//snapui.searchspring.io"]'); + let path = `https://snapui.athoscommerce.io/${this.config.client?.globals?.siteId}/`; + const script: HTMLScriptElement | null = document.querySelector( + 'script[src*="//snapui.searchspring.io"], script[src*="//snapui.athoscommerce.io"]' + ); if (script) { - const scriptRoot = script.getAttribute('src')!.match(/\/\/snapui.searchspring.io\/[a-zA-Z0-9]{6}\//); + let scriptRoot = script.getAttribute('src')!.match(/\/\/snapui.searchspring.io\/[a-zA-Z0-9]{6}\//); if (scriptRoot) { path = scriptRoot.toString(); + } else { + scriptRoot = script.getAttribute('src')!.match(/\/\/snapui.athoscommerce.io\/[a-zA-Z0-9]{6}\//); + if (scriptRoot) { + path = scriptRoot.toString(); + } } } @@ -498,7 +509,7 @@ export class Snap { action: 'append', // before, after, append, prepend element: () => { const branchContainer = document.createElement('div'); - branchContainer.id = 'searchspring-branch-override'; + branchContainer.id = 'athos-branch-override'; return branchContainer; }, }, @@ -538,11 +549,13 @@ export class Snap { elem ); - // reset the global searchspring object + // reset the global athos object try { - delete window.searchspring; + delete window.athos; + delete window.athos; } catch (e) { - window.searchspring = undefined; + window.athos = undefined; + window.athos = undefined; } document.head.appendChild(branchScript); @@ -564,20 +577,20 @@ export class Snap { } // bind to window global - window.searchspring = window.searchspring || {}; - window.searchspring.build = window.searchspring.build || 'modern'; - window.searchspring.context = this.context; - if (this.client) window.searchspring.client = this.client; - if (services?.templatesStore) window.searchspring.templates = this.templates; + window.athos = window.athos || {}; + window.athos.build = window.athos.build || 'modern'; + window.athos.context = this.context; + if (this.client) window.athos.client = this.client; + if (services?.templatesStore) window.athos.templates = this.templates; this.eventManager = setupEvents(); if (this.eventManager) { - window.searchspring.on = (event: string, ...func: any) => { + window.athos.on = (event: string, ...func: any) => { this.eventManager.on(event, ...func); }; - window.searchspring.fire = (event: string, ...func: any) => { + window.athos.fire = (event: string, ...func: any) => { this.eventManager.fire(event, ...func); }; } @@ -618,8 +631,8 @@ export class Snap { } ); - window.searchspring.controller = window.searchspring.controller || {}; - window.searchspring.controller[cntrlr.config.id] = this.controllers[cntrlr.config.id] = cntrlr; + window.athos.controller = window.athos.controller || {}; + window.athos.controller[cntrlr.config.id] = this.controllers[cntrlr.config.id] = cntrlr; this._controllerPromises[cntrlr.config.id] = new Promise((resolve) => resolve(cntrlr)); let searchPromise: Promise | null = null; @@ -770,7 +783,7 @@ export class Snap { action: 'after', // before, after, append, prepend element: () => { const acContainer = document.createElement('div'); - acContainer.className = 'ss__autocomplete--target'; + acContainer.className = 'athos__autocomplete--target'; acContainer.addEventListener('click', (e) => { e.stopPropagation(); }); diff --git a/packages/snap-preact/src/Templates/SnapTemplates.test.tsx b/packages/snap-preact/src/Templates/SnapTemplates.test.tsx index 7e875d8dd3..ddf708c0a1 100644 --- a/packages/snap-preact/src/Templates/SnapTemplates.test.tsx +++ b/packages/snap-preact/src/Templates/SnapTemplates.test.tsx @@ -1,4 +1,4 @@ -import { AutocompleteStoreConfigSettings, SearchStoreConfigSettings } from '@searchspring/snap-store-mobx'; +import { AutocompleteStoreConfigSettings, SearchStoreConfigSettings } from '@athoscommerce/snap-store-mobx'; import { SnapTemplates, mapBreakpoints, diff --git a/packages/snap-preact/src/Templates/SnapTemplates.tsx b/packages/snap-preact/src/Templates/SnapTemplates.tsx index a663c761bd..30758d6b8c 100644 --- a/packages/snap-preact/src/Templates/SnapTemplates.tsx +++ b/packages/snap-preact/src/Templates/SnapTemplates.tsx @@ -4,13 +4,13 @@ import deepmerge from 'deepmerge'; import { Snap } from '../Snap'; import { TemplateSelect } from '../../components/src/components/Atoms/TemplateSelect'; -import { DomTargeter, url, cookies, getContext, version } from '@searchspring/snap-toolbox'; +import { DomTargeter, url, cookies, getContext, version } from '@athoscommerce/snap-toolbox'; import { TemplateTarget, TemplatesStore } from './Stores/TemplateStore'; -import type { Target } from '@searchspring/snap-toolbox'; -import { type SearchStoreConfigSettings, type AutocompleteStoreConfigSettings } from '@searchspring/snap-store-mobx'; -import type { UrlTranslatorConfig } from '@searchspring/snap-url-manager'; -import type { AutocompleteController, PluginGrouping, SearchController } from '@searchspring/snap-controller'; +import type { Target } from '@athoscommerce/snap-toolbox'; +import { type SearchStoreConfigSettings, type AutocompleteStoreConfigSettings } from '@athoscommerce/snap-store-mobx'; +import type { UrlTranslatorConfig } from '@athoscommerce/snap-url-manager'; +import type { AutocompleteController, PluginGrouping, SearchController } from '@athoscommerce/snap-controller'; import type { RecommendationInstantiatorConfigSettings, RecommendationComponentObject, @@ -29,7 +29,7 @@ import { PluginAddToCartConfig, pluginLogger, PluginLoggerConfig, -} from '@searchspring/snap-platforms/common'; +} from '@athoscommerce/snap-platforms/common'; import { pluginBackgroundFilters as PluginShopifyBackgroundFilters, PluginBackgroundFiltersConfig as PluginShopifyBackgroundFiltersConfig, @@ -37,22 +37,22 @@ import { PluginMutateResultsConfig as PluginShopifyMutateResultsConfig, pluginAddToCart as pluginShopifyAddToCart, PluginAddToCartConfig as PluginShopifyAddToCartConfig, -} from '@searchspring/snap-platforms/shopify'; +} from '@athoscommerce/snap-platforms/shopify'; import { pluginAddToCart as pluginBigcommerceAddToCart, PluginAddToCartConfig as PluginBigCommerceAddToCartConfig, pluginBackgroundFilters as pluginBigcommerceBackgroundFilters, PluginBackgroundFiltersConfig as PluginBigcommerceBackgroundFiltersConfig, -} from '@searchspring/snap-platforms/bigcommerce'; +} from '@athoscommerce/snap-platforms/bigcommerce'; import { pluginAddToCart as pluginMagento2AddToCart, AddToCartConfig as PluginMagento2AddToCartConfig, pluginBackgroundFilters as pluginMagento2BackgroundFilters, PluginBackgroundFiltersConfig as PluginMagento2BackgroundFiltersConfig, -} from '@searchspring/snap-platforms/magento2'; +} from '@athoscommerce/snap-platforms/magento2'; -export const TEMPLATE_EDIT_COOKIE = 'ssEditor'; -const TEMPLATE_EDITOR_PARAM = 'searchspring-editor'; +export const TEMPLATE_EDIT_COOKIE = 'athosEditor'; +const TEMPLATE_EDITOR_PARAM = 'athos-editor'; // TODO: tabbing, finder export type SearchTargetConfig = { @@ -191,7 +191,7 @@ export class SnapTemplates extends Snap { action: 'append', element: () => { const themeEditContainer = document.createElement('div'); - themeEditContainer.id = 'searchspring-template-editor'; + themeEditContainer.id = 'athos-template-editor'; return themeEditContainer; }, }, diff --git a/packages/snap-preact/src/Templates/Stores/LibraryStore.ts b/packages/snap-preact/src/Templates/Stores/LibraryStore.ts index 45b5a1b450..d935ad4e19 100644 --- a/packages/snap-preact/src/Templates/Stores/LibraryStore.ts +++ b/packages/snap-preact/src/Templates/Stores/LibraryStore.ts @@ -3,7 +3,7 @@ import { FunctionalComponent, RenderableProps } from 'preact'; import type { Theme, ThemeComplete, ThemeMinimal } from '../../../components/src'; import { transformTranslationsToTheme, type TemplateCustomComponentTypes, type TemplateTypes } from './TemplateStore'; import type { TemplateStoreComponentConfig } from './TemplateStore'; -import type { PluginFunction } from '@searchspring/snap-controller'; +import type { PluginFunction } from '@athoscommerce/snap-controller'; import { pluginBackgroundFilters as shopifyPluginBackgroundFilters } from './library/plugins/shopify/pluginBackgroundFilters'; import { pluginMutateResults as shopifyPluginMutateResults } from './library/plugins/shopify/pluginMutateResults'; import { pluginAddToCart as shopifyPluginAddToCart } from './library/plugins/shopify/pluginAddToCart'; diff --git a/packages/snap-preact/src/Templates/Stores/TargetStore.test.ts b/packages/snap-preact/src/Templates/Stores/TargetStore.test.ts index 353e39c118..55880c430e 100644 --- a/packages/snap-preact/src/Templates/Stores/TargetStore.test.ts +++ b/packages/snap-preact/src/Templates/Stores/TargetStore.test.ts @@ -1,4 +1,4 @@ -import { StorageStore } from '@searchspring/snap-store-mobx'; +import { StorageStore } from '@athoscommerce/snap-store-mobx'; import { GLOBAL_THEME_NAME, TargetStore } from './TargetStore'; import { TemplatesStoreDependencies, TemplatesStoreConfigSettings, TemplateThemeTypes } from './TemplateStore'; diff --git a/packages/snap-preact/src/Templates/Stores/TemplateEditor/TemplateEditorStore.ts b/packages/snap-preact/src/Templates/Stores/TemplateEditor/TemplateEditorStore.ts index 572056803f..85701600a0 100644 --- a/packages/snap-preact/src/Templates/Stores/TemplateEditor/TemplateEditorStore.ts +++ b/packages/snap-preact/src/Templates/Stores/TemplateEditor/TemplateEditorStore.ts @@ -1,10 +1,10 @@ -import { AutocompleteStoreConfigSettings, SearchStoreConfigSettings, StorageStore, StorageType } from '@searchspring/snap-store-mobx'; +import { AutocompleteStoreConfigSettings, SearchStoreConfigSettings, StorageStore, StorageType } from '@athoscommerce/snap-store-mobx'; import { observable, makeObservable } from 'mobx'; import Color from 'color'; import deepmerge from 'deepmerge'; import { TemplatesStore, TEMPLATE_STORE_KEY, TargetMap, RecsTemplateTypes } from '../TemplateStore'; -import { AutocompleteController, SearchController } from '@searchspring/snap-controller'; +import { AutocompleteController, SearchController } from '@athoscommerce/snap-controller'; import type { AbstractionGroup } from '../../../types'; import { ThemeVariables, ThemeVariablesPartial } from '../../../../components/src'; diff --git a/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/autocompleteControllerUI.ts b/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/autocompleteControllerUI.ts index 994e97b7aa..72278530bd 100644 --- a/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/autocompleteControllerUI.ts +++ b/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/autocompleteControllerUI.ts @@ -1,4 +1,4 @@ -import { AutocompleteController } from '@searchspring/snap-controller'; +import { AutocompleteController } from '@athoscommerce/snap-controller'; import { AbstractionGroup } from '../../../../types'; import { TemplateEditorStore } from '../TemplateEditorStore'; diff --git a/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/configUI.ts b/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/configUI.ts index 51b3a5735d..b84126b5e1 100644 --- a/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/configUI.ts +++ b/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/configUI.ts @@ -9,7 +9,7 @@ export const configUI = (store: TemplateEditorStore): AbstractionGroup[] => { { type: 'text', label: 'SiteId', - description: 'site id used to connect to the searchspring service', + description: 'site id used to connect to the athos service', getDisplayState: () => 'disabled', getValue: () => { // value is derived in the editorstore at construction time diff --git a/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/searchControllerUI.ts b/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/searchControllerUI.ts index 72ff0711e6..7e65fc6d6f 100644 --- a/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/searchControllerUI.ts +++ b/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/searchControllerUI.ts @@ -1,4 +1,4 @@ -import { SearchController } from '@searchspring/snap-controller'; +import { SearchController } from '@athoscommerce/snap-controller'; import { AbstractionGroup } from '../../../../types'; import { TemplateEditorStore } from '../TemplateEditorStore'; diff --git a/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/themeUI.ts b/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/themeUI.ts index c3ab0ae5de..621c8a13eb 100644 --- a/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/themeUI.ts +++ b/packages/snap-preact/src/Templates/Stores/TemplateEditor/uiAbstractions/themeUI.ts @@ -1,4 +1,4 @@ -import { debounce } from '@searchspring/snap-toolbox'; +import { debounce } from '@athoscommerce/snap-toolbox'; import { AbstractionGroup } from '../../../../types'; import { TemplateEditorStore } from '../TemplateEditorStore'; diff --git a/packages/snap-preact/src/Templates/Stores/TemplateStore.ts b/packages/snap-preact/src/Templates/Stores/TemplateStore.ts index c11ede5f0f..d280369f41 100644 --- a/packages/snap-preact/src/Templates/Stores/TemplateStore.ts +++ b/packages/snap-preact/src/Templates/Stores/TemplateStore.ts @@ -1,29 +1,29 @@ import { observable, makeObservable } from 'mobx'; -import { StorageStore, StorageType } from '@searchspring/snap-store-mobx'; +import { StorageStore, StorageType } from '@athoscommerce/snap-store-mobx'; import { SnapTemplatesConfig } from '../SnapTemplates'; import { ThemeStore, ThemeStoreThemeConfig } from './ThemeStore'; import { TargetStore } from './TargetStore'; import { CurrencyCodes, LanguageCodes, LibraryImports, LibraryStore } from './LibraryStore'; -import { debounce } from '@searchspring/snap-toolbox'; +import { debounce } from '@athoscommerce/snap-toolbox'; import type { PluginAddToCartConfig as PluginShopifyAddToCartConfig, PluginBackgroundFiltersConfig as PluginShopifyBackgroundFiltersConfig, PluginMutateResultsConfig as PluginShopifyMutateResultsConfig, -} from '@searchspring/snap-platforms/shopify'; +} from '@athoscommerce/snap-platforms/shopify'; import type { PluginAddToCartConfig as PluginMagento2AddToCartConfig, PluginBackgroundFiltersConfig as PluginMagento2BackgroundFiltersConfig, -} from '@searchspring/snap-platforms/magento2'; +} from '@athoscommerce/snap-platforms/magento2'; import type { PluginAddToCartConfig as PluginBigCommerceAddToCartConfig, PluginBackgroundFiltersConfig as PluginBigcommerceBackgroundFiltersConfig, -} from '@searchspring/snap-platforms/bigcommerce'; +} from '@athoscommerce/snap-platforms/bigcommerce'; import type { PluginAddToCartConfig, PluginBackgroundFiltersConfig, PluginLoggerConfig, PluginScrollToTopConfig, -} from '@searchspring/snap-platforms/common'; +} from '@athoscommerce/snap-platforms/common'; import type { ConfigThemeOverrides, LangComponentOverrides, @@ -34,7 +34,7 @@ import type { ThemeVariablesPartial, } from '../../../components/src'; import type { GlobalThemeStyleScript, IntegrationPlatforms } from '../../types'; -import type { ClientConfig } from '@searchspring/snap-client'; +import type { ClientConfig } from '@athoscommerce/snap-client'; export type TemplateThemeTypes = 'library' | 'local'; export type TemplateTypes = 'search' | 'autocomplete' | `recommendation/${RecsTemplateTypes}`; @@ -128,7 +128,7 @@ export type TemplateStoreConfigConfig = { }; const RESIZE_DEBOUNCE = 100; -export const TEMPLATE_STORE_KEY = 'ss-templates'; +export const TEMPLATE_STORE_KEY = 'athos-templates'; export type TemplateStoreConfig = { config: TemplateStoreConfigConfig; diff --git a/packages/snap-preact/src/Templates/Stores/ThemeStore.test.ts b/packages/snap-preact/src/Templates/Stores/ThemeStore.test.ts index b22a4c48c8..6647fe7f11 100644 --- a/packages/snap-preact/src/Templates/Stores/ThemeStore.test.ts +++ b/packages/snap-preact/src/Templates/Stores/ThemeStore.test.ts @@ -3,7 +3,7 @@ import '@testing-library/jest-dom'; import { waitFor } from '@testing-library/preact'; import { ThemeStore, ThemeStoreThemeConfig, mergeThemeLayers } from './ThemeStore'; -import { StorageStore } from '@searchspring/snap-store-mobx'; +import { StorageStore } from '@athoscommerce/snap-store-mobx'; import type { TemplatesStoreDependencies, TemplateThemeTypes, TemplatesStoreConfigSettings } from './TemplateStore'; import type { ThemeComplete, ThemeVariables, ThemePartial } from '../../../components/src/providers/theme'; import { GLOBAL_THEME_NAME } from './TargetStore'; @@ -575,7 +575,7 @@ describe('ThemeStore', () => { const styleElements = document.querySelectorAll('head style')!; expect(styleElements).toHaveLength(2); - expect(styleElements[0].innerHTML).toBe(``); + expect(styleElements[0].innerHTML).toBe(``); expect(styleElements[1]).toHaveAttribute('data-emotion', 'ss-global'); }); diff --git a/packages/snap-preact/src/Templates/Stores/ThemeStore.tsx b/packages/snap-preact/src/Templates/Stores/ThemeStore.tsx index 6b5b7c252b..f859733146 100644 --- a/packages/snap-preact/src/Templates/Stores/ThemeStore.tsx +++ b/packages/snap-preact/src/Templates/Stores/ThemeStore.tsx @@ -116,7 +116,7 @@ export class ThemeStore { ); }); const styleElem = document.createElement('style'); - styleElem.innerHTML = ``; + styleElem.innerHTML = ``; document.head.appendChild(styleElem); render(, styleElem); } diff --git a/packages/snap-preact/src/Templates/Stores/library/languages/es.ts b/packages/snap-preact/src/Templates/Stores/library/languages/es.ts index 285a01ec33..bb7381cebd 100644 --- a/packages/snap-preact/src/Templates/Stores/library/languages/es.ts +++ b/packages/snap-preact/src/Templates/Stores/library/languages/es.ts @@ -1,5 +1,5 @@ import { LangComponents } from '../../../../../components/src'; -import type { ValueFacet } from '@searchspring/snap-store-mobx'; +import type { ValueFacet } from '@athoscommerce/snap-store-mobx'; export const es: LangComponents = { recommendation: {}, diff --git a/packages/snap-preact/src/Templates/Stores/library/languages/fr.ts b/packages/snap-preact/src/Templates/Stores/library/languages/fr.ts index 9a68b3c2c8..8c064d1ab7 100644 --- a/packages/snap-preact/src/Templates/Stores/library/languages/fr.ts +++ b/packages/snap-preact/src/Templates/Stores/library/languages/fr.ts @@ -1,4 +1,4 @@ -import type { ValueFacet } from '@searchspring/snap-store-mobx'; +import type { ValueFacet } from '@athoscommerce/snap-store-mobx'; import { LangComponents } from '../../../../../components/src'; export const fr: LangComponents = { diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/bigCommerce/pluginAddToCart.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/bigCommerce/pluginAddToCart.ts index 7cc4d295cb..994327bbe9 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/bigCommerce/pluginAddToCart.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/bigCommerce/pluginAddToCart.ts @@ -1 +1 @@ -export { pluginAddToCart } from '@searchspring/snap-platforms/bigcommerce'; +export { pluginAddToCart } from '@athoscommerce/snap-platforms/bigcommerce'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/bigCommerce/pluginBackgroundFilters.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/bigCommerce/pluginBackgroundFilters.ts index 242d686a15..9182fe0d5d 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/bigCommerce/pluginBackgroundFilters.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/bigCommerce/pluginBackgroundFilters.ts @@ -1 +1 @@ -export { pluginBackgroundFilters } from '@searchspring/snap-platforms/bigcommerce'; +export { pluginBackgroundFilters } from '@athoscommerce/snap-platforms/bigcommerce'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginAddToCart.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginAddToCart.ts index 4c7ae047cf..040780197c 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginAddToCart.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginAddToCart.ts @@ -1 +1 @@ -export { pluginAddToCart } from '@searchspring/snap-platforms/common'; +export { pluginAddToCart } from '@athoscommerce/snap-platforms/common'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginBackgroundFilters.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginBackgroundFilters.ts index 595d828331..0216304649 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginBackgroundFilters.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginBackgroundFilters.ts @@ -1 +1 @@ -export { pluginBackgroundFilters } from '@searchspring/snap-platforms/common'; +export { pluginBackgroundFilters } from '@athoscommerce/snap-platforms/common'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginLogger.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginLogger.ts index d6fd7b7fb6..8e6cdefdf2 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginLogger.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginLogger.ts @@ -1 +1 @@ -export { pluginLogger } from '@searchspring/snap-platforms/common'; +export { pluginLogger } from '@athoscommerce/snap-platforms/common'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginScrollToTop.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginScrollToTop.ts index cb5930b25d..128df3af1a 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginScrollToTop.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/common/pluginScrollToTop.ts @@ -1 +1 @@ -export { pluginScrollToTop } from '@searchspring/snap-platforms/common'; +export { pluginScrollToTop } from '@athoscommerce/snap-platforms/common'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/magento2/pluginAddToCart.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/magento2/pluginAddToCart.ts index 2f71df55ab..0e03d8a6cc 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/magento2/pluginAddToCart.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/magento2/pluginAddToCart.ts @@ -1 +1 @@ -export { pluginAddToCart } from '@searchspring/snap-platforms/magento2'; +export { pluginAddToCart } from '@athoscommerce/snap-platforms/magento2'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/magento2/pluginBackgroundFilters.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/magento2/pluginBackgroundFilters.ts index 53bcc2cf5c..681d4f8b74 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/magento2/pluginBackgroundFilters.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/magento2/pluginBackgroundFilters.ts @@ -1 +1 @@ -export { pluginBackgroundFilters } from '@searchspring/snap-platforms/magento2'; +export { pluginBackgroundFilters } from '@athoscommerce/snap-platforms/magento2'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginAddToCart.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginAddToCart.ts index 21fee22979..e39366ceeb 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginAddToCart.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginAddToCart.ts @@ -1 +1 @@ -export { pluginAddToCart } from '@searchspring/snap-platforms/shopify'; +export { pluginAddToCart } from '@athoscommerce/snap-platforms/shopify'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginBackgroundFilters.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginBackgroundFilters.ts index f35343d655..4a8aabeed8 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginBackgroundFilters.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginBackgroundFilters.ts @@ -1 +1 @@ -export { pluginBackgroundFilters } from '@searchspring/snap-platforms/shopify'; +export { pluginBackgroundFilters } from '@athoscommerce/snap-platforms/shopify'; diff --git a/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginMutateResults.ts b/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginMutateResults.ts index 288b86d2ac..dc079c435e 100644 --- a/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginMutateResults.ts +++ b/packages/snap-preact/src/Templates/Stores/library/plugins/shopify/pluginMutateResults.ts @@ -1 +1 @@ -export { pluginMutateResults } from '@searchspring/snap-platforms/shopify'; +export { pluginMutateResults } from '@athoscommerce/snap-platforms/shopify'; diff --git a/packages/snap-preact/src/create/createAutocompleteController.test.ts b/packages/snap-preact/src/create/createAutocompleteController.test.ts index a598389483..9eba5c0170 100644 --- a/packages/snap-preact/src/create/createAutocompleteController.test.ts +++ b/packages/snap-preact/src/create/createAutocompleteController.test.ts @@ -1,15 +1,15 @@ -import { Client } from '@searchspring/snap-client'; -import { AutocompleteStore } from '@searchspring/snap-store-mobx'; -import { UrlManager, UrlTranslator, reactLinker, CoreMap, UrlTranslatorSettingsConfig } from '@searchspring/snap-url-manager'; -import { EventManager } from '@searchspring/snap-event-manager'; -import { Profiler } from '@searchspring/snap-profiler'; -import { Logger } from '@searchspring/snap-logger'; -import { Tracker } from '@searchspring/snap-tracker'; +import { Client } from '@athoscommerce/snap-client'; +import { AutocompleteStore } from '@athoscommerce/snap-store-mobx'; +import { UrlManager, UrlTranslator, reactLinker, CoreMap, UrlTranslatorSettingsConfig } from '@athoscommerce/snap-url-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; +import { Profiler } from '@athoscommerce/snap-profiler'; +import { Logger } from '@athoscommerce/snap-logger'; +import { Tracker } from '@athoscommerce/snap-tracker'; import { createAutocompleteController } from './index'; import type { SnapAutocompleteControllerConfig } from '../types'; -import type { UrlTranslatorConfig } from '@searchspring/snap-url-manager'; +import type { UrlTranslatorConfig } from '@athoscommerce/snap-url-manager'; const createConfig: SnapAutocompleteControllerConfig = { client: { @@ -40,7 +40,7 @@ const createConfig: SnapAutocompleteControllerConfig = { describe('createAutocompleteController', () => { beforeEach(() => { - delete window.searchspring; + delete window.athos; }); it('throws when incomplete configuration is used', () => { diff --git a/packages/snap-preact/src/create/createAutocompleteController.ts b/packages/snap-preact/src/create/createAutocompleteController.ts index beefca1a95..5af9682d1b 100644 --- a/packages/snap-preact/src/create/createAutocompleteController.ts +++ b/packages/snap-preact/src/create/createAutocompleteController.ts @@ -1,11 +1,11 @@ -import { AutocompleteController } from '@searchspring/snap-controller'; -import { Client } from '@searchspring/snap-client'; -import { AutocompleteStore } from '@searchspring/snap-store-mobx'; -import { UrlManager, UrlTranslator, reactLinker } from '@searchspring/snap-url-manager'; -import { EventManager } from '@searchspring/snap-event-manager'; -import { Profiler } from '@searchspring/snap-profiler'; -import { Logger } from '@searchspring/snap-logger'; -import { Tracker } from '@searchspring/snap-tracker'; +import { AutocompleteController } from '@athoscommerce/snap-controller'; +import { Client } from '@athoscommerce/snap-client'; +import { AutocompleteStore } from '@athoscommerce/snap-store-mobx'; +import { UrlManager, UrlTranslator, reactLinker } from '@athoscommerce/snap-url-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; +import { Profiler } from '@athoscommerce/snap-profiler'; +import { Logger } from '@athoscommerce/snap-logger'; +import { Tracker } from '@athoscommerce/snap-tracker'; import type { SnapControllerServices, SnapAutocompleteControllerConfig } from '../types'; diff --git a/packages/snap-preact/src/create/createFinderController.test.ts b/packages/snap-preact/src/create/createFinderController.test.ts index 14fe16c348..26b6e53cbd 100644 --- a/packages/snap-preact/src/create/createFinderController.test.ts +++ b/packages/snap-preact/src/create/createFinderController.test.ts @@ -1,15 +1,15 @@ -import { Client } from '@searchspring/snap-client'; -import { FinderStore } from '@searchspring/snap-store-mobx'; -import { UrlManager, UrlTranslator, reactLinker, CoreMap, UrlTranslatorSettingsConfig } from '@searchspring/snap-url-manager'; -import { EventManager } from '@searchspring/snap-event-manager'; -import { Profiler } from '@searchspring/snap-profiler'; -import { Logger } from '@searchspring/snap-logger'; -import { Tracker } from '@searchspring/snap-tracker'; +import { Client } from '@athoscommerce/snap-client'; +import { FinderStore } from '@athoscommerce/snap-store-mobx'; +import { UrlManager, UrlTranslator, reactLinker, CoreMap, UrlTranslatorSettingsConfig } from '@athoscommerce/snap-url-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; +import { Profiler } from '@athoscommerce/snap-profiler'; +import { Logger } from '@athoscommerce/snap-logger'; +import { Tracker } from '@athoscommerce/snap-tracker'; import { createFinderController } from './index'; import type { SnapFinderControllerConfig } from '../types'; -import type { UrlTranslatorConfig } from '@searchspring/snap-url-manager'; +import type { UrlTranslatorConfig } from '@athoscommerce/snap-url-manager'; const createConfig: SnapFinderControllerConfig = { client: { @@ -54,7 +54,7 @@ const createConfig: SnapFinderControllerConfig = { describe('createFinderController', () => { beforeEach(() => { - delete window.searchspring; + delete window.athos; }); it('throws when incomplete configuration is used', () => { diff --git a/packages/snap-preact/src/create/createFinderController.ts b/packages/snap-preact/src/create/createFinderController.ts index 7d402b7f0d..e5986b42f4 100644 --- a/packages/snap-preact/src/create/createFinderController.ts +++ b/packages/snap-preact/src/create/createFinderController.ts @@ -1,11 +1,11 @@ -import { FinderController } from '@searchspring/snap-controller'; -import { Client } from '@searchspring/snap-client'; -import { FinderStore } from '@searchspring/snap-store-mobx'; -import { UrlManager, UrlTranslator, reactLinker } from '@searchspring/snap-url-manager'; -import { EventManager } from '@searchspring/snap-event-manager'; -import { Profiler } from '@searchspring/snap-profiler'; -import { Logger } from '@searchspring/snap-logger'; -import { Tracker } from '@searchspring/snap-tracker'; +import { FinderController } from '@athoscommerce/snap-controller'; +import { Client } from '@athoscommerce/snap-client'; +import { FinderStore } from '@athoscommerce/snap-store-mobx'; +import { UrlManager, UrlTranslator, reactLinker } from '@athoscommerce/snap-url-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; +import { Profiler } from '@athoscommerce/snap-profiler'; +import { Logger } from '@athoscommerce/snap-logger'; +import { Tracker } from '@athoscommerce/snap-tracker'; import type { SnapControllerServices, SnapFinderControllerConfig } from '../types'; diff --git a/packages/snap-preact/src/create/createRecommendationController.test.ts b/packages/snap-preact/src/create/createRecommendationController.test.ts index ecb0355b92..adec8be101 100644 --- a/packages/snap-preact/src/create/createRecommendationController.test.ts +++ b/packages/snap-preact/src/create/createRecommendationController.test.ts @@ -1,15 +1,15 @@ -import { Client } from '@searchspring/snap-client'; -import { RecommendationStore } from '@searchspring/snap-store-mobx'; -import { UrlManager, UrlTranslator, reactLinker, CoreMap, UrlTranslatorSettingsConfig } from '@searchspring/snap-url-manager'; -import { EventManager } from '@searchspring/snap-event-manager'; -import { Profiler } from '@searchspring/snap-profiler'; -import { Logger } from '@searchspring/snap-logger'; -import { Tracker } from '@searchspring/snap-tracker'; +import { Client } from '@athoscommerce/snap-client'; +import { RecommendationStore } from '@athoscommerce/snap-store-mobx'; +import { UrlManager, UrlTranslator, reactLinker, CoreMap, UrlTranslatorSettingsConfig } from '@athoscommerce/snap-url-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; +import { Profiler } from '@athoscommerce/snap-profiler'; +import { Logger } from '@athoscommerce/snap-logger'; +import { Tracker } from '@athoscommerce/snap-tracker'; import { createRecommendationController } from './index'; import type { SnapRecommendationControllerConfig } from '../types'; -import type { UrlTranslatorConfig } from '@searchspring/snap-url-manager'; +import type { UrlTranslatorConfig } from '@athoscommerce/snap-url-manager'; const createConfig: SnapRecommendationControllerConfig = { client: { @@ -40,7 +40,7 @@ const createConfig: SnapRecommendationControllerConfig = { describe('createRecommendationController', () => { beforeEach(() => { - delete window.searchspring; + delete window.athos; }); it('throws when incomplete configuration is used', () => { diff --git a/packages/snap-preact/src/create/createRecommendationController.ts b/packages/snap-preact/src/create/createRecommendationController.ts index 0357a9ec73..1dff06e250 100644 --- a/packages/snap-preact/src/create/createRecommendationController.ts +++ b/packages/snap-preact/src/create/createRecommendationController.ts @@ -1,11 +1,11 @@ -import { RecommendationController } from '@searchspring/snap-controller'; -import { Client } from '@searchspring/snap-client'; -import { RecommendationStore } from '@searchspring/snap-store-mobx'; -import { UrlManager, UrlTranslator, reactLinker } from '@searchspring/snap-url-manager'; -import { EventManager } from '@searchspring/snap-event-manager'; -import { Profiler } from '@searchspring/snap-profiler'; -import { Logger } from '@searchspring/snap-logger'; -import { Tracker } from '@searchspring/snap-tracker'; +import { RecommendationController } from '@athoscommerce/snap-controller'; +import { Client } from '@athoscommerce/snap-client'; +import { RecommendationStore } from '@athoscommerce/snap-store-mobx'; +import { UrlManager, UrlTranslator, reactLinker } from '@athoscommerce/snap-url-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; +import { Profiler } from '@athoscommerce/snap-profiler'; +import { Logger } from '@athoscommerce/snap-logger'; +import { Tracker } from '@athoscommerce/snap-tracker'; import type { SnapControllerServices, SnapRecommendationControllerConfig } from '../types'; diff --git a/packages/snap-preact/src/create/createSearchController.test.ts b/packages/snap-preact/src/create/createSearchController.test.ts index 8657df3693..23c9d2899f 100644 --- a/packages/snap-preact/src/create/createSearchController.test.ts +++ b/packages/snap-preact/src/create/createSearchController.test.ts @@ -1,15 +1,15 @@ -import { Client } from '@searchspring/snap-client'; -import { SearchStore } from '@searchspring/snap-store-mobx'; -import { UrlManager, UrlTranslator, reactLinker, CoreMap, UrlTranslatorSettingsConfig } from '@searchspring/snap-url-manager'; -import { EventManager } from '@searchspring/snap-event-manager'; -import { Profiler } from '@searchspring/snap-profiler'; -import { Logger } from '@searchspring/snap-logger'; -import { Tracker } from '@searchspring/snap-tracker'; +import { Client } from '@athoscommerce/snap-client'; +import { SearchStore } from '@athoscommerce/snap-store-mobx'; +import { UrlManager, UrlTranslator, reactLinker, CoreMap, UrlTranslatorSettingsConfig } from '@athoscommerce/snap-url-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; +import { Profiler } from '@athoscommerce/snap-profiler'; +import { Logger } from '@athoscommerce/snap-logger'; +import { Tracker } from '@athoscommerce/snap-tracker'; import { createSearchController } from './index'; import type { SnapSearchControllerConfig } from '../types'; -import type { UrlTranslatorConfig } from '@searchspring/snap-url-manager'; +import type { UrlTranslatorConfig } from '@athoscommerce/snap-url-manager'; const createConfig: SnapSearchControllerConfig = { client: { @@ -39,7 +39,7 @@ const createConfig: SnapSearchControllerConfig = { describe('createSearchController', () => { beforeEach(() => { - delete window.searchspring; + delete window.athos; }); it('throws when incomplete configuration is used', () => { diff --git a/packages/snap-preact/src/create/createSearchController.ts b/packages/snap-preact/src/create/createSearchController.ts index c524939753..9e369f3ef0 100644 --- a/packages/snap-preact/src/create/createSearchController.ts +++ b/packages/snap-preact/src/create/createSearchController.ts @@ -1,11 +1,11 @@ -import { SearchController } from '@searchspring/snap-controller'; -import { Client } from '@searchspring/snap-client'; -import { SearchStore } from '@searchspring/snap-store-mobx'; -import { UrlManager, UrlTranslator, reactLinker } from '@searchspring/snap-url-manager'; -import { EventManager } from '@searchspring/snap-event-manager'; -import { Profiler } from '@searchspring/snap-profiler'; -import { Logger } from '@searchspring/snap-logger'; -import { Tracker } from '@searchspring/snap-tracker'; +import { SearchController } from '@athoscommerce/snap-controller'; +import { Client } from '@athoscommerce/snap-client'; +import { SearchStore } from '@athoscommerce/snap-store-mobx'; +import { UrlManager, UrlTranslator, reactLinker } from '@athoscommerce/snap-url-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; +import { Profiler } from '@athoscommerce/snap-profiler'; +import { Logger } from '@athoscommerce/snap-logger'; +import { Tracker } from '@athoscommerce/snap-tracker'; import type { SnapControllerServices, SnapSearchControllerConfig } from '../types'; diff --git a/packages/snap-preact/src/getBundleDetails/getBundleDetails.test.ts b/packages/snap-preact/src/getBundleDetails/getBundleDetails.test.ts index 7a3890f436..5bd1f63afd 100644 --- a/packages/snap-preact/src/getBundleDetails/getBundleDetails.test.ts +++ b/packages/snap-preact/src/getBundleDetails/getBundleDetails.test.ts @@ -23,7 +23,7 @@ describe('getBundleDetails function', () => { afterAll(() => jest.clearAllMocks); it('fetches bundle details from requested bundle URL', () => { - const url = 'https://snapui.searchspring.io/siteId/next/bundle.js'; + const url = 'https://snapui.athoscommerce.io/siteId/next/bundle.js'; const fetchPromise = getBundleDetails(url).then((details) => { expect(details.lastModified).toBe('07 Jan 2022 22:42:39 GMT'); @@ -37,7 +37,7 @@ describe('getBundleDetails function', () => { }); it('rejects when bundle is not found', async () => { - const url = 'https://snapui.searchspring.io/siteId/dne/bundle.js'; + const url = 'https://snapui.athoscommerce.io/siteId/dne/bundle.js'; // @ts-ignore xhrMock.status = 403; diff --git a/packages/snap-preact/src/getInitialUrlState/getInitialUrlState.test.ts b/packages/snap-preact/src/getInitialUrlState/getInitialUrlState.test.ts index aae6f790ee..04acce4f9a 100644 --- a/packages/snap-preact/src/getInitialUrlState/getInitialUrlState.test.ts +++ b/packages/snap-preact/src/getInitialUrlState/getInitialUrlState.test.ts @@ -1,5 +1,5 @@ import { getInitialUrlState } from './getInitialUrlState'; -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; import { InitialUrlConfig } from '../types'; describe('getInitialUrlState function', () => { diff --git a/packages/snap-preact/src/getInitialUrlState/getInitialUrlState.ts b/packages/snap-preact/src/getInitialUrlState/getInitialUrlState.ts index 674e3dc86f..902e96071c 100644 --- a/packages/snap-preact/src/getInitialUrlState/getInitialUrlState.ts +++ b/packages/snap-preact/src/getInitialUrlState/getInitialUrlState.ts @@ -1,4 +1,4 @@ -import type { UrlManager } from '@searchspring/snap-url-manager'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; import { InitialUrlConfig } from '../types'; const VALID_ACTIONS = ['merge', 'set']; diff --git a/packages/snap-preact/src/integration.test.tsx b/packages/snap-preact/src/integration.test.tsx index 7c448431f0..36ecd43f5b 100644 --- a/packages/snap-preact/src/integration.test.tsx +++ b/packages/snap-preact/src/integration.test.tsx @@ -3,7 +3,7 @@ import 'whatwg-fetch'; import '@testing-library/jest-dom'; import { cleanup, waitFor } from '@testing-library/preact'; -import { cookies } from '@searchspring/snap-toolbox'; +import { cookies } from '@athoscommerce/snap-toolbox'; import { Snap, SnapConfig, DEV_COOKIE, BRANCH_PARAM, BRANCH_COOKIE } from './Snap'; import { SHOPIFY_WEBPIXEL_STORAGE_KEY } from './utils/configureSnapFeatures/configureSnapFeatures'; @@ -57,7 +57,7 @@ describe('Snap Preact Integration', () => { }; const contextString = `config = ${JSON.stringify(context.config)}; shopper = ${JSON.stringify(context.shopper)};`; - document.body.innerHTML = ``; + document.body.innerHTML = ``; }); afterEach(cleanup); @@ -73,13 +73,13 @@ describe('Snap Preact Integration', () => { expect(snap.client.mode).toBe('production'); }); - it(`automatically grabs context from #searchspring-context using 'getContext'`, () => { + it(`automatically grabs context from #athos-context using 'getContext'`, () => { const snap = new Snap(baseConfig); expect(snap.context).toStrictEqual(context); }); - it(`merges context from #searchspring-context with context in the config and the context takes priority`, () => { + it(`merges context from #athos-context with context in the config and the context takes priority`, () => { const contextConfig = { ...baseConfig, context: { @@ -102,7 +102,7 @@ describe('Snap Preact Integration', () => { }; const contextString = `config = ${JSON.stringify(config)}; shopper = ${JSON.stringify(context.shopper)};`; - document.body.innerHTML = ``; + document.body.innerHTML = ``; const snap = new Snap(baseConfig); @@ -119,7 +119,7 @@ describe('Snap Preact Integration', () => { }; const contextString = `config = ${JSON.stringify(config)}; shopper = ${JSON.stringify(context.shopper)};`; - document.body.innerHTML = ``; + document.body.innerHTML = ``; const snap = new Snap(baseConfig); diff --git a/packages/snap-preact/src/setupEvents.test.tsx b/packages/snap-preact/src/setupEvents.test.tsx index 19b462cce7..7e839b30dd 100644 --- a/packages/snap-preact/src/setupEvents.test.tsx +++ b/packages/snap-preact/src/setupEvents.test.tsx @@ -1,6 +1,6 @@ import { h } from 'preact'; import '@testing-library/jest-dom'; -import { EventManager } from '@searchspring/snap-event-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; import { setupEvents } from './setupEvents'; describe('setupEvents', () => { @@ -14,7 +14,7 @@ describe('setupEvents', () => { beforeAll(() => { eventManager = setupEvents(); - window.searchspring = { + window.athos = { controller: { search: { search: makeSearchSpy, diff --git a/packages/snap-preact/src/setupEvents.ts b/packages/snap-preact/src/setupEvents.ts index 1bed2c9b9e..d19cf14b0f 100644 --- a/packages/snap-preact/src/setupEvents.ts +++ b/packages/snap-preact/src/setupEvents.ts @@ -1,6 +1,6 @@ -import { AbstractController } from '@searchspring/snap-controller'; -import { EventManager, Next } from '@searchspring/snap-event-manager'; -import { Product, SearchStore } from '@searchspring/snap-store-mobx'; +import { AbstractController } from '@athoscommerce/snap-controller'; +import { EventManager, Next } from '@athoscommerce/snap-event-manager'; +import { Product, SearchStore } from '@athoscommerce/snap-store-mobx'; type ControllerSelectVariantOptionsData = { options: Record; @@ -53,8 +53,8 @@ export const setupEvents = () => { }; const matchControllers = (matchIds: (string | RegExp)[] | undefined): AbstractController[] => { - return Object.keys(window.searchspring.controller || {}).reduce((arr, id) => { - const controller = window.searchspring.controller[id] as AbstractController; + return Object.keys(window.athos.controller || {}).reduce((arr, id) => { + const controller = window.athos.controller[id] as AbstractController; if (!matchIds) { arr.push(controller); diff --git a/packages/snap-preact/src/types.ts b/packages/snap-preact/src/types.ts index 8a7b8d1bbe..5bacad1bb3 100644 --- a/packages/snap-preact/src/types.ts +++ b/packages/snap-preact/src/types.ts @@ -1,4 +1,4 @@ -import type { Client, ClientConfig, ClientGlobals } from '@searchspring/snap-client'; +import type { Client, ClientConfig, ClientGlobals } from '@athoscommerce/snap-client'; import type { ControllerConfig, SearchControllerConfig, @@ -6,16 +6,16 @@ import type { FinderControllerConfig, RecommendationControllerConfig, ContextVariables, -} from '@searchspring/snap-controller'; -import type { SearchStore, AutocompleteStore, FinderStore, RecommendationStore } from '@searchspring/snap-store-mobx'; -import type { UrlManager, UrlTranslatorConfig, UrlState } from '@searchspring/snap-url-manager'; -import type { EventManager } from '@searchspring/snap-event-manager'; -import type { Profiler } from '@searchspring/snap-profiler'; -import type { Logger } from '@searchspring/snap-logger'; -import type { Tracker } from '@searchspring/snap-tracker'; +} from '@athoscommerce/snap-controller'; +import type { SearchStore, AutocompleteStore, FinderStore, RecommendationStore } from '@athoscommerce/snap-store-mobx'; +import type { UrlManager, UrlTranslatorConfig, UrlState } from '@athoscommerce/snap-url-manager'; +import type { EventManager } from '@athoscommerce/snap-event-manager'; +import type { Profiler } from '@athoscommerce/snap-profiler'; +import type { Logger } from '@athoscommerce/snap-logger'; +import type { Tracker } from '@athoscommerce/snap-tracker'; import type { CSSInterpolation } from '@emotion/serialize'; import type { ThemeVariables } from '../components/src'; -import { AppMode } from '@searchspring/snap-toolbox'; +import { AppMode } from '@athoscommerce/snap-toolbox'; export type IntegrationPlatforms = 'shopify' | 'bigCommerce' | 'magento2' | 'other'; @@ -110,6 +110,7 @@ export type DeepPartial = Partial<{ [P in keyof T]: DeepPartial }>; declare global { interface Window { searchspring?: any; + athos?: any; } } diff --git a/packages/snap-preact/src/utils/configureSnapFeatures/configureSnapFeatures.ts b/packages/snap-preact/src/utils/configureSnapFeatures/configureSnapFeatures.ts index 06ddba0b28..34d213379b 100644 --- a/packages/snap-preact/src/utils/configureSnapFeatures/configureSnapFeatures.ts +++ b/packages/snap-preact/src/utils/configureSnapFeatures/configureSnapFeatures.ts @@ -1,5 +1,5 @@ import deepmerge from 'deepmerge'; -import type { TrackerEvents } from '@searchspring/snap-tracker'; +import type { TrackerEvents } from '@athoscommerce/snap-tracker'; import type { SnapConfig } from '../../Snap'; export const SHOPIFY_WEBPIXEL_STORAGE_KEY = 'ssWebPixel'; @@ -62,7 +62,7 @@ export function configureIntegratedSpellCorrection(config: SnapConfig) { } function configureTracking(config: SnapConfig) { - // Searchspring's Shopify Web Pixel App compatibility + // Athos' Shopify Web Pixel App compatibility let webPixel; try { webPixel = window.sessionStorage?.getItem(SHOPIFY_WEBPIXEL_STORAGE_KEY); diff --git a/packages/snap-preact/toolbox/src/index.ts b/packages/snap-preact/toolbox/src/index.ts index 9f4653b2a8..fac98f7de3 100644 --- a/packages/snap-preact/toolbox/src/index.ts +++ b/packages/snap-preact/toolbox/src/index.ts @@ -1,3 +1,3 @@ -export * from '@searchspring/snap-toolbox'; +export * from '@athoscommerce/snap-toolbox'; // future toolbox things for preact only diff --git a/packages/snap-profiler/package.json b/packages/snap-profiler/package.json index 38e109fb67..f0b9aa5d69 100644 --- a/packages/snap-profiler/package.json +++ b/packages/snap-profiler/package.json @@ -1,10 +1,10 @@ { - "name": "@searchspring/snap-profiler", + "name": "@athoscommerce/snap-profiler", "version": "1.11.0", "description": "Snap Profiler", "main": "dist/cjs/index.js", "module": "dist/esm/index.js", - "author": "Searchspring", + "author": "Athos Commerce", "license": "MIT", "repository": "https://github.com/searchspring/snap", "publishConfig": { diff --git a/packages/snap-shared/package.json b/packages/snap-shared/package.json index 3bed5bb6be..c7e12b1d1d 100644 --- a/packages/snap-shared/package.json +++ b/packages/snap-shared/package.json @@ -1,9 +1,9 @@ { - "name": "@searchspring/snap-shared", + "name": "@athoscommerce/snap-shared", "private": true, "version": "1.11.0", "description": "library of shared code utilized by snap packages", - "author": "Searchspring", + "author": "Athos Commerce", "license": "MIT", "scripts": { "build": "rm -rf ./dist && tsc && tsc -p tsconfig.cjs.json", @@ -15,7 +15,7 @@ "test:watch": "jest --watch" }, "devDependencies": { - "@searchspring/snap-client": "1.11.0" + "@athoscommerce/snap-client": "1.11.0" }, "sideEffects": false, "files": [ diff --git a/packages/snap-shared/src/MockClient/MockClient.ts b/packages/snap-shared/src/MockClient/MockClient.ts index a0caeaf80a..0d324404ba 100644 --- a/packages/snap-shared/src/MockClient/MockClient.ts +++ b/packages/snap-shared/src/MockClient/MockClient.ts @@ -1,5 +1,5 @@ import type { MetaResponseModel, SearchResponseModel, AutocompleteResponseModel } from '@athoscommerce/snapi-types'; -import { Client, ClientGlobals, ClientConfig, TrendingResponseModel } from '@searchspring/snap-client'; +import { Client, ClientGlobals, ClientConfig, TrendingResponseModel } from '@athoscommerce/snap-client'; import { MockData } from '../MockData/MockData'; /* diff --git a/packages/snap-shared/src/MockData/MockData.ts b/packages/snap-shared/src/MockData/MockData.ts index 51c35ccc8a..f12a9ad5d0 100644 --- a/packages/snap-shared/src/MockData/MockData.ts +++ b/packages/snap-shared/src/MockData/MockData.ts @@ -11,6 +11,7 @@ import * as fs from 'fs'; import deepmerge from 'deepmerge'; import type { MetaResponseModel, SearchResponseModel, AutocompleteResponseModel } from '@athoscommerce/snapi-types'; +import { RecommendCombinedResponseModel } from '@athoscommerce/snap-client'; type MockDataConfig = { siteId?: string; @@ -117,14 +118,14 @@ export class MockData { } } - recommend(files?: { profileFile?: string; resultsFile?: string }) { + recommend(files?: { profileFile?: string; resultsFile?: string }): RecommendCombinedResponseModel { const profileFile = `${__dirname}/recommend/profile/${this.config.siteId}/${files?.profileFile || this.config.recommend?.profile}.json`; const resultsFile = `${__dirname}/recommend/results/${this.config.siteId}/${files?.resultsFile || this.config.recommend?.results}.json`; try { return { meta: this.meta(), profile: getJSON(profileFile), - recommend: getJSON(resultsFile)[0], + results: getJSON(resultsFile)[0], }; } catch (err) { throw `Recommend JSON not found. Profile: '${profileFile}', Results: '${resultsFile}'`; diff --git a/packages/snap-store-mobx/README.md b/packages/snap-store-mobx/README.md index 92e8544883..0ce7c443cc 100644 --- a/packages/snap-store-mobx/README.md +++ b/packages/snap-store-mobx/README.md @@ -2,7 +2,7 @@ Management of Snap state using Mobx. -Although `@searchspring/snap-store-mobx` is published as a standalone package, it is not intended to be used directly. Internally it is a dependency of the `@searchspring/snap-preact` package. +Although `@athoscommerce/snap-store-mobx` is published as a standalone package, it is not intended to be used directly. Internally it is a dependency of the `@athoscommerce/snap-preact` package. Each controller will have a store as a property. For example, the `SearchController` will have a `store` property that is an instance of the `SearchStore`. diff --git a/packages/snap-store-mobx/package.json b/packages/snap-store-mobx/package.json index 18fec6f11b..022d2a3007 100644 --- a/packages/snap-store-mobx/package.json +++ b/packages/snap-store-mobx/package.json @@ -1,10 +1,10 @@ { - "name": "@searchspring/snap-store-mobx", + "name": "@athoscommerce/snap-store-mobx", "version": "1.11.0", "description": "Snap MobX Store", "main": "dist/cjs/index.js", "module": "dist/esm/index.js", - "author": "Searchspring", + "author": "Athos Commerce", "license": "MIT", "repository": "https://github.com/searchspring/snap", "publishConfig": { @@ -20,13 +20,13 @@ "test:watch": "jest --watch" }, "dependencies": { - "@searchspring/snap-toolbox": "1.11.0", + "@athoscommerce/snap-toolbox": "1.11.0", "mobx": "6.9.0" }, "devDependencies": { - "@searchspring/snap-client": "1.11.0", - "@searchspring/snap-url-manager": "1.11.0", - "@searchspring/snap-toolbox": "1.11.0", + "@athoscommerce/snap-client": "1.11.0", + "@athoscommerce/snap-url-manager": "1.11.0", + "@athoscommerce/snap-toolbox": "1.11.0", "mobx": "6.9.0" }, "sideEffects": false, diff --git a/packages/snap-store-mobx/src/Abstract/README.md b/packages/snap-store-mobx/src/Abstract/README.md index 2727e969ed..fabc4b7660 100644 --- a/packages/snap-store-mobx/src/Abstract/README.md +++ b/packages/snap-store-mobx/src/Abstract/README.md @@ -3,7 +3,7 @@ `SearchStore`, `AutocompleteStore`, and `FinderStore` extend `AbstractStore`. Therefore, the following methods and properties are available in all Stores. ## `update` method -Update the store's properties with `data` object that has been retrieved from Searchspring's Search API. +Update the store's properties with `data` object that has been retrieved from Athos' Search API. ```js const store = new SearchStore(); diff --git a/packages/snap-store-mobx/src/Autocomplete/AutocompleteStore.test.ts b/packages/snap-store-mobx/src/Autocomplete/AutocompleteStore.test.ts index 6398e6d30c..b03e0e1e1f 100644 --- a/packages/snap-store-mobx/src/Autocomplete/AutocompleteStore.test.ts +++ b/packages/snap-store-mobx/src/Autocomplete/AutocompleteStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { AutocompleteStore } from './AutocompleteStore'; import { AutocompleteResponseModel, MetaResponseModel, MetaResponseModelFacetDefaults } from '@athoscommerce/snapi-types'; @@ -152,7 +152,7 @@ describe('Autocomplete Store', () => { global.Storage.prototype.getItem = jest.fn((key) => mockStorage[key]); const historyData = ['dress', 'sleep', 'shirt', 'sandal', 'shoes']; - global.localStorage.setItem(`ss-history`, JSON.stringify({ history: JSON.stringify(historyData) })); + global.localStorage.setItem(`athos-history`, JSON.stringify({ history: JSON.stringify(historyData) })); const autocompleteStore = new AutocompleteStore(autocompleteConfig, services); autocompleteStore.update(searchData); diff --git a/packages/snap-store-mobx/src/Autocomplete/AutocompleteStore.ts b/packages/snap-store-mobx/src/Autocomplete/AutocompleteStore.ts index bfaa21bb4b..da5d277e7c 100644 --- a/packages/snap-store-mobx/src/Autocomplete/AutocompleteStore.ts +++ b/packages/snap-store-mobx/src/Autocomplete/AutocompleteStore.ts @@ -1,6 +1,6 @@ import { makeObservable, observable } from 'mobx'; -import { UrlManager } from '@searchspring/snap-url-manager'; +import { UrlManager } from '@athoscommerce/snap-url-manager'; import { AbstractStore } from '../Abstract/AbstractStore'; import { SearchFilterStore, @@ -21,7 +21,7 @@ import { } from './Stores'; import type { AutocompleteResponseModel, MetaResponseModel } from '@athoscommerce/snapi-types'; -import type { TrendingResponseModel } from '@searchspring/snap-client'; +import type { TrendingResponseModel } from '@athoscommerce/snap-client'; import type { AutocompleteStoreConfig, StoreServices } from '../types'; import { MetaStore } from '../Meta/MetaStore'; diff --git a/packages/snap-store-mobx/src/Autocomplete/README.md b/packages/snap-store-mobx/src/Autocomplete/README.md index 30d25d2c9d..a1093d98da 100644 --- a/packages/snap-store-mobx/src/Autocomplete/README.md +++ b/packages/snap-store-mobx/src/Autocomplete/README.md @@ -2,8 +2,8 @@ The autocomplete store is meant to hold the suggest and search API response and associated state. It extends the AbstractStore and the recommend response by adding several additional properties and methods to make working with the data easier. ```js -import { AutocompleteStore } from '@searchspring/snap-store-mobx' -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; +import { AutocompleteStore } from '@athoscommerce/snap-store-mobx' +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; const autocompleteConfig = { id: 'autocomplete', @@ -41,7 +41,7 @@ Sets all term suggestions to inactive Sets all trending term suggestions to inactive ## `meta` property -The meta property is an object containing the meta data retrieved from the Searchspring Meta API +The meta property is an object containing the meta data retrieved from the Athos Meta API ## `state` property Contains autocomplete lock state diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteFacetStore.test.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteFacetStore.test.ts index 419d4f124d..e6c4bdf62b 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteFacetStore.test.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteFacetStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { AutocompleteFacetStore } from './AutocompleteFacetStore'; import { AutocompleteStateStore } from './AutocompleteStateStore'; diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteHistoryStore.test.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteHistoryStore.test.ts index 953dee87be..39472b5d0d 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteHistoryStore.test.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteHistoryStore.test.ts @@ -1,4 +1,4 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; import { AutocompleteHistoryStore } from './AutocompleteHistoryStore'; import { AutocompleteStateStore } from '../../Autocomplete/Stores/AutocompleteStateStore'; diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteQueryStore.test.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteQueryStore.test.ts index 428c285aca..f369013c10 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteQueryStore.test.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteQueryStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { AutocompleteQueryStore } from './AutocompleteQueryStore'; @@ -9,7 +9,7 @@ const services = { let config = { id: 'autocomplete', - selector: 'input.searchspring-ac', + selector: 'input.athos-ac', settings: { integratedSpellCorrection: true, }, diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteQueryStore.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteQueryStore.ts index 544270d1f7..1bf3f2d448 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteQueryStore.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteQueryStore.ts @@ -1,5 +1,5 @@ import { observable, makeObservable } from 'mobx'; -import type { UrlManager } from '@searchspring/snap-url-manager'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; import type { SearchResponseModelSearchMatchTypeEnum } from '@athoscommerce/snapi-types'; import type { AutocompleteStoreConfig, StoreServices } from '../../types'; import { AutocompleteResponseModel } from '@athoscommerce/snapi-types'; diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteStateStore.test.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteStateStore.test.ts index aa337e2349..f6a9ac1037 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteStateStore.test.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteStateStore.test.ts @@ -1,4 +1,4 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; import { AutocompleteStateStore } from './AutocompleteStateStore'; diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteStateStore.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteStateStore.ts index 50f97e859c..50d4f474bf 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteStateStore.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteStateStore.ts @@ -1,5 +1,5 @@ import { observable, action, makeObservable } from 'mobx'; -import type { UrlManager } from '@searchspring/snap-url-manager'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; import type { StoreServices } from '../../types'; type AutocompleteStateStoreConfig = { diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTermStore.test.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTermStore.test.ts index 0b61b2a146..ed84aedc9e 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTermStore.test.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTermStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { AutocompleteTermStore } from './AutocompleteTermStore'; import { AutocompleteStateStore } from './AutocompleteStateStore'; @@ -12,7 +12,7 @@ const services = { let config = { id: 'autocomplete', - selector: 'input.searchspring-ac', + selector: 'input.athos-ac', settings: { integratedSpellCorrection: true, }, diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTermStore.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTermStore.ts index e0eb362e5e..98167d7d6c 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTermStore.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTermStore.ts @@ -1,5 +1,5 @@ import { observable, makeObservable } from 'mobx'; -import type { UrlManager } from '@searchspring/snap-url-manager'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; import type { AutocompleteStoreConfig, StoreServices } from '../../types'; import { AutocompleteStateStore } from './AutocompleteStateStore'; import { AutocompleteResponseModel } from '@athoscommerce/snapi-types'; diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTrendingStore.test.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTrendingStore.test.ts index b5586614d7..421c1732e8 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTrendingStore.test.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTrendingStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { AutocompleteTrendingStore } from './AutocompleteTrendingStore'; import { AutocompleteStateStore } from './AutocompleteStateStore'; diff --git a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTrendingStore.ts b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTrendingStore.ts index bc5dab55c8..b6c3a899c2 100644 --- a/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTrendingStore.ts +++ b/packages/snap-store-mobx/src/Autocomplete/Stores/AutocompleteTrendingStore.ts @@ -1,4 +1,4 @@ -import { TrendingResponseModel } from '@searchspring/snap-client'; +import { TrendingResponseModel } from '@athoscommerce/snap-client'; import { Term, TermData } from './AutocompleteTermStore'; type AutocompleteTrendingStoreConfig = Omit & { diff --git a/packages/snap-store-mobx/src/Cart/CartStore.test.ts b/packages/snap-store-mobx/src/Cart/CartStore.test.ts index 74a050f256..2c4090faae 100644 --- a/packages/snap-store-mobx/src/Cart/CartStore.test.ts +++ b/packages/snap-store-mobx/src/Cart/CartStore.test.ts @@ -1,4 +1,4 @@ -import { MockData } from '@searchspring/snap-shared'; +import { MockData } from '@athoscommerce/snap-shared'; import { CartStore } from './CartStore'; import { Product, SearchResultStore } from '../Search/Stores/SearchResultStore'; diff --git a/packages/snap-store-mobx/src/Cart/CartStore.ts b/packages/snap-store-mobx/src/Cart/CartStore.ts index 8e079fa96b..cb75a5811b 100644 --- a/packages/snap-store-mobx/src/Cart/CartStore.ts +++ b/packages/snap-store-mobx/src/Cart/CartStore.ts @@ -1,6 +1,6 @@ import { observable, computed, makeObservable } from 'mobx'; -import { EventManager } from '@searchspring/snap-event-manager'; -import type { Middleware } from '@searchspring/snap-event-manager'; +import { EventManager } from '@athoscommerce/snap-event-manager'; +import type { Middleware } from '@athoscommerce/snap-event-manager'; import type { Product } from '../Search/Stores'; export class CartStore { diff --git a/packages/snap-store-mobx/src/Finder/FinderStore.test.ts b/packages/snap-store-mobx/src/Finder/FinderStore.test.ts index 584590434c..b9ccd8719a 100644 --- a/packages/snap-store-mobx/src/Finder/FinderStore.test.ts +++ b/packages/snap-store-mobx/src/Finder/FinderStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { FinderStore } from './FinderStore'; import { FinderStoreConfig } from '../types'; diff --git a/packages/snap-store-mobx/src/Finder/FinderStore.ts b/packages/snap-store-mobx/src/Finder/FinderStore.ts index fdb4b091bc..9da6fd38c5 100644 --- a/packages/snap-store-mobx/src/Finder/FinderStore.ts +++ b/packages/snap-store-mobx/src/Finder/FinderStore.ts @@ -6,7 +6,7 @@ import { SearchPaginationStore } from '../Search/Stores'; import { StorageStore } from '../Storage/StorageStore'; import { FinderSelectionStore } from './Stores'; import type { FinderStoreConfig, StoreServices, SelectedSelection } from '../types'; -import { UrlManager } from '@searchspring/snap-url-manager'; +import { UrlManager } from '@athoscommerce/snap-url-manager'; import { MetaStore } from '../Meta/MetaStore'; export class FinderStore extends AbstractStore { @@ -30,7 +30,7 @@ export class FinderStore extends AbstractStore { if (this.config.persist?.enabled) { this.persistedStorage = new StorageStore({ type: 'local', - key: `ss-${this.config.id}-persisted`, + key: `athos-${this.config.id}-persisted`, }); } diff --git a/packages/snap-store-mobx/src/Finder/README.md b/packages/snap-store-mobx/src/Finder/README.md index d709ae5903..ed02ef050c 100644 --- a/packages/snap-store-mobx/src/Finder/README.md +++ b/packages/snap-store-mobx/src/Finder/README.md @@ -2,8 +2,8 @@ The finder store is meant to hold the API response and associated selection state. It extends the AbstractStore and the search response by adding several additional properties and methods to make working with the data easier. ```js -import { FinderStore, FinderStoreConfig } from '@searchspring/snap-store-mobx' -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; +import { FinderStore, FinderStoreConfig } from '@athoscommerce/snap-store-mobx' +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; const finderConfig: FinderStoreConfig = { id: 'finder', @@ -26,7 +26,7 @@ console.log(store.toJSON()); ``` ## `meta` property -The meta property is an object containing the meta data retrieved from the Searchspring Meta API +The meta property is an object containing the meta data retrieved from the Athos Meta API ## `pagination` property See [SearchStore](https://github.com/searchspring/snap/tree/main/packages/snap-store-mobx/src/Search) `pagination` property diff --git a/packages/snap-store-mobx/src/Finder/Stores/FinderSelectionStore.test.ts b/packages/snap-store-mobx/src/Finder/Stores/FinderSelectionStore.test.ts index e110b3707f..dc77610488 100644 --- a/packages/snap-store-mobx/src/Finder/Stores/FinderSelectionStore.test.ts +++ b/packages/snap-store-mobx/src/Finder/Stores/FinderSelectionStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { FinderSelectionStore } from './FinderSelectionStore'; import { StorageStore } from '../../Storage/StorageStore'; diff --git a/packages/snap-store-mobx/src/Meta/MetaStore.test.ts b/packages/snap-store-mobx/src/Meta/MetaStore.test.ts index d278103491..1751b40af0 100644 --- a/packages/snap-store-mobx/src/Meta/MetaStore.test.ts +++ b/packages/snap-store-mobx/src/Meta/MetaStore.test.ts @@ -1,4 +1,4 @@ -import { MockData } from '@searchspring/snap-shared'; +import { MockData } from '@athoscommerce/snap-shared'; import { MetaStore } from './MetaStore'; diff --git a/packages/snap-store-mobx/src/Meta/README.md b/packages/snap-store-mobx/src/Meta/README.md index a240f97e6f..1e485abec5 100644 --- a/packages/snap-store-mobx/src/Meta/README.md +++ b/packages/snap-store-mobx/src/Meta/README.md @@ -1,6 +1,6 @@ # MetaStore -The `MetaStore` contains the response from the Searchspring meta API which includes information about site configuration and feature settings. A `MetaStore` can be found on each root store's `meta` property. These include: +The `MetaStore` contains the response from the Athos meta API which includes information about site configuration and feature settings. A `MetaStore` can be found on each root store's `meta` property. These include: - [SearchStore](https://github.com/searchspring/snap/tree/main/packages/snap-store-mobx/src/Search) - [AutocompleteStore](https://github.com/searchspring/snap/tree/main/packages/snap-store-mobx/src/Autocomplete) diff --git a/packages/snap-store-mobx/src/Recommendation/README.md b/packages/snap-store-mobx/src/Recommendation/README.md index 8a4963704e..ad28aaefab 100644 --- a/packages/snap-store-mobx/src/Recommendation/README.md +++ b/packages/snap-store-mobx/src/Recommendation/README.md @@ -2,8 +2,8 @@ The recommendation store is meant to hold the recommend and profile API response and associated state. It extends the AbstractStore and the recommend response by adding several additional properties and methods to make working with the data easier. ```js -import { RecommendationStore } from '@searchspring/snap-store-mobx' -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; +import { RecommendationStore } from '@athoscommerce/snap-store-mobx' +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; const recommendationConfig = { id: 'recommendation', @@ -30,9 +30,9 @@ store.reset() ## `profile` property Contains an object with the following properties: -`tag` - the profile unique tag (set in SMC) +`tag` - the profile unique tag (set in ASD) -`placement` - location of the profile on a site (set in SMC) +`placement` - location of the profile on a site (set in ASD) `display` - object containing details regarding the template and any template parameters ## `results` property diff --git a/packages/snap-store-mobx/src/Recommendation/RecommendationStore.test.ts b/packages/snap-store-mobx/src/Recommendation/RecommendationStore.test.ts index 90b42a574c..f829a7c5a1 100644 --- a/packages/snap-store-mobx/src/Recommendation/RecommendationStore.test.ts +++ b/packages/snap-store-mobx/src/Recommendation/RecommendationStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { RecommendationStore } from './RecommendationStore'; diff --git a/packages/snap-store-mobx/src/Recommendation/RecommendationStore.ts b/packages/snap-store-mobx/src/Recommendation/RecommendationStore.ts index 8c632b9eed..11fc81d78a 100644 --- a/packages/snap-store-mobx/src/Recommendation/RecommendationStore.ts +++ b/packages/snap-store-mobx/src/Recommendation/RecommendationStore.ts @@ -5,7 +5,7 @@ import { Product, SearchResultStore } from '../Search/Stores'; import { CartStore } from '../Cart/CartStore'; import { RecommendationProfileStore } from './Stores'; import type { RecommendationStoreConfig, StoreServices } from '../types'; -import type { ProfileResponseModel, RecommendResponseModel } from '@searchspring/snap-client'; +import type { ProfileResponseModel, RecommendResponseModel } from '@athoscommerce/snap-client'; import { MetaResponseModel } from '@athoscommerce/snapi-types'; import { MetaStore } from '../Meta/MetaStore'; diff --git a/packages/snap-store-mobx/src/Recommendation/Stores/RecommendationProfileStore.test.ts b/packages/snap-store-mobx/src/Recommendation/Stores/RecommendationProfileStore.test.ts index 683841e003..822395a82e 100644 --- a/packages/snap-store-mobx/src/Recommendation/Stores/RecommendationProfileStore.test.ts +++ b/packages/snap-store-mobx/src/Recommendation/Stores/RecommendationProfileStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { RecommendationProfileStore } from './RecommendationProfileStore'; diff --git a/packages/snap-store-mobx/src/Recommendation/Stores/RecommendationProfileStore.ts b/packages/snap-store-mobx/src/Recommendation/Stores/RecommendationProfileStore.ts index f910cb8bcc..13b09203ea 100644 --- a/packages/snap-store-mobx/src/Recommendation/Stores/RecommendationProfileStore.ts +++ b/packages/snap-store-mobx/src/Recommendation/Stores/RecommendationProfileStore.ts @@ -1,5 +1,5 @@ import { observable, makeObservable } from 'mobx'; -import type { ProfileResponseModel } from '@searchspring/snap-client'; +import type { ProfileResponseModel } from '@athoscommerce/snap-client'; type RecommendationProfileStoreConfig = { data: { diff --git a/packages/snap-store-mobx/src/Search/README.md b/packages/snap-store-mobx/src/Search/README.md index 44a75ab589..1ac41e1cb9 100644 --- a/packages/snap-store-mobx/src/Search/README.md +++ b/packages/snap-store-mobx/src/Search/README.md @@ -2,7 +2,7 @@ The search store is meant to hold the search API response and associated state. It extends the AbstractStore and the search response by adding several additional properties and methods to make working with the data easier. ## `meta` property -The meta property is an object containing the meta data retrieved from the Searchspring Meta API. The majority of this data is used elsewhere in constructing other SearchStore data like 'sorting' and 'facets'. +The meta property is an object containing the meta data retrieved from the Athos Meta API. The majority of this data is used elsewhere in constructing other SearchStore data like 'sorting' and 'facets'. ## `merchandising` property @@ -135,11 +135,11 @@ cntrlr.on('afterStore', async ({ controller }, next) => { ### `collapse` property -Collapse state that will contain an initial state that can be defined in the Searchspring Management Console, or toggled programmatically using `toggleCollapse()`. +Collapse state that will contain an initial state that can be defined in the Athos Search & Product Discovery Console, or toggled programmatically using `toggleCollapse()`. ### `display` property -Contains the facet display type as configured in the Searchspring Management Console. +Contains the facet display type as configured in the Athos Search & Product Discovery Console. ```js enum FacetDisplay { @@ -152,7 +152,7 @@ enum FacetDisplay { ``` ### `label` property -Contains the facet label as configured in the Searchspring Management Console. +Contains the facet label as configured in the Athos Search & Product Discovery Console. ### `storage` property This is a reference to the `StorageStore` instance that is used to store the current facet state for `collapse` and `overflow`; this preserves these states as additional API queries are made (think faceting, pagination, etc...). The `SearchStore` automatically manages this stored state. @@ -182,7 +182,7 @@ Contains an object with `low` and `high` properties. This represents the current ### `formatSeparator` property Only applicable to facets where `type` is `range`. -The text to separate `min` and `max` values. Typically set to `-` and is configured in the Searchspring Management Console. +The text to separate `min` and `max` values. Typically set to `-` and is configured in the Athos Search & Product Discovery Console. ### `formatValue` property @@ -190,7 +190,7 @@ Only applicable to facets where `type` is `range`. A [printf format string](https://en.wikipedia.org/wiki/Printf_format_string) for how to format numerical values. -Configurable in the Searchspring Management Console and typically set to `$%01.2f`. +Configurable in the Athos Search & Product Discovery Console and typically set to `$%01.2f`. For example, `9.99` with a formateValue of `$%01.2f` will be formatted to `$9.99`. @@ -218,7 +218,7 @@ Typical usage is to use this with a search input for each facet, allowing a user Only applicable to facets where `type` is `value` or `range-buckets` -Facet `multiple` can be configured per facet in the Searchspring Management Console to the following values: +Facet `multiple` can be configured per facet in the Athos Search & Product Discovery Console to the following values: `single` - a facet can only contain a single active selection at any given time @@ -295,7 +295,7 @@ If `type` is `banner`, id will be set to `ssid-${banner.config.position.index}` ### `attributes` property Only applicable to results with `type` of `product` or `child` -Product attributes object. Will contain all attributes that have been indexed and enabled in the Searchspring Management Console +Product attributes object. Will contain all attributes that have been indexed and enabled in the Athos Search & Product Discovery Console ```json "attributes": { diff --git a/packages/snap-store-mobx/src/Search/SearchStore.test.ts b/packages/snap-store-mobx/src/Search/SearchStore.test.ts index 6c73fb4dfe..f77918ff1a 100644 --- a/packages/snap-store-mobx/src/Search/SearchStore.test.ts +++ b/packages/snap-store-mobx/src/Search/SearchStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { SearchStore } from './SearchStore'; import { SearchResponseModel, MetaResponseModel } from '@athoscommerce/snapi-types'; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchFacetStore.test.ts b/packages/snap-store-mobx/src/Search/Stores/SearchFacetStore.test.ts index ebd8ae864d..6962e7d5cd 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchFacetStore.test.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchFacetStore.test.ts @@ -1,7 +1,7 @@ import { configure } from 'mobx'; -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { SearchFacetStore, ValueFacet, FacetRangeValue, FacetValue, FacetHierarchyValue, RangeFacet } from './SearchFacetStore'; import { StorageStore } from '../../Storage/StorageStore'; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchFacetStore.ts b/packages/snap-store-mobx/src/Search/Stores/SearchFacetStore.ts index d0145ecec2..63f58ad45c 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchFacetStore.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchFacetStore.ts @@ -1,7 +1,7 @@ import deepmerge from 'deepmerge'; import { makeObservable, observable, action, computed, reaction } from 'mobx'; -import type { UrlManager } from '@searchspring/snap-url-manager'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; import type { StorageStore } from '../../Storage/StorageStore'; import type { AutocompleteStoreConfig, SearchStoreConfig, StoreServices, FacetStoreConfig } from '../../types'; import type { diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchFilterStore.test.ts b/packages/snap-store-mobx/src/Search/Stores/SearchFilterStore.test.ts index ca5b02cbe4..bd1eed0f9f 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchFilterStore.test.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchFilterStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { SearchFilterStore, RangeFilter, Filter } from './SearchFilterStore'; import { diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchFilterStore.ts b/packages/snap-store-mobx/src/Search/Stores/SearchFilterStore.ts index 748d171926..eedf22765e 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchFilterStore.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchFilterStore.ts @@ -1,6 +1,6 @@ import { makeObservable, observable } from 'mobx'; -import type { UrlManager } from '@searchspring/snap-url-manager'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; import type { AutocompleteStoreConfig, SearchStoreConfig, StoreServices } from '../../types'; import type { SearchResponseModelFilterRange, @@ -10,7 +10,7 @@ import type { SearchResponseModel, MetaResponseModel, } from '@athoscommerce/snapi-types'; -import { sprintf } from '@searchspring/snap-toolbox'; +import { sprintf } from '@athoscommerce/snap-toolbox'; type SearchFilterStoreConfig = { services: StoreServices; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchHistoryStore.test.ts b/packages/snap-store-mobx/src/Search/Stores/SearchHistoryStore.test.ts index e05ced74ed..9b034918b3 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchHistoryStore.test.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchHistoryStore.test.ts @@ -1,4 +1,4 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; import { SearchHistoryStore } from './SearchHistoryStore'; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchHistoryStore.ts b/packages/snap-store-mobx/src/Search/Stores/SearchHistoryStore.ts index 0568bc8d35..381f043f9f 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchHistoryStore.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchHistoryStore.ts @@ -31,7 +31,7 @@ export class SearchHistoryStore { this.storage = new StorageStore({ type: 'local', - key: `ss-history${this.config.globals?.siteId ? `-${this.config.globals?.siteId}` : ``}`, + key: `athos-history${this.config.globals?.siteId ? `-${this.config.globals?.siteId}` : ``}`, }); // reset to zero to clear any potentially existing terms diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchMerchandisingStore.test.ts b/packages/snap-store-mobx/src/Search/Stores/SearchMerchandisingStore.test.ts index 4b1f9d5ead..e3bfad530e 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchMerchandisingStore.test.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchMerchandisingStore.test.ts @@ -1,4 +1,4 @@ -import { MockData } from '@searchspring/snap-shared'; +import { MockData } from '@athoscommerce/snap-shared'; import { SearchMerchandisingStore } from './SearchMerchandisingStore'; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchPaginationStore.test.ts b/packages/snap-store-mobx/src/Search/Stores/SearchPaginationStore.test.ts index 2f2ef29f7f..817a8e957e 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchPaginationStore.test.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchPaginationStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { SearchPaginationStore } from './SearchPaginationStore'; import { SearchResponseModel, MetaResponseModel, MetaResponseModelFacetDefaults } from '@athoscommerce/snapi-types'; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchPaginationStore.ts b/packages/snap-store-mobx/src/Search/Stores/SearchPaginationStore.ts index b0fd7e195d..c968a3c3ea 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchPaginationStore.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchPaginationStore.ts @@ -1,7 +1,7 @@ import { observable, action, computed, makeObservable } from 'mobx'; import type { StoreServices, SearchStoreConfig } from '../../types'; -import type { UrlManager } from '@searchspring/snap-url-manager'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; import { MetaResponseModel, SearchResponseModel } from '@athoscommerce/snapi-types'; type SearchPaginationStoreConfig = { diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchQueryStore.test.ts b/packages/snap-store-mobx/src/Search/Stores/SearchQueryStore.test.ts index d36555c1c2..f63c9ef423 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchQueryStore.test.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchQueryStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { SearchQueryStore } from './SearchQueryStore'; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchQueryStore.ts b/packages/snap-store-mobx/src/Search/Stores/SearchQueryStore.ts index 322899af0a..6dbb5c6355 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchQueryStore.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchQueryStore.ts @@ -1,8 +1,8 @@ import { observable, makeObservable } from 'mobx'; -import { escapeHTML } from '@searchspring/snap-toolbox'; +import { escapeHTML } from '@athoscommerce/snap-toolbox'; -import type { UrlManager } from '@searchspring/snap-url-manager'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; import type { StoreServices } from '../../types'; import type { SearchResponseModel, SearchResponseModelSearchMatchTypeEnum } from '@athoscommerce/snapi-types'; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchResultStore.test.ts b/packages/snap-store-mobx/src/Search/Stores/SearchResultStore.test.ts index c8382ccfc4..adab7370e4 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchResultStore.test.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchResultStore.test.ts @@ -1,5 +1,5 @@ import deepmerge from 'deepmerge'; -import { MockData } from '@searchspring/snap-shared'; +import { MockData } from '@athoscommerce/snap-shared'; import { SearchResponseModelResult, SearchResponseModelResultCoreMappings } from '@athoscommerce/snapi-types'; import { Banner, Product, SearchResultStore, ProductMask, Variants, Variant, VariantSelection, VariantData, Badges } from './SearchResultStore'; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchSortingStore.test.ts b/packages/snap-store-mobx/src/Search/Stores/SearchSortingStore.test.ts index 9292bdd25f..ee4f613980 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchSortingStore.test.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchSortingStore.test.ts @@ -1,5 +1,5 @@ -import { UrlManager, UrlTranslator } from '@searchspring/snap-url-manager'; -import { MockData } from '@searchspring/snap-shared'; +import { UrlManager, UrlTranslator } from '@athoscommerce/snap-url-manager'; +import { MockData } from '@athoscommerce/snap-shared'; import { SearchSortingStore } from './SearchSortingStore'; diff --git a/packages/snap-store-mobx/src/Search/Stores/SearchSortingStore.ts b/packages/snap-store-mobx/src/Search/Stores/SearchSortingStore.ts index 204eca6e65..0d8685ee36 100644 --- a/packages/snap-store-mobx/src/Search/Stores/SearchSortingStore.ts +++ b/packages/snap-store-mobx/src/Search/Stores/SearchSortingStore.ts @@ -1,6 +1,6 @@ import { observable, computed, makeObservable } from 'mobx'; -import type { UrlManager } from '@searchspring/snap-url-manager'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; import type { StoreServices } from '../../types'; import type { MetaResponseModel, MetaResponseModelSortOption, SearchResponseModel } from '@athoscommerce/snapi-types'; diff --git a/packages/snap-store-mobx/src/Storage/README.md b/packages/snap-store-mobx/src/Storage/README.md index 47308dd595..86b3424c66 100644 --- a/packages/snap-store-mobx/src/Storage/README.md +++ b/packages/snap-store-mobx/src/Storage/README.md @@ -2,7 +2,7 @@ An interface for storing data in the browser session storage, local storage, cookies, or memory ```js -import { StorageStore } from '@searchspring/snap-store-mobx'; +import { StorageStore } from '@athoscommerce/snap-store-mobx'; const config = { type: 'session', diff --git a/packages/snap-store-mobx/src/Storage/StorageStore.ts b/packages/snap-store-mobx/src/Storage/StorageStore.ts index 2af31e42fb..8148aba020 100644 --- a/packages/snap-store-mobx/src/Storage/StorageStore.ts +++ b/packages/snap-store-mobx/src/Storage/StorageStore.ts @@ -1,4 +1,4 @@ -import { featureFlags, cookies } from '@searchspring/snap-toolbox'; +import { featureFlags, cookies } from '@athoscommerce/snap-toolbox'; const utils = { cookies, diff --git a/packages/snap-store-mobx/src/types.ts b/packages/snap-store-mobx/src/types.ts index 3c3df62cd5..af38c2b9d4 100644 --- a/packages/snap-store-mobx/src/types.ts +++ b/packages/snap-store-mobx/src/types.ts @@ -1,5 +1,5 @@ -import type { UrlManager } from '@searchspring/snap-url-manager'; -import type { RecommendRequestModel } from '@searchspring/snap-client'; +import type { UrlManager } from '@athoscommerce/snap-url-manager'; +import type { RecommendRequestModel } from '@athoscommerce/snap-client'; import type { SearchResponseModelFacetValueAllOfValues, AutocompleteRequestModel, diff --git a/packages/snap-toolbox/README.md b/packages/snap-toolbox/README.md index 8dfe39d870..0f3712174f 100644 --- a/packages/snap-toolbox/README.md +++ b/packages/snap-toolbox/README.md @@ -6,7 +6,7 @@ A collection of utility tools such as DOM targeting, currency formatting & brows ## Installation ```bash -npm install --save @searchspring/snap-toolbox +npm install --save @athoscommerce/snap-toolbox ``` @@ -21,5 +21,5 @@ import { url, charsParams, until, -} from '@searchspring/snap-toolbox'; +} from '@athoscommerce/snap-toolbox'; ``` \ No newline at end of file diff --git a/packages/snap-toolbox/package.json b/packages/snap-toolbox/package.json index 6d03edf100..d14a25f010 100644 --- a/packages/snap-toolbox/package.json +++ b/packages/snap-toolbox/package.json @@ -1,10 +1,10 @@ { - "name": "@searchspring/snap-toolbox", + "name": "@athoscommerce/snap-toolbox", "version": "1.11.0", "description": "Snap Toolbox", "main": "dist/cjs/index.js", "module": "dist/esm/index.js", - "author": "Searchspring", + "author": "AthosCommerce", "license": "MIT", "repository": "https://github.com/searchspring/snap", "publishConfig": { diff --git a/packages/snap-toolbox/src/DomTargeter/README.md b/packages/snap-toolbox/src/DomTargeter/README.md index f49bd618e0..05d0b1ef23 100644 --- a/packages/snap-toolbox/src/DomTargeter/README.md +++ b/packages/snap-toolbox/src/DomTargeter/README.md @@ -2,7 +2,7 @@ `DomTargeter` is a utility used for rendering components in specified DOM targets. ```js -import { DomTargeter } from '@searchspring/snap-toolbox'; +import { DomTargeter } from '@athoscommerce/snap-toolbox'; ``` The constructor accepts an array of targets, an onTarget callback function, and optionally the Document. @@ -262,7 +262,7 @@ const targets = contentTarget.getTargets(); ## Complete Example ```js -import { DomTargeter } from '@searchspring/snap-toolbox'; +import { DomTargeter } from '@athoscommerce/snap-toolbox'; import { render } from 'preact'; const targeter = new DomTargeter( diff --git a/packages/snap-toolbox/src/charsParams/README.md b/packages/snap-toolbox/src/charsParams/README.md index 624d3e4a8a..0663fed10d 100644 --- a/packages/snap-toolbox/src/charsParams/README.md +++ b/packages/snap-toolbox/src/charsParams/README.md @@ -2,7 +2,7 @@ This utility function returns the length (in bytes) of a given object. ```js -import { charsParams } from '@searchspring/snap-toolbox'; +import { charsParams } from '@athoscommerce/snap-toolbox'; const params = { query: "hello" }; diff --git a/packages/snap-toolbox/src/cookies/README.md b/packages/snap-toolbox/src/cookies/README.md index 1b37520078..487a5f6d5b 100644 --- a/packages/snap-toolbox/src/cookies/README.md +++ b/packages/snap-toolbox/src/cookies/README.md @@ -2,7 +2,7 @@ An interface for setting and getting cookies. ```js -import { cookies } from '@searchspring/snap-toolbox'; +import { cookies } from '@athoscommerce/snap-toolbox'; ``` ## `set` function diff --git a/packages/snap-toolbox/src/debounce/README.md b/packages/snap-toolbox/src/debounce/README.md index bae8538b7d..cd808d39ea 100644 --- a/packages/snap-toolbox/src/debounce/README.md +++ b/packages/snap-toolbox/src/debounce/README.md @@ -2,7 +2,7 @@ A function used to delay frequent inputs ```typescript -import { debounce } from '@searchspring/snap-toolbox'; +import { debounce } from '@athoscommerce/snap-toolbox'; ``` ## `debounce` function diff --git a/packages/snap-toolbox/src/featureFlags/README.md b/packages/snap-toolbox/src/featureFlags/README.md index 04cfd6877d..a5294c32b5 100644 --- a/packages/snap-toolbox/src/featureFlags/README.md +++ b/packages/snap-toolbox/src/featureFlags/README.md @@ -2,7 +2,7 @@ This utility provides a way to check for browser feature support. ```js -import { getFlags, featureFlags } from '@searchspring/snap-toolbox'; +import { getFlags, featureFlags } from '@athoscommerce/snap-toolbox'; ``` ## `getFlags` method diff --git a/packages/snap-toolbox/src/filters/README.md b/packages/snap-toolbox/src/filters/README.md index cd0954bcd5..4af72f165c 100644 --- a/packages/snap-toolbox/src/filters/README.md +++ b/packages/snap-toolbox/src/filters/README.md @@ -2,7 +2,7 @@ Contains a collection of methods used to transform strings or numbers into common variations. ```js -import { filters } from '@searchspring/snap-toolbox'; +import { filters } from '@athoscommerce/snap-toolbox'; ``` ## `formatNumber` method diff --git a/packages/snap-toolbox/src/getContext/README.md b/packages/snap-toolbox/src/getContext/README.md index bd8dea2365..a1a84c2b2b 100644 --- a/packages/snap-toolbox/src/getContext/README.md +++ b/packages/snap-toolbox/src/getContext/README.md @@ -2,13 +2,13 @@ This utility function gets a script tags attributes and innerHTML declarations and returns them in an object. ```js -import { getContext } from '@searchspring/snap-toolbox'; +import { getContext } from '@athoscommerce/snap-toolbox'; ``` -The function takes two parameters, the first being an array of script tag attributes or innerHTML variable names to evaluate. The second optional parameter for a script tag element or CSS selector string. If the script tag element is not provided, the function will query the DOM for a Snap script (using src or #searchspring-context selector). +The function takes two parameters, the first being an array of script tag attributes or innerHTML variable names to evaluate. The second optional parameter for a script tag element or CSS selector string. If the script tag element is not provided, the function will query the DOM for a Snap script (using src or #athos-context selector). -The script element must either have a src containing `snapui.searchspring.io` or an id or type attribute that begins with `searchspring`. -For example: `src="https://snapui.searchspring.io/siteId/bundle.js"`, `type="searchspring"`, `type="searchspring/context"`, `type="searchspring/controller"`, or `id="searchspring-context"`. +The script element must either have a src containing `snapui.athoscommerce.io` or an id or type attribute that equals `athos-context`. +For example: `src="https://snapui.athoscommerce.io/siteId/bundle.js"`, `type="searchspring"`, `type="searchspring/context"`, `type="searchspring/controller"`, or `id="athos-context"`. The innerHTML of the script MUST only contain variable assignments without `var`, `let`, or `const`. Each declaration should end with a semi-colon to ensure minification does not impact the functions ability to parse the innerHTML. @@ -19,7 +19,7 @@ If siteId is passed as a variable to evaluate, it will grab it out of the contex ### Example Integration Context ```html -