Debounce the validation, so we don't validate every character.
Debounce also ensures the right ordering.
Only one request runs at a time, we cancel the previous before we fire a new.
this commit change the default name to different format
<release>-<arch>-<date>-<time>
const dateString = `${day}${month}${year}`;
const timeString = `${hours}`;
This updates snippets used for event tracking in Amplitude, adding `imageBuilder` to the name of the event and as a `module` property.
Two more typed events were also added to track number of created blueprints. Name for both events is the same `blueprintCreated`, the differentiation between Create and Create and build images is captured in the `type` property.
These new events will allow to calculate percentage of users that were shown recommendations and of those who added a recommended package while succesfully finishing blueprint creation.
When the option to register with rhc and insights was added back the disableNext condition wasn't updated, allowing user to continue with registration even without selecting activation key.
This adds a code snippet to track package recommendations via Amplitude.
Tests were failing without default mock for `analytics.track()` value used to track package recommendations.
This updates the Registration step as per recent mocks.
There is now only one checkbox which switches between (register everything now / register later). When the checkbox is not checked "register later" option gets selected, activation key dropdown gets disabled and information about activation keys is hidden to support the fact that no activation key will be used.
When the checkbox is checked it either loads previously used activation key in the case of "on edit" scenario, looks for a recently used activation key in localStorage or in a case there are no activationKeys automatically creates and selects one.
The Next button gets disabled only when "register-now" is selected, but there is no activationKey selected. As the option to clear the dropdown got removed this should occur only when fetching/creating activation key.
`renderCustomRoutesWithReduxRouter` and `renderWithReduxRouter`are functionally the same apart from routes they use to render components.
We could just use `renderCustomRoutesWithReduxRouter` and use the routes from `renderWithReduxRouter` as a default value for an optional parameter `routes`.
When a package got selected and deselected again, landing on 0 for selected packages, the information shown in the package recommendations was "Select packages to generate recommendations.No recommendations found for the set of selected packages", this updates the logic to separate the messages.
CentOS 8 was deprecated and is no longer used, but 'On Edit' for a no longer valid blueprint with 'centos-8' as their distribution defaulted to RHEL 9.
This moved the `beforeEach` blocks inside the `describe` blocks as per documentation.
Previously the code inside `beforeEach` didn't trigger which lead to problems with asynchrocinity as mocks didn't get cleared.
This updates the files to be compatible with Vitest. Changes include:
- adding `@testing-library/jest-dom` import to enable custom jest matchers
- renaming `jest.` to `vi.`
- setting flags to false as default where needed