@commercetools-frontend-extensions/import-resources-modal v1.3.19
@commercetools-frontend-extensions/import-resources-modal
Package for importing resources into Merchant Center Applications.
This library takes into account that you are building a Merchant Center Applications which documentation you can find here. The components follow the same principles of the UIKit components.
Getting started
$ npm install --save @commercetools-frontend-extensions/import-resources-modal
// or
$ yarn add @commercetools-frontend-extensions/import-resources-modal
Description
Import Resources Modal is an internal component used to import resources from csv files, it's using Importer Services to create async import Job.
Usage
import ImportResourcesModal from '@commercetools-frontend-extensions/import-resources-modal';
<ImportResourcesModal
isOpen={true}
resourceTypes={["category"]}
onStartImportSuccess={() => {}}
onClose={() => {}}
/>
Properties
Props | Type | Required | Default | Description | |
---|---|---|---|---|---|
isOpen | boolean | ✅ | Controls whether the import modal is open or closed | ||
resourceTypes | string[] | ✅ | Types of resources, for example: category , product ... If multiple types are provided, the user can select from the UI which resource type to upload | ||
onStartImportSuccess | function | A callback function invoked when the import process successfully starts | |||
onClose | function | A callback function triggered when the modal is requested to close (either by clicking on the overlay, clicking the close button or pressing ESC ). This function is also invoked after an import process, irrespective of whether it was successful or failed |
Releasing
This package uses changesets
in order to do releases to NPM.
In case you want to publish a new version with the latest changes you need to:
- Add a changeset with
pnpm changeset
and select@commercetools-frontend-extensions/import-resources-modal
as the modified package. - Some options would be appear in order to do the release:
patch
: use this release for fixes or small changesminor
: use this release for depenency upgrades or medium changesmajor
: use this release for breaking changes
- After selecting the option you will need to add a comment for the release notes. We recommend to use the same format as for the commits.
- e.g:
feat(utils): add utils for dates
- e.g:
- Push the
changeset
to your branch and GitHub actions will detect that the PR contains changes that affect the published library. - After the PR gets merged, another PR will be created called
Version Packages
which is the one that will be detected, again by GitHub Actions, to do a release to NPM. - Make sure that everything is correct and then merge
Version Packages
PR. - Wait until the new version is available in NPM and then deploy the custom in CircleCI.
Canary releases
Canary releases are automatically published to the distribution channel via CI following a successful build and merge to the main branch.
i18n
The repo is configured with an integration with Transifex. The process for i18n is the same as the Merchant Center uses.
pnpm i18n:build
for adding the new keys to transifex.
Once the PR gets merged to main
transifex will receive a notification with new keys that need to be translated (that's why is important that description
and defaultMessage
are descriptive enough).
Whenever the translators finish translations and mark them as done, the repo will receive a PR (per language) for adding translated messages.
Once we review that translated keys are correct and add a changeset
we can merge the PR. (Don't forget to deploy the custom app)
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
12 months ago
1 year ago
1 year ago
1 year ago
12 months ago
11 months ago
11 months ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
11 months ago
1 year ago
11 months ago
1 year ago
12 months ago
1 year ago
1 year ago
11 months ago
12 months ago
12 months ago
11 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
11 months ago
11 months ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
1 year ago