-
Notifications
You must be signed in to change notification settings - Fork 159
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into renovate/carbon-pictograms-react-11.x
- Loading branch information
Showing
246 changed files
with
6,553 additions
and
2,131 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+173 KB
.yarn/cache/@parcel-watcher-linux-arm64-glibc-npm-2.5.0-e2245511c0-10.zip
Binary file not shown.
Binary file added
BIN
+192 KB
.yarn/cache/@parcel-watcher-linux-x64-glibc-npm-2.5.0-32a578ae14-10.zip
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,30 @@ | |
All notable changes to this project will be documented in this file. | ||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. | ||
|
||
## [1.53.5](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-18) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services-store | ||
|
||
|
||
|
||
|
||
|
||
## [1.53.4](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-12) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services-store | ||
|
||
|
||
|
||
|
||
|
||
## [1.53.3](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-11-13) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services-store | ||
|
||
|
||
|
||
|
||
|
||
## [1.53.2](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-09-18) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services-store | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,86 @@ | |
All notable changes to this project will be documented in this file. | ||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. | ||
|
||
## [2.16.2](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-18) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
## [2.16.1](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-12) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
# [2.16.0](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-12) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
# [2.16.0-rc.3](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-07) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
# [2.16.0-rc.2](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-05) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
# [2.16.0-rc.1](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-11-29) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
# [2.16.0-rc.0](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-11-25) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
## [2.15.1](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-11-13) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
# [2.15.0](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-11-05) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
# [2.15.0-rc.0](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-11-05) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
||
|
||
|
||
|
||
|
||
# [2.14.0](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-10-25) | ||
|
||
**Note:** Version bump only for package @carbon/ibmdotcom-services | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
/** | ||
* @license | ||
* | ||
* Copyright IBM Corp. 2024 | ||
* | ||
* This source code is licensed under the Apache-2.0 license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
*/ | ||
|
||
import Cookies from 'js-cookie'; | ||
|
||
const _cookieName = 'activeCartId'; | ||
|
||
class SAPCommerceAPI { | ||
/** | ||
* Check if the user has an active cart by looking for the non-empty cookie. | ||
* | ||
* @returns {boolean} | ||
*/ | ||
static hasActiveCart() { | ||
const activeCartId = SAPCommerceAPI.getActiveCartId(); | ||
// Return true if the activeCartId cookie is non-empty. | ||
return activeCartId !== ''; | ||
} | ||
|
||
/** | ||
* Returns the active cart id. | ||
* | ||
* @returns {string} | ||
* The active cart id if there is one, otherwise empty string. | ||
*/ | ||
static getActiveCartId() { | ||
const activeCartId = Cookies.get(_cookieName); | ||
return activeCartId && typeof activeCartId === 'string' | ||
? activeCartId.trim() | ||
: ''; | ||
} | ||
|
||
/** | ||
* Set the active cart id. | ||
* | ||
* @param {string} activeCartId | ||
* The active cart id. | ||
*/ | ||
static setActiveCartId(activeCartId) { | ||
Cookies.set(_cookieName, activeCartId.trim()); | ||
} | ||
|
||
/** | ||
* Remove the active cart id. | ||
*/ | ||
static removeActiveCartId() { | ||
Cookies.remove(_cookieName); | ||
} | ||
} | ||
|
||
export default SAPCommerceAPI; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
/** | ||
* @license | ||
* | ||
* Copyright IBM Corp. 2024 | ||
* | ||
* This source code is licensed under the Apache-2.0 license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
*/ | ||
export { default as SAPCommerceAPI } from './SAPCommerce.js'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,30 @@ | |
All notable changes to this project will be documented in this file. | ||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. | ||
|
||
## [1.44.5](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-18) | ||
|
||
**Note:** Version bump only for package @carbon/storybook-addon-theme | ||
|
||
|
||
|
||
|
||
|
||
## [1.44.4](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-12) | ||
|
||
**Note:** Version bump only for package @carbon/storybook-addon-theme | ||
|
||
|
||
|
||
|
||
|
||
## [1.44.3](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-11-13) | ||
|
||
**Note:** Version bump only for package @carbon/storybook-addon-theme | ||
|
||
|
||
|
||
|
||
|
||
## [1.44.2](https://github.com/carbon-design-system/carbon-for-ibm-dotcom/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-09-18) | ||
|
||
**Note:** Version bump only for package @carbon/storybook-addon-theme | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.