From ac7ca887e527ec8f82c0f423289669e4340ec5b0 Mon Sep 17 00:00:00 2001 From: nitinraj-tarento <75484189+nitinraj-tarento@users.noreply.github.com> Date: Tue, 19 Oct 2021 14:51:15 +0530 Subject: [PATCH 01/11] discuss card changes --- .../discuss-category.component.css | 3 +- .../discuss-start.component.scss | 13 +++---- .../my-discussion.component.html | 35 +++++++++++++++---- .../my-discussion.component.scss | 30 +++++++++++++++- .../side-pannel/side-pannel.component.html | 4 ++- .../category-card.component.html | 11 ++++-- .../category-card.component.scss | 5 +++ 7 files changed, 82 insertions(+), 19 deletions(-) diff --git a/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.css b/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.css index 327e8941..9e8fc300 100644 --- a/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.css +++ b/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.css @@ -1,6 +1,7 @@ .discuss-category-cards{ display: grid; - grid-template-columns: repeat(auto-fill, minmax(292px, 1fr)); + /* grid-template-columns: repeat(auto-fill, minmax(292px, 1fr)); */ + grid-template-columns: repeat(auto-fill, minmax(475px, 1fr)); grid-gap: 24px; margin-bottom: 24px; cursor: pointer; diff --git a/projects/discussion-ui/src/lib/components/discuss-start/discuss-start.component.scss b/projects/discussion-ui/src/lib/components/discuss-start/discuss-start.component.scss index 5f19758d..54c23060 100644 --- a/projects/discussion-ui/src/lib/components/discuss-start/discuss-start.component.scss +++ b/projects/discussion-ui/src/lib/components/discuss-start/discuss-start.component.scss @@ -232,8 +232,8 @@ // .discussion-start-modal .discussion-start-modal-content .discussion-start-form .start-form-field .start-form-field-control { .discussion-start-modal .discussion-start-modal-content .discussion-start-form .start-form-field .textarea_box { - width: 98%; - max-width: 98%; + width: 100%; + max-width: 100%; border: 1px solid #70707069; outline: none; border-radius: 4px 4px; @@ -284,13 +284,14 @@ select.post_form_select:focus { border: 1px solid #024f9d; } .text_form_field_box { - width: calc(100% - 290px); - margin-left: 18px; - float: right; + // width: calc(100% - 290px); + // margin-left: 18px; + // float: right; + width: 100%; } .text_form_field_box input.question_input_field { - width:97%!important; + width:100%!important; } @media (max-width: 768px) { diff --git a/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.html b/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.html index bd4d8d22..47b910b8 100644 --- a/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.html +++ b/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.html @@ -5,15 +5,27 @@
{{ data?.username | splitInitials }} +
-
-
{{data?.department}}
-
{{data?.location}}
-
{{data?.email || data?.username}}
-
-
-
+
+ + +
+ +
+
+
{{data?.topiccount || 0 }} Discussions @@ -22,10 +34,19 @@ {{data?.postcount || 0 }} Posts + + 45 + Profile views + +
+ +
+

Last online 4 minutes ago

+
diff --git a/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.scss b/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.scss index 05f66c6b..09a58256 100644 --- a/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.scss +++ b/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.scss @@ -67,12 +67,23 @@ display: flex; flex-direction: column; align-items: baseline; - justify-content: space-evenly; + // justify-content: space-evenly; + justify-content: space-between; + width: calc(100% - 180px); } +.bottom_info_box { + width: 100%; + display: flex; +} +.info-top-box { + flex-wrap: wrap; + width: 100%; +} .profile-data { margin-top: 16px; font-size: 14px; + width: 100%; } .post-count-area { @@ -134,6 +145,23 @@ } } +a.karma_btn { + padding: 10px 40px; + box-sizing: border-box; + text-align: center; + font: 700 14px/21px Lato; + border-radius: 4px 4px; + background-color: rgba(0, 0, 0, .04); +} +.post-time-box { + p { + font-weight: 700; + } +} +// .karma_icon { +// margin-right: 8px; +// } + .discuss-card-content { z-index: 1!important; } diff --git a/projects/discussion-ui/src/lib/components/side-pannel/side-pannel.component.html b/projects/discussion-ui/src/lib/components/side-pannel/side-pannel.component.html index 0e734518..b286b323 100644 --- a/projects/discussion-ui/src/lib/components/side-pannel/side-pannel.component.html +++ b/projects/discussion-ui/src/lib/components/side-pannel/side-pannel.component.html @@ -20,4 +20,6 @@
- \ No newline at end of file + + + diff --git a/projects/discussion-ui/src/lib/elements/category-card/category-card.component.html b/projects/discussion-ui/src/lib/elements/category-card/category-card.component.html index 68b2febf..48c345fc 100644 --- a/projects/discussion-ui/src/lib/elements/category-card/category-card.component.html +++ b/projects/discussion-ui/src/lib/elements/category-card/category-card.component.html @@ -3,12 +3,17 @@
Buffer-image
-
+
+
+

{{category.description}}

+
+ -

{{category.description}}

+
-
{{category.totalTopicCount}} discussions
+
789 views
+
eye-icon
diff --git a/projects/discussion-ui/src/lib/elements/category-card/category-card.component.scss b/projects/discussion-ui/src/lib/elements/category-card/category-card.component.scss index 1e4c5f3d..bae2e37b 100644 --- a/projects/discussion-ui/src/lib/elements/category-card/category-card.component.scss +++ b/projects/discussion-ui/src/lib/elements/category-card/category-card.component.scss @@ -91,6 +91,11 @@ font-size: 14px; font-weight: 700 !important; font-family: inherit; + + // .trend_icon { + // margin-right: 4px; + // color: rgba(0, 0, 0, .6); + // } } } From c9856a5f8fd4e973746a5b91dd746a75b10f96c9 Mon Sep 17 00:00:00 2001 From: nitinraj-tarento <75484189+nitinraj-tarento@users.noreply.github.com> Date: Thu, 21 Oct 2021 14:12:03 +0530 Subject: [PATCH 02/11] changes in discussion forum --- .../src/lib/components/components.module.ts | 6 +- .../discuss-category.component.css | 24 ++- .../discuss-category.component.html | 19 +- .../discuss-tags/discuss-tags.component.html | 2 + .../discuss-tags/discuss-tags.component.scss | 3 + .../components/leader-board/leader-board.html | 182 ++++++++++++++++++ .../components/leader-board/leader-board.scss | 129 +++++++++++++ .../leader-board/leaderboard-component.ts | 11 ++ .../lib-entry/lib-entry.component.scss | 3 +- .../my-discussion.component.scss | 3 +- .../side-pannel/side-pannel.component.html | 4 +- .../discussion-routing.module.ts | 6 + .../category-card.component.html | 8 +- .../category-card.component.scss | 7 +- 14 files changed, 394 insertions(+), 13 deletions(-) create mode 100644 projects/discussion-ui/src/lib/components/leader-board/leader-board.html create mode 100644 projects/discussion-ui/src/lib/components/leader-board/leader-board.scss create mode 100644 projects/discussion-ui/src/lib/components/leader-board/leaderboard-component.ts diff --git a/projects/discussion-ui/src/lib/components/components.module.ts b/projects/discussion-ui/src/lib/components/components.module.ts index 4c94038a..06225352 100644 --- a/projects/discussion-ui/src/lib/components/components.module.ts +++ b/projects/discussion-ui/src/lib/components/components.module.ts @@ -18,6 +18,8 @@ import { DiscussAllComponent } from './discuss-all/discuss-all.component'; import { TagAllDiscussionComponent } from './tag-all-discussion/tag-all-discussion.component'; import { InfiniteScrollModule } from 'ngx-infinite-scroll'; import { TrendingTagsComponent } from './trending-tags/trending-tags.component'; +import { LeaderBoardComponent } from './leader-board/leaderboard-component'; + @NgModule({ declarations: [ SidePannelComponent, @@ -30,6 +32,7 @@ import { TrendingTagsComponent } from './trending-tags/trending-tags.component'; DiscussAllComponent, TagAllDiscussionComponent, TrendingTagsComponent, + LeaderBoardComponent, ], imports: [ CommonModule, @@ -39,7 +42,7 @@ import { TrendingTagsComponent } from './trending-tags/trending-tags.component'; ReactiveFormsModule, TagInputModule, PipesModule, - InfiniteScrollModule + InfiniteScrollModule, ], exports: [ SidePannelComponent, @@ -53,6 +56,7 @@ import { TrendingTagsComponent } from './trending-tags/trending-tags.component'; DiscussAllComponent, TagAllDiscussionComponent, TrendingTagsComponent, + LeaderBoardComponent, ], providers: [ DiscussionService, ConfigService diff --git a/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.css b/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.css index 9e8fc300..b6579346 100644 --- a/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.css +++ b/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.css @@ -14,10 +14,32 @@ } .card-comp { - height: calc(100% - 24px); + height: calc(100% - 32px); display: inline-block; } +.discuss-home { + background: no-repeat padding-box #0074b6; + border-radius: 4px 4px; + padding: 14px 15px; + box-sizing: border-box; + width: 140px; + height: 50px; + +} + + + +.recent-tabs { + padding: 0 0!important; +} +.filter-option { + border-bottom: 1px solid rgba(0, 0, 0, .3); +} +.filter-option.tabs-active { + border-bottom: 3px solid var(--blue); + } + @media (max-width: 700px) { .discuss-category-cards { grid-template-columns: 1fr; diff --git a/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.html b/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.html index 389a44a2..c37a126d 100644 --- a/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.html +++ b/projects/discussion-ui/src/lib/components/discuss-category/discuss-category.component.html @@ -1,6 +1,23 @@ -
+ +
+
+ +
+ +
Start discussion
+
+ +
diff --git a/projects/discussion-ui/src/lib/components/discuss-tags/discuss-tags.component.html b/projects/discussion-ui/src/lib/components/discuss-tags/discuss-tags.component.html index 7b2bbec8..7266d584 100644 --- a/projects/discussion-ui/src/lib/components/discuss-tags/discuss-tags.component.html +++ b/projects/discussion-ui/src/lib/components/discuss-tags/discuss-tags.component.html @@ -20,3 +20,5 @@
+ + diff --git a/projects/discussion-ui/src/lib/components/discuss-tags/discuss-tags.component.scss b/projects/discussion-ui/src/lib/components/discuss-tags/discuss-tags.component.scss index f058f78f..4284ccfd 100644 --- a/projects/discussion-ui/src/lib/components/discuss-tags/discuss-tags.component.scss +++ b/projects/discussion-ui/src/lib/components/discuss-tags/discuss-tags.component.scss @@ -72,3 +72,6 @@ } } + + + diff --git a/projects/discussion-ui/src/lib/components/leader-board/leader-board.html b/projects/discussion-ui/src/lib/components/leader-board/leader-board.html new file mode 100644 index 00000000..db035023 --- /dev/null +++ b/projects/discussion-ui/src/lib/components/leader-board/leader-board.html @@ -0,0 +1,182 @@ + + + + +
+ + + +
+ +

