From 38fb97b8e2f5d6e033e3e37f903b8338b8b4d355 Mon Sep 17 00:00:00 2001 From: Tan Nhu Date: Thu, 12 Jan 2023 09:56:01 -0800 Subject: [PATCH] Add placeholder for Review changes (#193) --- .../components/Changes/Changes.module.scss | 4 - .../Changes/Changes.module.scss.d.ts | 1 - web/src/components/Changes/Changes.tsx | 11 ++- .../ReviewDecisionButton.module.scss | 15 +++ .../ReviewDecisionButton.module.scss.d.ts | 9 ++ .../ReviewDecisionButton.tsx | 91 +++++++++++++++++++ .../MarkdownEditorWithPreview.module.scss | 22 ++++- .../MarkdownEditorWithPreview.tsx | 45 +++++---- web/src/framework/strings/stringTypes.ts | 3 + web/src/i18n/strings.en.yaml | 7 +- .../PullRequest/Conversation/Conversation.tsx | 4 +- web/src/pages/PullRequests/PullRequests.tsx | 1 - 12 files changed, 181 insertions(+), 32 deletions(-) create mode 100644 web/src/components/Changes/ReviewDecisionButton/ReviewDecisionButton.module.scss create mode 100644 web/src/components/Changes/ReviewDecisionButton/ReviewDecisionButton.module.scss.d.ts create mode 100644 web/src/components/Changes/ReviewDecisionButton/ReviewDecisionButton.tsx diff --git a/web/src/components/Changes/Changes.module.scss b/web/src/components/Changes/Changes.module.scss index 764c514ba..c20028a45 100644 --- a/web/src/components/Changes/Changes.module.scss +++ b/web/src/components/Changes/Changes.module.scss @@ -8,10 +8,6 @@ padding: var(--spacing-medium) 0 !important; background-color: var(--white) !important; z-index: 2; - - .hideButton { - visibility: hidden; - } } .diffStatsLabel { diff --git a/web/src/components/Changes/Changes.module.scss.d.ts b/web/src/components/Changes/Changes.module.scss.d.ts index a34a38536..fb645450b 100644 --- a/web/src/components/Changes/Changes.module.scss.d.ts +++ b/web/src/components/Changes/Changes.module.scss.d.ts @@ -3,7 +3,6 @@ declare const styles: { readonly wrapper: string readonly header: string - readonly hideButton: string readonly diffStatsLabel: string readonly main: string readonly enableDiffLineBreaks: string diff --git a/web/src/components/Changes/Changes.tsx b/web/src/components/Changes/Changes.tsx index c964fd103..28c9a3a86 100644 --- a/web/src/components/Changes/Changes.tsx +++ b/web/src/components/Changes/Changes.tsx @@ -17,6 +17,7 @@ import type { TypesPullReq } from 'services/code' import { PullRequestTabContentWrapper } from '../../pages/PullRequest/PullRequestTabContentWrapper' import { ChangesDropdown } from './ChangesDropdown' import { DiffViewConfiguration } from './DiffViewConfiguration' +import { ReviewDecisionButton } from './ReviewDecisionButton/ReviewDecisionButton' import css from './Changes.module.scss' const STICKY_TOP_POSITION = 64 @@ -138,11 +139,11 @@ export const Changes: React.FC = ({ )} -