From 2f734e3495026718d70ec20d470a14387846b051 Mon Sep 17 00:00:00 2001 From: gets0ul Date: Thu, 10 Sep 2020 17:28:03 +0700 Subject: [PATCH 01/38] #4294: Fix dropdown issue being hidden behind footer on profile settings page. --- .../shared/components/Header/__snapshots__/index.jsx.snap | 8 +++++++- src/shared/components/Header/index.jsx | 2 +- src/shared/components/TopcoderFooter/style.scss | 1 + src/shared/routes/Topcoder/styles.scss | 2 +- 4 files changed, 10 insertions(+), 3 deletions(-) diff --git a/__tests__/shared/components/Header/__snapshots__/index.jsx.snap b/__tests__/shared/components/Header/__snapshots__/index.jsx.snap index 9f0f7a4186..8f3f8376f7 100644 --- a/__tests__/shared/components/Header/__snapshots__/index.jsx.snap +++ b/__tests__/shared/components/Header/__snapshots__/index.jsx.snap @@ -1,7 +1,13 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP exports[`Default render 1`] = ` -
+
+
Date: Sat, 12 Sep 2020 04:58:09 +0700 Subject: [PATCH 02/38] Fix for #4347 - Open blog page in new, separate tab --- __tests__/shared/components/Header/__snapshots__/index.jsx.snap | 1 + config/default.js | 1 + config/production.js | 1 + 3 files changed, 3 insertions(+) diff --git a/__tests__/shared/components/Header/__snapshots__/index.jsx.snap b/__tests__/shared/components/Header/__snapshots__/index.jsx.snap index 9f0f7a4186..5e384a6d98 100644 --- a/__tests__/shared/components/Header/__snapshots__/index.jsx.snap +++ b/__tests__/shared/components/Header/__snapshots__/index.jsx.snap @@ -118,6 +118,7 @@ exports[`Default render 1`] = ` }, Object { "href": "https://www.topcoder-dev.com/blog", + "openNewTab": true, "title": "Blog", }, Object { diff --git a/config/default.js b/config/default.js index e9c1df07aa..1b87d67929 100644 --- a/config/default.js +++ b/config/default.js @@ -370,6 +370,7 @@ module.exports = { { title: 'Blog', href: 'https://www.topcoder-dev.com/blog', + openNewTab: true, }, { title: 'Thrive', diff --git a/config/production.js b/config/production.js index d62be0f17d..405c90e93b 100644 --- a/config/production.js +++ b/config/production.js @@ -171,6 +171,7 @@ module.exports = { { title: 'Blog', href: 'https://www.topcoder.com/blog', + openNewTab: true, }, { title: 'Thrive', From 4be833ad1987b586c86b91308ede75ce2c102bc5 Mon Sep 17 00:00:00 2001 From: rashmi73 <41687423+rashmi73@users.noreply.github.com> Date: Sat, 12 Sep 2020 03:40:13 +0530 Subject: [PATCH 03/38] Update index.jsx --- src/shared/components/ProfilePage/index.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/components/ProfilePage/index.jsx b/src/shared/components/ProfilePage/index.jsx index 92195ee203..d810d1c3d3 100644 --- a/src/shared/components/ProfilePage/index.jsx +++ b/src/shared/components/ProfilePage/index.jsx @@ -192,7 +192,7 @@ class ProfilePage extends React.Component { info={info} onShowBadges={() => this.setState({ badgesModalOpen: true })} showBadgesButton={achievements && achievements.length > 0} - wins={_.get(stats, 'wins', 0)} + wins={_.get(stats && stats[0] || {}, 'wins', 0)} />
From a6a68d6e1f7177f45d69076fb986e56ec6093d74 Mon Sep 17 00:00:00 2001 From: rashmi73 <41687423+rashmi73@users.noreply.github.com> Date: Sat, 12 Sep 2020 03:56:49 +0530 Subject: [PATCH 04/38] Update index.jsx --- src/shared/components/ProfilePage/index.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/components/ProfilePage/index.jsx b/src/shared/components/ProfilePage/index.jsx index d810d1c3d3..74181a61ca 100644 --- a/src/shared/components/ProfilePage/index.jsx +++ b/src/shared/components/ProfilePage/index.jsx @@ -192,7 +192,7 @@ class ProfilePage extends React.Component { info={info} onShowBadges={() => this.setState({ badgesModalOpen: true })} showBadgesButton={achievements && achievements.length > 0} - wins={_.get(stats && stats[0] || {}, 'wins', 0)} + wins={_.get((stats && stats[0]) || {}, 'wins', 0)} />
From ea282e2593a1787334845f1ddd3f4224d0a12b45 Mon Sep 17 00:00:00 2001 From: rashmi73 <41687423+rashmi73@users.noreply.github.com> Date: Sat, 12 Sep 2020 04:29:16 +0530 Subject: [PATCH 05/38] Update index.jsx.snap --- .../shared/components/ProfilePage/__snapshots__/index.jsx.snap | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/__tests__/shared/components/ProfilePage/__snapshots__/index.jsx.snap b/__tests__/shared/components/ProfilePage/__snapshots__/index.jsx.snap index fb48f813bb..3f8045b9fa 100644 --- a/__tests__/shared/components/ProfilePage/__snapshots__/index.jsx.snap +++ b/__tests__/shared/components/ProfilePage/__snapshots__/index.jsx.snap @@ -58,7 +58,7 @@ exports[`renders a full Profile correctly 1`] = ` } onShowBadges={[Function]} showBadgesButton={true} - wins={3} + wins={0} />
From 7b542d630944f5045865301b021a2ef63ca26912 Mon Sep 17 00:00:00 2001 From: Gaurav Seta Date: Sat, 12 Sep 2020 06:15:01 +0530 Subject: [PATCH 06/38] Update index.jsx --- src/shared/routes/index.jsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/shared/routes/index.jsx b/src/shared/routes/index.jsx index 9c8eb25569..6b6a8440b7 100644 --- a/src/shared/routes/index.jsx +++ b/src/shared/routes/index.jsx @@ -93,6 +93,10 @@ function Routes({ communityId }) { component={() => } path="/community/(competitive-programming|data-science|design|development|qa)/how-to-compete" /> + Date: Sat, 12 Sep 2020 16:03:41 +0530 Subject: [PATCH 07/38] Update ChallengeTags.jsx --- src/shared/components/challenge-detail/Header/ChallengeTags.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/components/challenge-detail/Header/ChallengeTags.jsx b/src/shared/components/challenge-detail/Header/ChallengeTags.jsx index bbea412300..bc9ef6c5b6 100644 --- a/src/shared/components/challenge-detail/Header/ChallengeTags.jsx +++ b/src/shared/components/challenge-detail/Header/ChallengeTags.jsx @@ -62,7 +62,7 @@ export default function ChallengeTags(props) { challengeType && ( setImmediate(() => setChallengeListingFilter(challengeType.id)) + onClick={() => setImmediate(() => setChallengeListingFilter({ types: [challengeType.id] })) } to={`${challengesUrl}?filter[types][0]=${encodeURIComponent(challengeType.id)}`} > From 334596ee7fbd9d74b8320c66bc9325cbaae94f33 Mon Sep 17 00:00:00 2001 From: rashmi73 <41687423+rashmi73@users.noreply.github.com> Date: Sat, 12 Sep 2020 17:02:27 +0530 Subject: [PATCH 08/38] Update ChallengeTags.jsx --- .../components/challenge-detail/Header/ChallengeTags.jsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/shared/components/challenge-detail/Header/ChallengeTags.jsx b/src/shared/components/challenge-detail/Header/ChallengeTags.jsx index bc9ef6c5b6..9e660d1a05 100644 --- a/src/shared/components/challenge-detail/Header/ChallengeTags.jsx +++ b/src/shared/components/challenge-detail/Header/ChallengeTags.jsx @@ -62,7 +62,8 @@ export default function ChallengeTags(props) { challengeType && ( setImmediate(() => setChallengeListingFilter({ types: [challengeType.id] })) + onClick={() => + setImmediate(() => setChallengeListingFilter({ types: [challengeType.id] })) } to={`${challengesUrl}?filter[types][0]=${encodeURIComponent(challengeType.id)}`} > From ff38813a8e5f51fbb31bd9ebf863211bca9a9fd9 Mon Sep 17 00:00:00 2001 From: Luiz Ricardo Rodrigues Date: Mon, 14 Sep 2020 00:36:01 -0300 Subject: [PATCH 09/38] fix: for #4745 Issue: https://github.com/topcoder-platform/community-app/issues/4745 PR: https://github.com/topcoder-platform/topcoder-react-ui-kit/pull/33 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c02656c845..cecb7f752a 100644 --- a/package.json +++ b/package.json @@ -138,7 +138,7 @@ "tc-core-library-js": "github:appirio-tech/tc-core-library-js#v2.6.3", "tc-ui": "^1.0.12", "topcoder-react-lib": "1.0.4", - "topcoder-react-ui-kit": "2.0.0", + "topcoder-react-ui-kit": "1000.1.0", "topcoder-react-utils": "0.7.8", "turndown": "^4.0.2", "url-parse": "^1.4.1", From f719dcd35ee4d8b352bfe6eb8af72766beaa8ab5 Mon Sep 17 00:00:00 2001 From: gets0ul Date: Mon, 14 Sep 2020 11:43:42 +0700 Subject: [PATCH 10/38] Move out inline style to .scss file --- .../shared/components/Header/__snapshots__/index.jsx.snap | 6 +----- src/shared/components/Header/index.jsx | 4 +++- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/__tests__/shared/components/Header/__snapshots__/index.jsx.snap b/__tests__/shared/components/Header/__snapshots__/index.jsx.snap index 6887259318..8470a7c6c5 100644 --- a/__tests__/shared/components/Header/__snapshots__/index.jsx.snap +++ b/__tests__/shared/components/Header/__snapshots__/index.jsx.snap @@ -2,11 +2,7 @@ exports[`Default render 1`] = `
+
Date: Mon, 14 Sep 2020 11:45:23 +0700 Subject: [PATCH 11/38] New scss for header --- src/shared/components/Header/style.scss | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 src/shared/components/Header/style.scss diff --git a/src/shared/components/Header/style.scss b/src/shared/components/Header/style.scss new file mode 100644 index 0000000000..5f470ea788 --- /dev/null +++ b/src/shared/components/Header/style.scss @@ -0,0 +1,3 @@ +.nav-header-wrapper { + z-index: 2; +} From 980bbc4fedbc41c52d5791d00f56c0d0a36b707f Mon Sep 17 00:00:00 2001 From: gets0ul Date: Mon, 14 Sep 2020 11:53:59 +0700 Subject: [PATCH 12/38] Fix test snapshot. --- __tests__/shared/components/Header/__snapshots__/index.jsx.snap | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/__tests__/shared/components/Header/__snapshots__/index.jsx.snap b/__tests__/shared/components/Header/__snapshots__/index.jsx.snap index 8470a7c6c5..e82f28e5b7 100644 --- a/__tests__/shared/components/Header/__snapshots__/index.jsx.snap +++ b/__tests__/shared/components/Header/__snapshots__/index.jsx.snap @@ -2,7 +2,7 @@ exports[`Default render 1`] = `
Date: Mon, 14 Sep 2020 07:03:22 -0300 Subject: [PATCH 13/38] Deploy milestone-20200924 to Dev and Stag Issues: #4347 #4745 #4895 #4687 --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 00fe48889e..aa518f77e1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -230,6 +230,7 @@ workflows: filters: branches: only: + - milestone-20200924 - develop # This is alternate dev env for parallel testing - "build-test": @@ -260,8 +261,7 @@ workflows: filters: branches: only: - - milestone-v1.3 - - milestone-20200910 + - milestone-20200924 - develop # Production builds are exectuted # when PR is merged to the master From 08fb3c3c6f6192fb971269bb071aeef52e991b99 Mon Sep 17 00:00:00 2001 From: "Luiz R. Rodrigues" Date: Mon, 14 Sep 2020 08:42:49 -0300 Subject: [PATCH 14/38] Added validation before call phaseEndDate and phaseStartDate --- .../challenge-listing/Tooltips/ProgressBarTooltip/index.jsx | 6 +++--- src/shared/utils/challenge-listing/sort.js | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/shared/components/challenge-listing/Tooltips/ProgressBarTooltip/index.jsx b/src/shared/components/challenge-listing/Tooltips/ProgressBarTooltip/index.jsx index 432afcde8b..5d7af55ffe 100644 --- a/src/shared/components/challenge-listing/Tooltips/ProgressBarTooltip/index.jsx +++ b/src/shared/components/challenge-listing/Tooltips/ProgressBarTooltip/index.jsx @@ -97,9 +97,9 @@ function Tip(props) { const allPhases = c.phases || []; const endPhaseDate = Math.max(...allPhases.map(d => phaseEndDate(d))); - const registrationPhase = allPhases.find(phase => phase.name === 'Registration'); - const submissionPhase = allPhases.find(phase => phase.name === 'Submission'); - const checkpointPhase = allPhases.find(phase => phase.name === 'Checkpoint Submission'); + const registrationPhase = allPhases.find(phase => phase.name === 'Registration') || {}; + const submissionPhase = allPhases.find(phase => phase.name === 'Submission') || {}; + const checkpointPhase = allPhases.find(phase => phase.name === 'Checkpoint Submission') || {}; if (registrationPhase) { steps.push({ diff --git a/src/shared/utils/challenge-listing/sort.js b/src/shared/utils/challenge-listing/sort.js index 65e6803f0a..0f8d77a159 100644 --- a/src/shared/utils/challenge-listing/sort.js +++ b/src/shared/utils/challenge-listing/sort.js @@ -56,8 +56,8 @@ export default { const getChallengeStartDate = (challenge) => { // extract the phases from `challenge.phases`, // as `challenge.registrationStartDate` returned from API is not reliable - const registrationPhase = find(challenge.phases, p => p.name === 'Registration'); - const submissionPhase = find(challenge.phases, p => p.name === 'Submission'); + const registrationPhase = find(challenge.phases, p => p.name === 'Registration') || {}; + const submissionPhase = find(challenge.phases, p => p.name === 'Submission') || {}; // registration phase exists if (registrationPhase) { return moment(phaseStartDate(registrationPhase)); From 2f14cfbac6b3dfef1fc7a4832c4e165d0852601f Mon Sep 17 00:00:00 2001 From: Kiril Kartunov Date: Mon, 14 Sep 2020 22:50:19 +0300 Subject: [PATCH 15/38] challenge submission --- .../Checkbox/__snapshots__/index.jsx.snap | 24 ++ .../components/GUIKit/Checkbox/index.jsx | 12 + .../Datepicker/__snapshots__/index.jsx.snap | 118 ++++++++++ .../components/GUIKit/Datepicker/index.jsx | 12 + .../Dropdown/__snapshots__/index.jsx.snap | 78 +++++++ .../components/GUIKit/Dropdown/index.jsx | 12 + .../__snapshots__/index.jsx.snap | 72 ++++++ .../components/GUIKit/DropdownTerms/index.jsx | 12 + .../RadioButton/__snapshots__/index.jsx.snap | 29 +++ .../components/GUIKit/RadioButton/index.jsx | 12 + .../TextInput/__snapshots__/index.jsx.snap | 15 ++ .../components/GUIKit/TextInput/index.jsx | 12 + .../Textarea/__snapshots__/index.jsx.snap | 15 ++ .../components/GUIKit/Textarea/index.jsx | 12 + .../Toggles/__snapshots__/index.jsx.snap | 16 ++ .../components/GUIKit/Toggles/index.jsx | 12 + config/default.js | 3 + .../GUIKit/Assets/Images/icon-next.svg | 11 + .../GUIKit/Assets/Images/icon-prev.svg | 13 ++ .../GUIKit/Assets/Styles/Includes/_mixin.scss | 72 ++++++ .../GUIKit/Assets/Styles/Includes/index.scss | 1 + .../GUIKit/Assets/Styles/_default.scss | 7 + .../components/GUIKit/Checkbox/index.jsx | 59 +++++ .../components/GUIKit/Checkbox/style.scss | 109 +++++++++ .../components/GUIKit/Datepicker/index.jsx | 88 ++++++++ .../components/GUIKit/Datepicker/style.scss | 203 +++++++++++++++++ .../components/GUIKit/Dropdown/index.jsx | 95 +++++--- .../components/GUIKit/Dropdown/style.scss | 208 +++++++++++++++++- .../components/GUIKit/DropdownTerms/index.jsx | 187 ++++++++++++++++ .../GUIKit/DropdownTerms/style.scss | 162 ++++++++++++++ .../components/GUIKit/JobListCard/style.scss | 2 +- .../components/GUIKit/Paginate/style.scss | 2 +- .../components/GUIKit/RadioButton/index.jsx | 66 ++++++ .../components/GUIKit/RadioButton/style.scss | 147 +++++++++++++ .../components/GUIKit/SearchCombo/style.scss | 2 +- .../components/GUIKit/TextInput/index.jsx | 69 ++++++ .../components/GUIKit/TextInput/style.scss | 63 ++++++ .../components/GUIKit/Textarea/index.jsx | 68 ++++++ .../components/GUIKit/Textarea/style.scss | 66 ++++++ .../components/GUIKit/Toggles/index.jsx | 53 +++++ .../components/GUIKit/Toggles/style.scss | 141 ++++++++++++ src/shared/components/GUIKit/_default.scss | 2 - .../examples/GUIKit/Checkbox/index.jsx | 189 ++++++++++++++++ .../examples/GUIKit/Checkbox/style.scss | 56 +++++ .../examples/GUIKit/Datepicker/index.jsx | 65 ++++++ .../examples/GUIKit/Datepicker/style.scss | 31 +++ .../examples/GUIKit/Dropdown/index.jsx | 87 ++++++++ .../examples/GUIKit/Dropdown/style.scss | 33 +++ .../examples/GUIKit/DropdownTerms/index.jsx | 83 +++++++ .../examples/GUIKit/DropdownTerms/style.scss | 33 +++ .../examples/GUIKit/RadioButton/index.jsx | 83 +++++++ .../examples/GUIKit/RadioButton/style.scss | 59 +++++ .../examples/GUIKit/TextInput/index.jsx | 76 +++++++ .../examples/GUIKit/TextInput/style.scss | 31 +++ .../examples/GUIKit/Textarea/index.jsx | 65 ++++++ .../examples/GUIKit/Textarea/style.scss | 33 +++ .../examples/GUIKit/Toggles/index.jsx | 127 +++++++++++ .../examples/GUIKit/Toggles/style.scss | 45 ++++ .../components/examples/GUIKit/index.jsx | 47 ++++ .../components/examples/GUIKit/style.scss | 16 ++ src/shared/routes/Examples/Examples.jsx | 2 + src/shared/utils/useWindowSize.js | 26 +++ 62 files changed, 3509 insertions(+), 40 deletions(-) create mode 100644 __tests__/shared/components/GUIKit/Checkbox/__snapshots__/index.jsx.snap create mode 100644 __tests__/shared/components/GUIKit/Checkbox/index.jsx create mode 100644 __tests__/shared/components/GUIKit/Datepicker/__snapshots__/index.jsx.snap create mode 100644 __tests__/shared/components/GUIKit/Datepicker/index.jsx create mode 100644 __tests__/shared/components/GUIKit/Dropdown/__snapshots__/index.jsx.snap create mode 100644 __tests__/shared/components/GUIKit/Dropdown/index.jsx create mode 100644 __tests__/shared/components/GUIKit/DropdownTerms/__snapshots__/index.jsx.snap create mode 100644 __tests__/shared/components/GUIKit/DropdownTerms/index.jsx create mode 100644 __tests__/shared/components/GUIKit/RadioButton/__snapshots__/index.jsx.snap create mode 100644 __tests__/shared/components/GUIKit/RadioButton/index.jsx create mode 100644 __tests__/shared/components/GUIKit/TextInput/__snapshots__/index.jsx.snap create mode 100644 __tests__/shared/components/GUIKit/TextInput/index.jsx create mode 100644 __tests__/shared/components/GUIKit/Textarea/__snapshots__/index.jsx.snap create mode 100644 __tests__/shared/components/GUIKit/Textarea/index.jsx create mode 100644 __tests__/shared/components/GUIKit/Toggles/__snapshots__/index.jsx.snap create mode 100644 __tests__/shared/components/GUIKit/Toggles/index.jsx create mode 100644 src/shared/components/GUIKit/Assets/Images/icon-next.svg create mode 100644 src/shared/components/GUIKit/Assets/Images/icon-prev.svg create mode 100644 src/shared/components/GUIKit/Assets/Styles/Includes/_mixin.scss create mode 100644 src/shared/components/GUIKit/Assets/Styles/Includes/index.scss create mode 100644 src/shared/components/GUIKit/Assets/Styles/_default.scss create mode 100644 src/shared/components/GUIKit/Checkbox/index.jsx create mode 100644 src/shared/components/GUIKit/Checkbox/style.scss create mode 100644 src/shared/components/GUIKit/Datepicker/index.jsx create mode 100644 src/shared/components/GUIKit/Datepicker/style.scss create mode 100644 src/shared/components/GUIKit/DropdownTerms/index.jsx create mode 100644 src/shared/components/GUIKit/DropdownTerms/style.scss create mode 100644 src/shared/components/GUIKit/RadioButton/index.jsx create mode 100644 src/shared/components/GUIKit/RadioButton/style.scss create mode 100644 src/shared/components/GUIKit/TextInput/index.jsx create mode 100644 src/shared/components/GUIKit/TextInput/style.scss create mode 100644 src/shared/components/GUIKit/Textarea/index.jsx create mode 100644 src/shared/components/GUIKit/Textarea/style.scss create mode 100644 src/shared/components/GUIKit/Toggles/index.jsx create mode 100644 src/shared/components/GUIKit/Toggles/style.scss delete mode 100644 src/shared/components/GUIKit/_default.scss create mode 100644 src/shared/components/examples/GUIKit/Checkbox/index.jsx create mode 100644 src/shared/components/examples/GUIKit/Checkbox/style.scss create mode 100644 src/shared/components/examples/GUIKit/Datepicker/index.jsx create mode 100644 src/shared/components/examples/GUIKit/Datepicker/style.scss create mode 100644 src/shared/components/examples/GUIKit/Dropdown/index.jsx create mode 100644 src/shared/components/examples/GUIKit/Dropdown/style.scss create mode 100644 src/shared/components/examples/GUIKit/DropdownTerms/index.jsx create mode 100644 src/shared/components/examples/GUIKit/DropdownTerms/style.scss create mode 100644 src/shared/components/examples/GUIKit/RadioButton/index.jsx create mode 100644 src/shared/components/examples/GUIKit/RadioButton/style.scss create mode 100644 src/shared/components/examples/GUIKit/TextInput/index.jsx create mode 100644 src/shared/components/examples/GUIKit/TextInput/style.scss create mode 100644 src/shared/components/examples/GUIKit/Textarea/index.jsx create mode 100644 src/shared/components/examples/GUIKit/Textarea/style.scss create mode 100644 src/shared/components/examples/GUIKit/Toggles/index.jsx create mode 100644 src/shared/components/examples/GUIKit/Toggles/style.scss create mode 100644 src/shared/components/examples/GUIKit/index.jsx create mode 100644 src/shared/components/examples/GUIKit/style.scss create mode 100644 src/shared/utils/useWindowSize.js diff --git a/__tests__/shared/components/GUIKit/Checkbox/__snapshots__/index.jsx.snap b/__tests__/shared/components/GUIKit/Checkbox/__snapshots__/index.jsx.snap new file mode 100644 index 0000000000..3d56855d05 --- /dev/null +++ b/__tests__/shared/components/GUIKit/Checkbox/__snapshots__/index.jsx.snap @@ -0,0 +1,24 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Default render 1`] = ` + +`; diff --git a/__tests__/shared/components/GUIKit/Checkbox/index.jsx b/__tests__/shared/components/GUIKit/Checkbox/index.jsx new file mode 100644 index 0000000000..e693ad4989 --- /dev/null +++ b/__tests__/shared/components/GUIKit/Checkbox/index.jsx @@ -0,0 +1,12 @@ +import React from 'react'; +import Renderer from 'react-test-renderer/shallow'; + +import Checkbox from 'components/GUIKit/Checkbox'; + + +const rnd = new Renderer(); + +it('Default render', () => { + rnd.render(()); + expect(rnd.getRenderOutput()).toMatchSnapshot(); +}); diff --git a/__tests__/shared/components/GUIKit/Datepicker/__snapshots__/index.jsx.snap b/__tests__/shared/components/GUIKit/Datepicker/__snapshots__/index.jsx.snap new file mode 100644 index 0000000000..6bf8ad76cf --- /dev/null +++ b/__tests__/shared/components/GUIKit/Datepicker/__snapshots__/index.jsx.snap @@ -0,0 +1,118 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Default render 1`] = ` +
+ + } + date={null} + daySize={53} + disableScroll={false} + disabled={false} + displayFormat="MMM DD, YYYY" + enableOutsideDays={true} + firstDayOfWeek={1} + focused={false} + hideKeyboardShortcutsPanel={true} + horizontalMargin={0} + horizontalMonthPadding={13} + id="null----false" + initialVisibleMonth={null} + inputIconPosition="after" + isDayBlocked={[Function]} + isDayHighlighted={[Function]} + isOutsideRange={[Function]} + isRTL={false} + keepFocusOnInput={false} + keepOpenOnDateSelect={false} + monthFormat="MMMM YYYY" + navNext={ + + } + navPrev={ + + } + noBorder={false} + numberOfMonths={1} + onClose={[Function]} + onDateChange={[Function]} + onFocusChange={[Function]} + onNextMonthClick={[Function]} + onPrevMonthClick={[Function]} + openDirection="down" + orientation="horizontal" + phrases={ + Object { + "calendarLabel": "Calendar", + "chooseAvailableDate": [Function], + "clearDate": "Clear Date", + "closeDatePicker": "Close", + "dateIsSelected": [Function], + "dateIsUnavailable": [Function], + "enterKey": "Enter key", + "escape": "Escape key", + "hideKeyboardShortcutsPanel": "Close the shortcuts panel.", + "homeEnd": "Home and end keys", + "jumpToNextMonth": "Move forward to switch to the next month.", + "jumpToPrevMonth": "Move backward to switch to the previous month.", + "keyboardNavigationInstructions": "Press the down arrow key to interact with the calendar and + select a date. Press the question mark key to get the keyboard shortcuts for changing dates.", + "keyboardShortcuts": "Keyboard Shortcuts", + "leftArrowRightArrow": "Right and left arrow keys", + "moveFocusByOneDay": "Move backward (left) and forward (right) by one day.", + "moveFocusByOneMonth": "Switch months.", + "moveFocusByOneWeek": "Move backward (up) and forward (down) by one week.", + "moveFocustoStartAndEndOfWeek": "Go to the first or last day of a week.", + "openThisPanel": "Open this panel.", + "pageUpPageDown": "page up and page down keys", + "questionMark": "Question mark", + "returnFocusToInput": "Return to the date input field.", + "selectFocusedDate": "Select the date in focus.", + "showKeyboardShortcutsPanel": "Open the keyboard shortcuts panel.", + "upArrowDownArrow": "up and down arrow keys", + } + } + placeholder="" + readOnly={false} + regular={false} + renderCalendarInfo={null} + renderDayContents={[Function]} + renderMonthElement={null} + renderMonthText={null} + reopenPickerOnClearDate={false} + required={false} + screenReaderInputMessage="" + showClearDate={false} + showDefaultInputIcon={false} + small={false} + verticalHeight={null} + verticalSpacing={22} + weekDayFormat="ddd" + withFullScreenPortal={false} + withPortal={false} + /> +
+`; diff --git a/__tests__/shared/components/GUIKit/Datepicker/index.jsx b/__tests__/shared/components/GUIKit/Datepicker/index.jsx new file mode 100644 index 0000000000..c0001cce99 --- /dev/null +++ b/__tests__/shared/components/GUIKit/Datepicker/index.jsx @@ -0,0 +1,12 @@ +import React from 'react'; +import Renderer from 'react-test-renderer/shallow'; + +import Datepicker from 'components/GUIKit/Datepicker'; + + +const rnd = new Renderer(); + +it('Default render', () => { + rnd.render(()); + expect(rnd.getRenderOutput()).toMatchSnapshot(); +}); diff --git a/__tests__/shared/components/GUIKit/Dropdown/__snapshots__/index.jsx.snap b/__tests__/shared/components/GUIKit/Dropdown/__snapshots__/index.jsx.snap new file mode 100644 index 0000000000..694bfadb1b --- /dev/null +++ b/__tests__/shared/components/GUIKit/Dropdown/__snapshots__/index.jsx.snap @@ -0,0 +1,78 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Default render 1`] = ` +
+
+ + + + + radio + +
+
+`; diff --git a/__tests__/shared/components/GUIKit/RadioButton/index.jsx b/__tests__/shared/components/GUIKit/RadioButton/index.jsx new file mode 100644 index 0000000000..f386d2bbbd --- /dev/null +++ b/__tests__/shared/components/GUIKit/RadioButton/index.jsx @@ -0,0 +1,12 @@ +import React from 'react'; +import Renderer from 'react-test-renderer/shallow'; + +import RadioButton from 'components/GUIKit/RadioButton'; + + +const rnd = new Renderer(); + +it('Default render', () => { + rnd.render(()); + expect(rnd.getRenderOutput()).toMatchSnapshot(); +}); diff --git a/__tests__/shared/components/GUIKit/TextInput/__snapshots__/index.jsx.snap b/__tests__/shared/components/GUIKit/TextInput/__snapshots__/index.jsx.snap new file mode 100644 index 0000000000..f85a42e507 --- /dev/null +++ b/__tests__/shared/components/GUIKit/TextInput/__snapshots__/index.jsx.snap @@ -0,0 +1,15 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Default render 1`] = ` +
+ +
+`; diff --git a/__tests__/shared/components/GUIKit/TextInput/index.jsx b/__tests__/shared/components/GUIKit/TextInput/index.jsx new file mode 100644 index 0000000000..fb49292a71 --- /dev/null +++ b/__tests__/shared/components/GUIKit/TextInput/index.jsx @@ -0,0 +1,12 @@ +import React from 'react'; +import Renderer from 'react-test-renderer/shallow'; + +import TextInput from 'components/GUIKit/TextInput'; + + +const rnd = new Renderer(); + +it('Default render', () => { + rnd.render(()); + expect(rnd.getRenderOutput()).toMatchSnapshot(); +}); diff --git a/__tests__/shared/components/GUIKit/Textarea/__snapshots__/index.jsx.snap b/__tests__/shared/components/GUIKit/Textarea/__snapshots__/index.jsx.snap new file mode 100644 index 0000000000..c1aa4a9108 --- /dev/null +++ b/__tests__/shared/components/GUIKit/Textarea/__snapshots__/index.jsx.snap @@ -0,0 +1,15 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Default render 1`] = ` +
+