* feat: add data for preview to challengeMeta
* feat: allow creation of project preview frames
* feat: make project preview data available for frame
* refactor: simplify reducer
* feat: show project preview for first challenge
* feat: show project preview on MultiFile challenges
* test: check for presence/absence of preview modal
* fix: simplify previewProject saga
* test: uncomment project preview test
* fix: increase modal size + change modal title
* modal-footer
* feat: adjust preview size
* fix: remove margin, padding, and line-height for preview of finished projects
* Revert "fix: remove margin, padding, and line-height for preview of finished projects"
This reverts commit 0db11a0819
.
* fix: remove margin on all previews
* refactor: use closeModal('projectPreview') for clarity
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
* fix: get started -> start coding!
* fix: update closeModal type
Co-authored-by: moT01 <20648924+moT01@users.noreply.github.com>
Co-authored-by: Ahmad Abdolsaheb <ahmad.abdolsaheb@gmail.com>
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
33 lines
1.1 KiB
JavaScript
33 lines
1.1 KiB
JavaScript
// ***********************************************************
|
|
// This example plugins/index.js can be used to load plugins
|
|
//
|
|
// You can change the location of this file or turn off loading
|
|
// the plugins file with the 'pluginsFile' configuration option.
|
|
//
|
|
// You can read more here:
|
|
// https://on.cypress.io/plugins-guide
|
|
// ***********************************************************
|
|
|
|
// This function is called when a project is opened or re-opened (e.g. due to
|
|
// the project's config changing)
|
|
/* eslint-disable no-unused-vars */
|
|
|
|
const { execSync } = require('child_process');
|
|
const { existsSync } = require('fs');
|
|
require('dotenv').config();
|
|
|
|
module.exports = (on, config) => {
|
|
// `on` is used to hook into various events Cypress emits
|
|
// `config` is the resolved Cypress config
|
|
config.env = config.env || {};
|
|
on('before:run', () => {
|
|
if (!existsSync('../../config/curriculum.json')) {
|
|
execSync('npm run build:curriculum');
|
|
}
|
|
});
|
|
|
|
// Allows us to test the new curriculum before it's released:
|
|
config.env.SHOW_UPCOMING_CHANGES = process.env.SHOW_UPCOMING_CHANGES;
|
|
return config;
|
|
};
|