Top contributors of the month

+
+ +
+
+
+
+ DN +
+
+

Devaprathap Nagendra

+

Joint Secretary at Tourism

+ +42 Karma +
+
+
+
+ + +
+
+
+
+ DN +
+
+

Anand Bhairavi

+

Joint Secretary at Tourism

+ +37 Karma +
+
+
+
+ + +
+
+
+
+ DN +
+
+

Munmunja Mukherjee

+

Under Secretary at Ministry of Ex..

+ +29 Karma +
+
+
+
+ +
+
+ +
+ +

All users

+ + +
+ +
+
+
+
+ DN +
+
+

Somorjit Phuritshabam

+

Under Secretary at Ministry of Ext.

+ 542 Karma +
+
+
+
+ + +
+
+
+
+ DN +
+
+

Renuka Karmakar

+

Joint Secretary at AYUSH

+ 538 Karma +
+
+
+
+ + +
+
+
+
+ DN +
+
+

Manjunatha HS

+

Joint Secretary Finance

+ 456 Karma +
+
+
+
+ + +
+
+
+
+ DN +
+
+

Rakhi Mohapatra

+

Director at Civil Aviation

+ 454 Karma +
+
+
+
+ + +
+
+
+
+ DN +
+
+

Satyaki Roy

+

Additional Secretary at Urban Dev

