From f046f25b7a8af39cad8c3336a6f6890d8f2d3adf Mon Sep 17 00:00:00 2001 From: dyatlov-a Date: Mon, 7 Oct 2024 21:13:23 +0300 Subject: [PATCH] Created components: InputMultiLines, InputSingleLine --- .../Forms/InputMultiLines.stories.razor | 23 ++++++ .../Forms/InputSingleLine.stories.razor | 23 ++++++ .../Components/InputMultiLines.razor | 32 ++++++++ .../Components/InputMultiLines.razor.css | 20 +++++ .../Components/InputMultiSelectList.razor.css | 16 ++++ .../Components/InputSelectList.razor | 74 ++++++++++--------- .../Components/InputSelectList.razor.css | 23 ++++++ .../Components/InputSingleLine.razor | 32 ++++++++ .../Components/InputSingleLine.razor.css | 16 ++++ .../Features/AcceptCookieDialog.razor | 2 +- .../AssessmentSessionHistoryPage.razor | 2 +- .../AssessmentSessionHistoryPage.razor.css | 4 + .../AssessmentSessionPage.razor | 6 +- .../AssessmentSessionPage.razor.css | 6 ++ .../Constructor/ConstructorPage.razor | 2 +- .../Constructor/ConstructorPage.razor.css | 4 + .../Constructor/Stages/Stage1/CheckBot.razor | 9 +-- .../Stages/Stage2/FeatureCard.razor.css | 1 + .../Stages/Stage2/InputFeatures.razor.css | 12 +++ .../Stages/Stage3/BotDetailsItemEditor.razor | 15 +--- .../Constructor/Stages/Stage4/Complete.razor | 28 +++---- .../Constructor/Stages/StagesPage.razor | 2 +- .../Constructor/Stages/StagesPage.razor.css | 2 + .../AppraiserIntegrationWidget.razor | 26 ++----- .../Reviewer/ReviewHistoryWidget.razor.css | 3 + .../Settings/DashboardSettings.razor | 2 +- .../Settings/DashboardSettings.razor.css | 1 + .../wwwroot/css/main.css | 48 +----------- 28 files changed, 291 insertions(+), 143 deletions(-) create mode 100644 src/Inc.TeamAssistant.Stories/Components/Forms/InputMultiLines.stories.razor create mode 100644 src/Inc.TeamAssistant.Stories/Components/Forms/InputSingleLine.stories.razor create mode 100644 src/Inc.TeamAssistant.WebUI/Components/InputMultiLines.razor create mode 100644 src/Inc.TeamAssistant.WebUI/Components/InputMultiLines.razor.css create mode 100644 src/Inc.TeamAssistant.WebUI/Components/InputSelectList.razor.css create mode 100644 src/Inc.TeamAssistant.WebUI/Components/InputSingleLine.razor create mode 100644 src/Inc.TeamAssistant.WebUI/Components/InputSingleLine.razor.css diff --git a/src/Inc.TeamAssistant.Stories/Components/Forms/InputMultiLines.stories.razor b/src/Inc.TeamAssistant.Stories/Components/Forms/InputMultiLines.stories.razor new file mode 100644 index 00000000..6216edc8 --- /dev/null +++ b/src/Inc.TeamAssistant.Stories/Components/Forms/InputMultiLines.stories.razor @@ -0,0 +1,23 @@ +@attribute [Stories("Components/Forms/InputMultiLines")] + + + + + + + + + + + + + +@code { + private readonly string _fieldId = "input-multilines"; + + public string Text { get; set; } = "Text"; +} \ No newline at end of file diff --git a/src/Inc.TeamAssistant.Stories/Components/Forms/InputSingleLine.stories.razor b/src/Inc.TeamAssistant.Stories/Components/Forms/InputSingleLine.stories.razor new file mode 100644 index 00000000..0ba9cbcb --- /dev/null +++ b/src/Inc.TeamAssistant.Stories/Components/Forms/InputSingleLine.stories.razor @@ -0,0 +1,23 @@ +@attribute [Stories("Components/Forms/InputSingleLine")] + + + + + + + + + + + + + +@code { + private readonly string _fieldId = "input-multilines"; + + public string Text { get; set; } = "Text"; +} \ No newline at end of file diff --git a/src/Inc.TeamAssistant.WebUI/Components/InputMultiLines.razor b/src/Inc.TeamAssistant.WebUI/Components/InputMultiLines.razor new file mode 100644 index 00000000..0233d6f9 --- /dev/null +++ b/src/Inc.TeamAssistant.WebUI/Components/InputMultiLines.razor @@ -0,0 +1,32 @@ +@inherits InputBase + +
+ @if (IsDisabled) + { + + } + else + { + + } +
+ +@code { + [Parameter, EditorRequired] + public string FieldId { get; set; } = string.Empty; + + [Parameter] + public bool IsDisabled { get; set; } + + protected override bool TryParseValueFromString(string? value, out string result, out string validationErrorMessage) + { + throw new NotImplementedException(); + } +} \ No newline at end of file diff --git a/src/Inc.TeamAssistant.WebUI/Components/InputMultiLines.razor.css b/src/Inc.TeamAssistant.WebUI/Components/InputMultiLines.razor.css new file mode 100644 index 00000000..e88b6d2a --- /dev/null +++ b/src/Inc.TeamAssistant.WebUI/Components/InputMultiLines.razor.css @@ -0,0 +1,20 @@ +::deep .form-control { + width: 100%; + padding: .625rem .3125rem; + border: 3px solid #555; + border-radius: 0; + color: #000; + background-color: #dfdfdf; + transition: border 0.3s; +} +::deep .form-control_multilines { + resize: none; + height: 102px; +} +::deep .form-control:focus, .form-control_enabled:hover { + border: 3px solid #000; +} +::deep .form-control_disabled { + background-color: #aaa; + cursor: default; +} \ No newline at end of file diff --git a/src/Inc.TeamAssistant.WebUI/Components/InputMultiSelectList.razor.css b/src/Inc.TeamAssistant.WebUI/Components/InputMultiSelectList.razor.css index 2a5c5afd..d3bb8336 100644 --- a/src/Inc.TeamAssistant.WebUI/Components/InputMultiSelectList.razor.css +++ b/src/Inc.TeamAssistant.WebUI/Components/InputMultiSelectList.razor.css @@ -1,3 +1,19 @@ +.form-control { + width: 100%; + padding: .625rem .3125rem; + border: 3px solid #555; + border-radius: 0; + color: #000; + background-color: #dfdfdf; + transition: border 0.3s; +} +.form-control:focus, .form-control_enabled:hover { + border: 3px solid #000; +} +.form-control_disabled { + background-color: #aaa; + cursor: default; +} .multiselect__item { display: inline-block; padding: 5px; diff --git a/src/Inc.TeamAssistant.WebUI/Components/InputSelectList.razor b/src/Inc.TeamAssistant.WebUI/Components/InputSelectList.razor index 8ec778d9..83c29cd4 100644 --- a/src/Inc.TeamAssistant.WebUI/Components/InputSelectList.razor +++ b/src/Inc.TeamAssistant.WebUI/Components/InputSelectList.razor @@ -3,42 +3,44 @@ @inherits InputBase -@if (IsDisabled) -{ - - @if (HasEmptyValue) - { - - } - @foreach (var item in Items) - { - - } - -} -else -{ - - @if (HasEmptyValue) - { - - } - @foreach (var item in Items) - { - - } - -} +
+ @if (IsDisabled) + { + + @if (HasEmptyValue) + { + + } + @foreach (var item in Items) + { + + } + + } + else + { + + @if (HasEmptyValue) + { + + } + @foreach (var item in Items) + { + + } + + } +
@code { [Parameter, EditorRequired] diff --git a/src/Inc.TeamAssistant.WebUI/Components/InputSelectList.razor.css b/src/Inc.TeamAssistant.WebUI/Components/InputSelectList.razor.css new file mode 100644 index 00000000..740fea2a --- /dev/null +++ b/src/Inc.TeamAssistant.WebUI/Components/InputSelectList.razor.css @@ -0,0 +1,23 @@ +::deep .form-control { + width: 100%; + padding: .625rem .3125rem; + border: 3px solid #555; + border-radius: 0; + color: #000; + background-color: #dfdfdf; + transition: border 0.3s; +} +::deep .form-control:focus, .form-control_enabled:hover { + border: 3px solid #000; +} +::deep .form-control_disabled { + background-color: #aaa; + cursor: default; +} +::deep .form-control_select-list { + -webkit-appearance: none; + -moz-appearance: none; + appearance: none; + background: #dfdfdf url('imgs/arrow-down.png') calc(100% - 5px) center no-repeat; + padding-right: 20px; +} \ No newline at end of file diff --git a/src/Inc.TeamAssistant.WebUI/Components/InputSingleLine.razor b/src/Inc.TeamAssistant.WebUI/Components/InputSingleLine.razor new file mode 100644 index 00000000..ec9dd281 --- /dev/null +++ b/src/Inc.TeamAssistant.WebUI/Components/InputSingleLine.razor @@ -0,0 +1,32 @@ +@inherits InputBase + +
+ @if (IsDisabled) + { + + } + else + { + + } +
+ +@code { + [Parameter, EditorRequired] + public string FieldId { get; set; } = string.Empty; + + [Parameter] + public bool IsDisabled { get; set; } + + protected override bool TryParseValueFromString(string? value, out string result, out string validationErrorMessage) + { + throw new NotImplementedException(); + } +} \ No newline at end of file diff --git a/src/Inc.TeamAssistant.WebUI/Components/InputSingleLine.razor.css b/src/Inc.TeamAssistant.WebUI/Components/InputSingleLine.razor.css new file mode 100644 index 00000000..101624af --- /dev/null +++ b/src/Inc.TeamAssistant.WebUI/Components/InputSingleLine.razor.css @@ -0,0 +1,16 @@ +::deep .form-control { + width: 100%; + padding: .625rem .3125rem; + border: 3px solid #555; + border-radius: 0; + color: #000; + background-color: #dfdfdf; + transition: border 0.3s; +} +::deep .form-control:focus, .form-control_enabled:hover { + border: 3px solid #000; +} +::deep .form-control_disabled { + background-color: #aaa; + cursor: default; +} \ No newline at end of file diff --git a/src/Inc.TeamAssistant.WebUI/Features/AcceptCookieDialog.razor b/src/Inc.TeamAssistant.WebUI/Features/AcceptCookieDialog.razor index dd15a02b..954e9f95 100644 --- a/src/Inc.TeamAssistant.WebUI/Features/AcceptCookieDialog.razor +++ b/src/Inc.TeamAssistant.WebUI/Features/AcceptCookieDialog.razor @@ -34,7 +34,7 @@ { _cookieModule = await JsRuntime.InvokeAsync( "import", - "./Features/Dialogs/AcceptCookieDialog.razor.js"); + "./Features/AcceptCookieDialog.razor.js"); var rightsValue = await _cookieModule.InvokeAsync("readCookie", _rightsCookieName); if (!_rightsCookieValue.Equals(rightsValue, StringComparison.InvariantCultureIgnoreCase)) diff --git a/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionHistoryPage.razor b/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionHistoryPage.razor index ecbba0c1..fc735fec 100644 --- a/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionHistoryPage.razor +++ b/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionHistoryPage.razor @@ -18,7 +18,7 @@
-

@Resources[Messages.GUI_StoryList]

+

@Resources[Messages.GUI_StoryList]

diff --git a/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionHistoryPage.razor.css b/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionHistoryPage.razor.css index 05f94c89..86bdd0c3 100644 --- a/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionHistoryPage.razor.css +++ b/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionHistoryPage.razor.css @@ -17,6 +17,10 @@ .assessment-history-switcher { padding-top: 20px; } +.assessment-history__title { + font-size: 2.4rem; + line-height: 3.4rem; +} ::deep .loading { height: calc(100vh - 400px); } \ No newline at end of file diff --git a/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionPage.razor b/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionPage.razor index c1facfde..0d991831 100644 --- a/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionPage.razor +++ b/src/Inc.TeamAssistant.WebUI/Features/AssessmentSession/AssessmentSessionPage.razor @@ -23,11 +23,11 @@
-

@Resources[Messages.GUI_TaskAssess]

-

+

@Resources[Messages.GUI_TaskAssess]

+

@string.Format(Resources[Messages.GUI_AssessmentSessionAbout], _item.TeamName)

-

@Resources[Messages.GUI_AssessmentSessionConnect]

+

@Resources[Messages.GUI_AssessmentSessionConnect]