Project

General

Profile

« Previous | Next » 

Revision 58549

[Trunk | Connect]: Connect redesing
1. app.component.ts: <subscribe> and <invite> components added (floating buttons on the right side of each page for communities).
2. community.component.html:
3. community.component.ts:
a. 'projectsCalculated' and 'contentProvidersCalculated' fields added, to calculate tootlip after both requests complete
b. added methods for building tootips
c. 'activeTab' set to 'summary'.
4. affiliations.component.html: minor phrasing changes (e.g. title).
5. curators.component.html: shortview changed.
6. results.component.ts: Title changed | 'View all' moved to the bottom.
7. customization.component.ts: Changed '--portal-main-color' from '#4C9CD5' to '#4687E6' | Changed '--portal-dark-color' from '#24857F' to '#2D72D6'.
8. invite.component.html: shortview changed.
9. invite.component.ts: 'properties' field as input (get it is called from app.component).
10. invite.module.ts & inviteBasic.module.ts: InviteBasicModule created to declare InviteComponent without routing and login guard | InviteModule imports InviteBasicModule and adds routing and login guar$
11. subscribe.component.ts: Changes for subscribe button and members | 'properties' field as input (get it is called from app.component).
12. connect-custom.css: css for subscribe and invite buttons and for tooltip with 'community-page-tooltip' class.
13. customization.css: class 'communityBackground' added and css for 'subtitle' class inside 'communityBackground'.

View differences:

community.component.ts
42 42
  public contentProviderTotal = null;
43 43
  public organizationTotal = null;
44 44

  
45
  public projectsCalculated: boolean = false;
46
  public contentProvidersCalculated: boolean = false;
47

  
45 48
  params: any = {};
46 49
  properties: EnvProperties;
47 50

  
......
66 69
  public subSoftware;
67 70
  public subOrps;
68 71
  @ViewChild(StatisticsForDashboardComponent) statistics: StatisticsForDashboardComponent = null;
69
  public activeTab = "publication";
72
  public activeTab = "summary";
70 73
  public show: string = 'overview';
71 74

  
72 75
  searchLinkToResults: string = null;
......
181 184
            },
182 185
            error => {
183 186
              this.handleError("Error getting number of projects for community with id: " + this.communityId, error);
187
            },
188
            () => {
189
              this.projectsCalculated = true;
184 190
            }
185 191
          );
186 192

  
......
191 197
            },
192 198
            error => {
193 199
              this.handleError("Error getting number of content providers for community with id: " + this.communityId, error);
200
            },
201
            () => {
202
              this.contentProvidersCalculated = true;
194 203
            }
195 204
          );
196 205

  
......
220 229
      researchResultsTotal => {
221 230
        this.setTotal(resultType, researchResultsTotal);
222 231
        if (resultType == "publication") {
223
          this.searchResearchResults(resultType, this.publicationTotal, this.publicationResults);
232
          //this.searchResearchResults(resultType, this.publicationTotal, this.publicationResults);
224 233
        }
225 234
      },
226 235
      error => {
......
357 366
      return (full ? ("other research product" + (plural ? "s" : "")) : "other");
358 367
    }
359 368
  }
369

  
370
  public buildProjectsAndContentProvidesTooltip(): string {
371
    let tooltipContent: string = "<div class='uk-margin'>";
372

  
373
    if(this.projectTotal != null  && this.projectTotal > 0 && this.isEntityEnabled('project') && this.isRouteEnabled(this.searchLinkToProjects)) {
374
      tooltipContent += "<span class='uk-text-bold'>Projects</span>";
375
    }
376
    if(this.projectTotal != null  && this.projectTotal > 0 && this.isEntityEnabled('project') && this.isRouteEnabled(this.searchLinkToProjects)
377
      && (this.contentProviderTotal != null  && this.contentProviderTotal > 0 && this.isEntityEnabled('datasource') && this.isRouteEnabled(this.searchLinkToDataProviders))) {
378
      tooltipContent += " and ";
379
    }
380
    if(this.contentProviderTotal != null  && this.contentProviderTotal > 0 && this.isEntityEnabled('datasource') && this.isRouteEnabled(this.searchLinkToDataProviders)) {
381
      tooltipContent += "<span class='uk-text-bold'>Content Providers</span>";
382
    }
383

  
384
    tooltipContent += " have been selected as relevant for your community by the gateway curators.";
385
    tooltipContent += "</div>";
386

  
387
    return tooltipContent;
388
  }
389

  
390
  public buildZenodoCommunitiesTooltip(): string {
391
    let tooltipContent: string = "<div class='uk-margin'>";
392

  
393
    tooltipContent += "<span class='uk-text-bold'>Zenodo</span> is a catch-all repository for OpenAIRE.";
394
    tooltipContent += "<div class='uk-margin-small-top'>A <span class='uk-text-bold'>Zenodo Community</span> is created and curated by Zenodo users.</div>";
395
    tooltipContent += "</div>";
396
    return tooltipContent;
397
  }
360 398
}

Also available in: Unified diff