+ 508 Karma +
+
+
+
+ + +
+
+
+
+ DN +
+
+

Joy Mathew

+

Joint Secretary at DoPT

+ 412 Karma +
+
+
+
+ +
+
+ +
+ + \ No newline at end of file diff --git a/projects/discussion-ui/src/lib/components/leader-board/leader-board.scss b/projects/discussion-ui/src/lib/components/leader-board/leader-board.scss new file mode 100644 index 00000000..7d10da2c --- /dev/null +++ b/projects/discussion-ui/src/lib/components/leader-board/leader-board.scss @@ -0,0 +1,129 @@ + +// leader board css + + +.df-back-header { + display: none; +} + +.search { + border: 1px solid #dedfe0; + height: 1.5rem; + padding: 12px; + font: inherit; + border-radius: 5px; + margin-bottom: 2rem; + width: 685px; +} +.leader_board_box { + width:100%; + .top_contributor_box { + width: 100%; + margin-bottom: 56px; + } + .discuss-category-cards { + display: grid; + grid-template-columns: repeat(auto-fill,minmax(292px,1fr)); + grid-gap: 24px; + margin-bottom: 24px; + cursor: pointer; + position: relative; + z-index: unset; + width: 100%; + + } + + .category-card { + // box-shadow: 0 2px 1px -1px rgb(0 0 0 / 20%), 0 1px 1px 0 rgb(0 0 0 / 14%), 0 1px 3px 0 rgb(0 0 0 / 12%); + background: #fff; + color: rgba(0,0,0,.87); + transition: box-shadow 280ms cubic-bezier(.4,0,.2,1); + display: block; + position: relative; + border-radius: 4px; + // height: 100%; + width: auto; + padding: 16px; + z-index: 2; + } + .categories-card-content { + width: 315px; + height: 96px; + } + + p.user_content_heading { + margin-bottom: 4px!important; + } + + p.user_designation { + font: 400 12px/16px Lato; + margin-bottom: 4px!important; + } + .user_title_box { + width: 48px; + height: 48px; + border-radius: 4px 4px; + text-align: center; + color: #fff; + justify-content: center; + display: flex; + } + + .inner_contributor_box { + width: 100%; + box-sizing: border-box; + } + + + .user_content_box { + margin-left: 12px; + text-align: left; + align-content: flex-start; + } + p.user_content_heading { + margin-bottom: 4px!important; + } + + p.user_designation { + font: 400 12px/16px Lato; + margin-bottom: 4px!important; + } + + .tabs-filter { + .filter-option { + border-bottom: 1px solid rgba(0, 0, 0, .3); + } + .filter-option.tabs-active { + border-bottom: 3px solid var(--blue); + } + } + + .recent-tabs { + padding: 0 0!important; + } + + // p.karma_text { + + // } + + + + .bg_pink { + background-color: #C4544E; + } + .bg_blue { + background-color: #49418C; + } + .bg_purple { + background-color: #7B418C; + } + .bg_light_blue { + background-color: #4E91C4; + } + .bg_gray { + background-color: #84762C; + } + .bg_green { + background-color: #306933; + } +} diff --git a/projects/discussion-ui/src/lib/components/leader-board/leaderboard-component.ts b/projects/discussion-ui/src/lib/components/leader-board/leaderboard-component.ts new file mode 100644 index 00000000..06220d39 --- /dev/null +++ b/projects/discussion-ui/src/lib/components/leader-board/leaderboard-component.ts @@ -0,0 +1,11 @@ +import { Component, OnInit } from "@angular/core"; + + +@Component({ + selector: 'lib-leaderboard', + templateUrl: './leader-board.html', + styleUrls: ['./leader-board.scss'] + }) + export class LeaderBoardComponent { + + } \ No newline at end of file diff --git a/projects/discussion-ui/src/lib/components/lib-entry/lib-entry.component.scss b/projects/discussion-ui/src/lib/components/lib-entry/lib-entry.component.scss index 7e0a21ac..15bbc1f1 100644 --- a/projects/discussion-ui/src/lib/components/lib-entry/lib-entry.component.scss +++ b/projects/discussion-ui/src/lib/components/lib-entry/lib-entry.component.scss @@ -3,12 +3,13 @@ margin-bottom: 1rem; .df-btn-container { - display: flex; + // display: flex; align-items: center; justify-content: space-between; padding: 0.75rem 0; position: relative; margin: 0 1rem; + display:none; s .df-back-btn { outline: none; diff --git a/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.scss b/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.scss index 09a58256..f25807dd 100644 --- a/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.scss +++ b/projects/discussion-ui/src/lib/components/my-discussion/my-discussion.component.scss @@ -151,7 +151,8 @@ a.karma_btn { text-align: center; font: 700 14px/21px Lato; border-radius: 4px 4px; - background-color: rgba(0, 0, 0, .04); + background-color: rgba(0, 0, 0, .04); + width:185px; } .post-time-box { p { diff --git a/projects/discussion-ui/src/lib/components/side-pannel/side-pannel.component.html b/projects/discussion-ui/src/lib/components/side-pannel/side-pannel.component.html index b286b323..17d53c96 100644 --- a/projects/discussion-ui/src/lib/components/side-pannel/side-pannel.component.html +++ b/projects/discussion-ui/src/lib/components/side-pannel/side-pannel.component.html @@ -2,7 +2,7 @@
  • {{d.label}}
  • - +
  • Leaderboard
  • @@ -15,7 +15,7 @@
  • All discussions
  • Categories
  • Tags
  • - +
  • Leaderboard
  • My discussions
  • diff --git a/projects/discussion-ui/src/lib/discussion-routing/discussion-routing.module.ts b/projects/discussion-ui/src/lib/discussion-routing/discussion-routing.module.ts index 909531c8..e87c1088 100644 --- a/projects/discussion-ui/src/lib/discussion-routing/discussion-routing.module.ts +++ b/projects/discussion-ui/src/lib/discussion-routing/discussion-routing.module.ts @@ -9,6 +9,7 @@ import { RouterModule, Routes } from '@angular/router'; import { DiscussHomeComponent } from './../components/discuss-home/discuss-home.component'; import { DiscussAllComponent } from './../components/discuss-all/discuss-all.component'; import { TagAllDiscussionComponent } from './../components/tag-all-discussion/tag-all-discussion.component'; +import { LeaderBoardComponent } from '../components/leader-board/leaderboard-component'; const routes: Routes = [ @@ -56,6 +57,11 @@ const routes: Routes = [ path: 'topic/:topicId/:slug', pathMatch: 'full', component: DiscussionDetailsComponent + }, + { + path: 'leaderboard', + pathMatch: 'full', + component: LeaderBoardComponent } ] }, diff --git a/projects/discussion-ui/src/lib/elements/category-card/category-card.component.html b/projects/discussion-ui/src/lib/elements/category-card/category-card.component.html index 48c345fc..a61f5bbf 100644 --- a/projects/discussion-ui/src/lib/elements/category-card/category-card.component.html +++ b/projects/discussion-ui/src/lib/elements/category-card/category-card.component.html @@ -1,11 +1,11 @@
    -
    +
    Buffer-image
    -
    +
    -

    {{category.description}}

    +

    {{category.description}}

    @@ -13,7 +13,7 @@
    789 views
    - +
    eye-icon
    diff --git a/projects/discussion-ui/src/lib/elements/category-card/category-card.component.scss b/projects/discussion-ui/src/lib/elements/category-card/category-card.component.scss index bae2e37b..2aa96490 100644 --- a/projects/discussion-ui/src/lib/elements/category-card/category-card.component.scss +++ b/projects/discussion-ui/src/lib/elements/category-card/category-card.component.scss @@ -32,13 +32,16 @@ .category-card-img { position: absolute; top: 3px; - left: 3px; + left: 0px; width: 45px; height: 45px; vertical-align: middle; } } + .category-card-text { + margin-left: 1rem; + } .category-card-header-label { display: -webkit-box; -webkit-line-clamp: 2; @@ -50,7 +53,7 @@ color: rgba(0, 0, 0, .87); word-break: break-all; font-size: 1rem; - margin:0 1rem; + // margin:0 1rem; font-weight: 700 !important; } } From a7076ae3952b8faa2aa1bef6ad20025376b155c3 Mon Sep 17 00:00:00 2001 From: nitinraj-tarento <75484189+nitinraj-tarento@users.noreply.github.com> Date: Wed, 27 Oct 2021 20:02:04 +0530 Subject: [PATCH 03/11] changes in discussion detail page --- .../discussion-details.component.html | 44 ++++++++++++++++--- .../discussion-details.component.scss | 6 +-- .../related-discussion.component.html | 6 ++- 3 files changed, 47 insertions(+), 9 deletions(-) diff --git a/projects/discussion-ui/src/lib/components/discussion-details/discussion-details.component.html b/projects/discussion-ui/src/lib/components/discussion-details/discussion-details.component.html index 86c134d6..22c8f715 100644 --- a/projects/discussion-ui/src/lib/components/discussion-details/discussion-details.component.html +++ b/projects/discussion-ui/src/lib/components/discussion-details/discussion-details.component.html @@ -3,7 +3,19 @@
    -
    +
    +
    +
    + {{ post?.user?.username | splitInitials }} + + + +
    +
    +
    + +
    @@ -21,15 +33,23 @@
    -
    + + + +
    + + + + + + -

    -
    + + + + +
    @@ -46,6 +75,11 @@
    + + +

    + +
    diff --git a/projects/discussion-ui/src/lib/components/discussion-details/discussion-details.component.scss b/projects/discussion-ui/src/lib/components/discussion-details/discussion-details.component.scss index d44bf638..72df0a3e 100644 --- a/projects/discussion-ui/src/lib/components/discussion-details/discussion-details.component.scss +++ b/projects/discussion-ui/src/lib/components/discussion-details/discussion-details.component.scss @@ -68,8 +68,8 @@ .circle-text { // border-radius: 50%; border-radius: 4px 4px; - width: 28px; - height: 28px; + width: 24px; + height: 24px; display: flex; justify-content: center; align-items: center; @@ -82,7 +82,7 @@ .circle-label { color: var(--white); - font-size: 17px; + font-size: 10px; line-height: 12px; letter-spacing: .2625px; text-transform: uppercase; diff --git a/projects/discussion-ui/src/lib/elements/related-discussion/related-discussion.component.html b/projects/discussion-ui/src/lib/elements/related-discussion/related-discussion.component.html index bcff81fc..2c55fd67 100644 --- a/projects/discussion-ui/src/lib/elements/related-discussion/related-discussion.component.html +++ b/projects/discussion-ui/src/lib/elements/related-discussion/related-discussion.component.html @@ -6,7 +6,11 @@