Skip to content

Commit

Permalink
feat [ISEEC-3258] Remove Contact Us (#56)
Browse files Browse the repository at this point in the history
* feat: remove contact us (2.0.2)

* fix: cross platform build

* feat: create the path correctly

* chore: remove fs-extra

* fix: quote things

Co-authored-by: Lucas Grimauth Evangelista <Lucas.Grimauth@ibm.com>
Co-authored-by: Tim R. Bula <timrbula@gmail.com>
  • Loading branch information
3 people authored Apr 4, 2022
1 parent 2b6a514 commit ad6af94
Show file tree
Hide file tree
Showing 10 changed files with 2,618 additions and 2,868 deletions.
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@boomerang-io/carbon-addons-boomerang-react",
"description": "Carbon Addons for Boomerang apps",
"version": "2.0.1",
"version": "2.0.2",
"author": {
"name": "Tim Bula",
"email": "timrbula@gmail.com"
Expand Down Expand Up @@ -70,8 +70,8 @@
"window-or-global": "1.0.1"
},
"peerDependencies": {
"axios": ">=0.26.0",
"@carbon/icons-react": "^10.38.0",
"axios": ">=0.26.0",
"carbon-components": "^10.25.0",
"carbon-components-react": "^7.25.0",
"carbon-icons": "^7.0.7",
Expand Down Expand Up @@ -121,6 +121,7 @@
"carbon-components": "^10.54.0",
"carbon-components-react": "^7.54.0",
"carbon-icons": "^7.0.7",
"cpy": "^8.0.0",
"cross-env": "^7.0.3",
"formik": "^2.2.9",
"in-publish": "^2.0.1",
Expand Down
38 changes: 23 additions & 15 deletions scripts/build.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
'use strict';

const cpy = require('cpy');
const path = require('path');
const which = require('npm-which')(__dirname);
const { execSync } = require('child_process');
const { inInstall } = require('in-publish');
const which = require('npm-which')(__dirname);

if (inInstall()) {
process.exit(0);
Expand All @@ -18,16 +18,24 @@ const exec = (command, extraEnv) =>

const ignoreGlobs = ['**/*.spec.js', '**/*.stories.js'].join(',');

try {
exec(`${babelPath} src --quiet -d es --ignore "${ignoreGlobs}"`, {
BABEL_ENV: 'es',
});
exec(`${babelPath} src --quiet -d lib --ignore "${ignoreGlobs}"`, {
BABEL_ENV: 'cjs',
});
exec(`mkdir -p styles/scss`);
exec(`rsync -avm --include='*.scss' -f 'hide,! */' ./src/* ./styles/scss`);
} catch (error) {
console.error('One of the commands failed:', error.stack); // eslint-disable-line no-console
process.exit(1);
async function build() {
try {
exec(`"${babelPath}" src --quiet -d es --ignore "${ignoreGlobs}"`, {
BABEL_ENV: 'es',
});
exec(`"${babelPath}" src --quiet -d lib --ignore "${ignoreGlobs}"`, {
BABEL_ENV: 'cjs',
});
await cpy('**/*.scss', '../styles/scss', {
parents: true,
cwd: path.resolve(process.cwd(), 'src'),
});
} catch (error) {
console.error('One of the commands failed:', error.stack); // eslint-disable-line no-console
process.exit(1);
}
}

(async (args) => {
await build(args);
})(process.argv);
122 changes: 0 additions & 122 deletions src/components/ContactUs/ContactUs.js

This file was deleted.

88 changes: 0 additions & 88 deletions src/components/ContactUs/ContactUs.spec.js

This file was deleted.

25 changes: 0 additions & 25 deletions src/components/ContactUs/ContactUs.stories.js

This file was deleted.

50 changes: 0 additions & 50 deletions src/components/ContactUs/_contactUs.scss

This file was deleted.

1 change: 0 additions & 1 deletion src/components/ContactUs/index.js

This file was deleted.

4 changes: 0 additions & 4 deletions src/components/UIShell/UIShell.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import HeaderMenuButton from '../HeaderMenuButton';
import HeaderMenuLink from '../HeaderMenuLink';
import ProfileSettings from '../ProfileSettings';
import AboutPlatform from '../AboutPlatform';
import ContactUs from '../ContactUs';
import Feedback from '../Feedback';
import PrivacyStatement from '../PrivacyStatement';
import SignOut from '../SignOut';
Expand Down Expand Up @@ -240,9 +239,6 @@ function UIShell({
text="Tutorial"
/>
),
Boolean(finalBaseServiceUrl) && isSupportEnabled && (
<ContactUs baseServiceUrl={finalBaseServiceUrl} key="Contact Us" />
),
Boolean(finalBaseServiceUrl) && isSupportEnabled && (
<HeaderMenuLink
external={false}
Expand Down
1 change: 0 additions & 1 deletion src/styles/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ $css--plex: true !default;
@import '../components/ComboBox/combobox';
@import '../components/ComboBoxMultiSelect/comboBoxMultiSelect';
@import '../components/ConfirmModal/confirmModal';
@import '../components/ContactUs/contactUs';
@import '../components/Creatable/creatable';
@import '../components/DateInput/dateInput';
@import '../components/Feedback/feedback';
Expand Down
Loading

0 comments on commit ad6af94

Please sign in to comment.