Project

General

Profile

1
<metadata-preview *ngIf="showOptions.show=='claim' && properties" class="uk-margin-top"
2
                  [results]="results" [sources]="sources"
3
                  [localStoragePrefix]="localStoragePrefix" [inlineEntity]="inlineEntity"
4
                  [showOptions]="showOptions" [properties]=properties [pageContents]="pageContents"
5
                  [defaultColors]="(communityId?false:true)" [communityId]="communityId"
6
>
7
</metadata-preview>
8
<div id="tm-main" class="uk-section  uk-padding-remove-top tm-middle" *ngIf="showOptions.show != 'claim'">
9
  <div class="uk-grid">
10
    <div class="tm-main uk-width-1-1@s uk-width-1-1@m  uk-width-1-1@l uk-row-first ">
11
      <schema2jsonld *ngIf="url" [URL]="url" name="Link your research results" type="other"></schema2jsonld>
12
      <div [class]="((showOptions.show == 'claim')?'':' uk-margin-top ')+' uk-container uk-container-large '">
13
        <div>
14
          <!-- <div class="uk-width-1-1">
15
            <helper position="top"></helper>
16
          </div> -->
17
          <div class="uk-grid  helper-grid">
18
<!--            <helper position="left" styleName=" uk-width-1-5 uk-padding-left"></helper>-->
19
            <div class="uk-width-expand">
20

    
21
              <div *ngIf="properties" class="uk-section uk-section-default uk-padding-remove-top">
22

    
23
                <div style=""
24
                     [class]="((showOptions.show == 'claim')?'':' uk-margin-top ')+' uk-container uk-container-large '">
25
                  <div class="uk-grid" *ngIf="showOptions.show!='claim'">
26
                    <div class="uk-width-2-3">
27
                      <div class="uk-h5">
28

    
29
<!--                        <div *ngIf="showOptions.show!='source' && showOptions.show != 'claim' && showOptions.linkToEntities.length > 1">-->
30
<!--                          <mat-form-field class="matSelectionFormField">-->
31
<!--                            <mat-label>Sort by:</mat-label>-->
32
<!--                            <mat-select [(ngModel)]="showOptions.show" class="uk-width-auto  uk-text-bold matSelection"-->
33
<!--                                        *ngIf="showOptions.linkToEntities.length > 1"-->
34
<!--                                        [disableOptionCentering]="true"-->
35
<!--                                        panelClass="matSelectionPanel">-->
36
<!--                              <mat-option *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 "-->
37
<!--                                          value="project">PROJECTS</mat-option>-->
38
<!--                              <mat-option *ngIf="showOptions.linkToEntities.indexOf('result')!=-1 " value="result">RESEARCH-->
39
<!--                                RESULTS</mat-option>-->
40
<!--                              <mat-option *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 " value="context">COMMUNITIES-->
41
<!--                              </mat-option>-->
42
<!--                            </mat-select>-->
43
<!--                          </mat-form-field>-->
44
<!--                        </div>-->
45

    
46
                          <span *ngIf="showOptions.show!='source' && showOptions.show != 'claim' && showOptions.linkToEntities.length > 1"
47
                                class="uk-flex-inline uk-flex-middle uk-width-3-5@m uk-width-1-1@s">
48
                            <span class="uk-width-1-4 uk-text-muted">LINK TO </span>
49
                            <mat-select [(ngModel)]="showOptions.show" class="uk-width-3-4@m matSelection"
50
                                          *ngIf="showOptions.linkToEntities.length > 1"
51
                                          [disableOptionCentering]="true"
52
                                          panelClass="matSelectionPanel">
53
                                <mat-option *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 "
54
                                            value="project">PROJECTS</mat-option>
55
                                <mat-option *ngIf="showOptions.linkToEntities.indexOf('result')!=-1 " value="result">RESEARCH
56
                                  RESULTS</mat-option>
57
                                <mat-option *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 " value="context">COMMUNITIES
58
                                </mat-option>
59
                              </mat-select>
60
                          </span>
61

    
62
                           <span *ngIf="showOptions.show!='source' && showOptions.show != 'claim' && showOptions.linkToEntities.length ==1">
63
                             <span>LINK TO </span>
64
                             <span class=" uk-width-auto  uk-text-bold">
65
                               <span *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 "
66
                                     value="project">PROJECTS</span>
67
                               <span *ngIf="showOptions.linkToEntities.indexOf('result')!=-1 " value="result">RESEARCH
68
                                 RESULTS</span>
69
                               <span *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 " value="context">COMMUNITIES
70
                               </span>
71
                             </span>
72
                           </span>
73
                        <span *ngIf="showOptions.show=='source'" class="uk-text-bold">
74
                            ADD LINKING SOURCES
75
                           </span>
76

    
77
                      </div>
78
                      <div *ngIf="showOptions.show=='source'">
79
                        <claim-result-search-form [selectedResults]="sources" [properties]=properties
80
                                                  [localStoragePrefix]="localStoragePrefix+'sources'" [basketLimit]="basketLimit"
81
                        ></claim-result-search-form>
82
                      </div>
83
                      <div *ngIf="showOptions.show=='project'">
84
                        <claim-projects-search-form [selectedProjects]="results" [properties]=properties
85
                                                    [localStoragePrefix]="localStoragePrefix+'results'" [basketLimit]="basketLimit"
86
                        ></claim-projects-search-form>
87
                      </div>
88
                      <div *ngIf="showOptions.show=='context'">
89
                        <claim-contexts-search-form [communityId]=communityId [results]="results" [sources]="sources"
90
                                                    [properties]=properties
91
                                                    [localStoragePrefix]="localStoragePrefix+'results'" [basketLimit]="basketLimit"
92
                        ></claim-contexts-search-form>
93
                      </div>
94
                      <div *ngIf="showOptions.show=='result'">
95
                        <claim-result-search-form [selectedResults]="results" [properties]=properties
96
                                                  [localStoragePrefix]="localStoragePrefix+'results'" [basketLimit]="basketLimit"
97
                        ></claim-result-search-form>
98
                      </div>
99

    
100
                    </div>
101
                    <!-- Basket-->
102
                    <div *ngIf="showOptions.show != 'claim'" class="uk-width-1-3" style="">
103
                      <div class="linksbasketheader uk-margin-bottom uk-text-bold uk-h5">
104
                        LINKS BASKET
105
                      </div>
106
                      <div class="linksbasket uk-inline uk-width-1-1" style="">
107
                        <div *ngIf="inlineEntity == null">
108
                          <div class="linksbaskettitles  uk-padding-small uk-animation-toggle"
109
                               (click)="showOptions.showBasketSources()"
110
                               [style.cursor]="(showOptions.show!='source'?'pointer':'default')">
111
                            <div class="uk-h6 uk-margin-remove portal-color" >
112
                              SOURCES ({{(sources.length) | number}})
113
                              <span *ngIf="showOptions.show!='source' && !showOptions.basketShowSources"
114
                                    class="uk-icon"><svg width="20"
115
                                                         height="20"
116
                                                         viewBox="0 0 20 20"
117
                                                         xmlns="http://www.w3.org/2000/svg"
118
                                                         icon="chevron-left"
119
                                                         ratio="1"><polyline
120
                                fill="none" stroke="#000" stroke-width="1.03" points="13 16 7 10 13 4"></polyline></svg></span>
121
                              <span *ngIf="showOptions.show!='source' &&  showOptions.basketShowSources"
122
                                    class="uk-icon"><svg width="20"
123
                                                         height="20"
124
                                                         viewBox="0 0 20 20"
125
                                                         xmlns="http://www.w3.org/2000/svg"
126
                                                         icon="chevron-down"
127
                                                         ratio="1"><polyline
128
                                fill="none" stroke="#000" stroke-width="1.03" points="16 7 10 13 4 7"></polyline></svg></span>
129
                            </div>
130
                            Research results to link
131
                          </div>
132

    
133
                          <div *ngIf="showOptions.basketShowSources"
134
                               class="  uk-margin-remove-top uk-height-medium  uk-overflow-auto ">
135
                            <div class="uk-background-muted uk-padding-small  " style="min-height: 17px;">
136
                              <div *ngIf="showOptions.show != 'source'" class="uk-text-center">
137
                                <a (click)="showOptions.showSource()">
138
                                  <!--span class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="plus" ratio="1"><rect x="9" y="1" width="1" height="17"></rect><rect x="1" y="9" width="17" height="1"></rect></svg></span-->
139
                                  Edit sources</a>
140
                              </div>
141
                              <start-over *ngIf="showOptions.show == 'source' && (sources.length)> 0"
142
                                          [results]="sources"
143
                                          [localStoragePrefix]="localStoragePrefix+'sources'"
144
                                          message="all sources" class="uk-float-right"></start-over>
145
                              <bulk-claim *ngIf="showOptions.show == 'source'" [results]="sources"
146
                                          [properties]=properties
147
                                          [localStoragePrefix]="localStoragePrefix+'sources'" [basketLimit]="basketLimit"
148
                              >
149
                              </bulk-claim>
150

    
151
                            </div>
152
                            <div class="uk-animation-slide-top-small  uk-padding-small">
153

    
154
                              <div *ngIf="(sources.length) == 0 " class="uk-alert no-selected-message uk-text-center">
155
                                No Sources added yet. Start adding sources from the left panel. Or upload a DOI's CSV file.
156
                              </div>
157
                              <div *ngIf="sources.length >= basketLimit "
158
                                   class="uk-alert uk-alert-warning uk-text-center">
159
                                Basket reached the size limit. No more sources can be added.
160
                              </div>
161
                              <claim-selected-results [results]="sources"
162
                                                      [localStoragePrefix]="localStoragePrefix+'sources'" class=""
163
                                                      [enableRemove]="showOptions.show == 'source'">
164
                              </claim-selected-results>
165
                              <div id="test1"></div>
166
                            </div>
167
                          </div>
168
                        </div>
169
                        <div *ngIf="inlineEntity"
170
                             class="linkInlineEntity   uk-padding-small">
171
                          <div class="uk-h6 linkInlineEntity uk-margin-small-bottom ">
172
                            SOURCE
173

    
174
                          </div>
175
                          <claim-title [entity]="inlineEntity" [slice]="true" [sliceSize]="45"
176
                                       [shortVersion]="true"></claim-title>
177
                          <div class="uk-margin-small-top">
178
                            <span class="uk-label custom-label linkInlineEntityLabel"
179
                                  title="Type">{{inlineEntity.type}}</span>
180
                            <span *ngIf="inlineEntity.project">
181
                            <span class="uk-label custom-label linkInlineEntityLabel"
182
                                  title="Funder">{{inlineEntity.project.funderName}}</span>
183
                              <!--                            <span class="uk-label custom-label " title="Type">{{inlineEntity.type}}</span>-->
184
                          </span>
185
                            <span *ngIf="inlineEntity.result">
186
                            <span class="uk-label custom-label linkInlineEntityLabel "
187
                                  title="Access mode">{{inlineEntity.result.accessRights}}</span>
188
                          </span>
189
                          </div>
190

    
191
                        </div>
192
                        <div *ngIf="showOptions.show !='source'">
193
                          <div class=" linksbaskettitles   uk-padding-small  uk-animation-toggle" (click)="showOptions.basketShowLinksTo=!showOptions.basketShowLinksTo;
194
                            showOptions.basketShowSources=!showOptions.basketShowLinksTo ">
195
                            <div *ngIf="!inlineEntity"> <!--Enable toggle -->
196
                              <span class="uk-h6 uk-margin-remove portal-color" >
197
                                  LINK TO ({{(results.length)  | number}})
198
                                  <span *ngIf="!showOptions.basketShowLinksTo" class="uk-icon"><svg width="20"
199
                                                                                                    height="20"
200
                                                                                                    viewBox="0 0 20 20"
201
                                                                                                    xmlns="http://www.w3.org/2000/svg"
202
                                                                                                    icon="chevron-left"
203
                                                                                                    ratio="1"><polyline
204
                                    fill="none" stroke="#000" stroke-width="1.03"
205
                                    points="13 16 7 10 13 4"></polyline></svg></span>
206
                                  <span *ngIf="showOptions.basketShowLinksTo" class="uk-icon"><svg width="20"
207
                                                                                                   height="20"
208
                                                                                                   viewBox="0 0 20 20"
209
                                                                                                   xmlns="http://www.w3.org/2000/svg"
210
                                                                                                   icon="chevron-down"
211
                                                                                                   ratio="1"><polyline
212
                                    fill="none" stroke="#000" stroke-width="1.03"
213
                                    points="16 7 10 13 4 7"></polyline></svg></span>
214
                                </span>
215
                            </div>
216
                            <div *ngIf="inlineEntity"> <!--Inline Entity - no toggle -->
217
                              <span class="uk-h6 uk-margin-remove portal-color">
218
                                  LINK TO ({{(results.length)  | number}})
219
                                  </span>
220
                            </div>
221

    
222

    
223
                            <div class="linksBasketSubtitles">
224
                              Entities to link with the sources
225
                            </div>
226
                          </div>
227
                          <div *ngIf="showOptions.basketShowLinksTo"
228
                               class="uk-height-medium  uk-overflow-auto">
229
                            <div  *ngIf="  (results.length)> 0 || showOptions.show=='result'"
230
                                  class="uk-background-muted uk-padding-small  " style="min-height: 17px;">
231
                              <start-over *ngIf="  (results.length)> 0"
232
                                          [results]="results" [localStoragePrefix]="localStoragePrefix+'results'"
233
                                          message="all results (projects, communities, research results)"
234
                                          class="uk-float-right"></start-over>
235
                              <bulk-claim *ngIf="showOptions.show=='result'" [results]="results" [properties]=properties
236
                                          [localStoragePrefix]="localStoragePrefix+'results'" [basketLimit]="basketLimit"></bulk-claim>
237
                            </div>
238

    
239
                            <div class="uk-padding-small uk-animation-slide-top-small">
240
                              <div *ngIf="results.length >= basketLimit "
241
                                   class="uk-alert uk-alert-warning uk-text-center">
242
                                Basket reached the size limit. No more entities can be added.
243
                              </div>
244
                              <claim-selected-results sectionTitle="Selected Results" [results]="results"
245
                                                      [localStoragePrefix]="localStoragePrefix+'results'">
246
                              </claim-selected-results>
247
                              <div *ngIf="(results.length) == 0 " class="uk-alert no-selected-message uk-text-center">
248
                                No entities to link with the sources. Start adding entities from the left panel.
249
                              </div>
250

    
251
                            </div>
252
                          </div>
253
                        </div>
254

    
255

    
256
                      </div>
257
                      <div *ngIf="showOptions.show=='source'"
258
                           [class]="((sources.length)>0?'linksbaskettitlesPortalColor ':'uk-disabled')+ ' linksbaskettitles uk-padding-small'"
259
                           (click)="openSelectionModal(); ">
260
                        <!--show = linkTo; basketShowSources=false;
261
                           basketShowLinksTo=true;-->
262
                        <div class="uk-h6 uk-margin-remove portal-color">CONTINUE TO - LINK TO <span
263
                          *ngIf="results.length > 0">({{(results.length)  | number}})</span>
264
                          <span class="uk-icon uk-float-right uk-text-bold uk-margin-small-right">
265
                          <svg width="30" height="30" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"
266
                               icon="chevron-right" ratio="1.5"><polyline fill="none" stroke="#000" stroke-width="1.03"
267
                                                                          points="7 4 13 10 7 16"></polyline></svg>
268
                          </span>
269
                        </div>
270
                        <div class="linksBasketSubtitles">
271
                          Entities to link with the sources
272
                        </div>
273
                      </div>
274
                      <div *ngIf="showOptions.show!='source'"
275
                           [class]="((results.length)>0?'linksbaskettitlesPortalColor ':'uk-disabled')+ ' linksbaskettitles uk-margin-small-top uk-padding-small'"
276
                           style="height:auto !important; " (click)="showOptions.show = 'claim'; scrollUp();">
277

    
278
                        <div class="uk-margin-remove portal-color uk-text-center">
279
                          FINISH LINKING
280
                          <span class="uk-icon uk-float-right uk-text-bold uk-margin-small-right">
281
                          <svg width="30" height="30" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"
282
                               icon="chevron-right" ratio="1.5"><polyline fill="none" stroke="#000" stroke-width="1.03"
283
                                                                          points="7 4 13 10 7 16"></polyline></svg>
284
                          </span>
285
                        </div>
286
                      </div>
287
                    </div>
288
                  </div>
289
                  <helper *ngIf="pageContents && pageContents['bottom'] && pageContents['bottom'].length > 0" [texts]="pageContents['bottom']"></helper>
290
                </div>
291

    
292

    
293
<!--                <helper position="right" styleName=" uk-width-1-5"></helper>-->
294
              </div>
295
<!--              <helper position="bottom"></helper>-->
296
            </div>
297

    
298

    
299
          </div>
300

    
301
        </div>
302
      </div>
303
    </div>
304
  </div>
305
</div>
306

    
307
<modal-alert (alertOutput)="closeSelectionModal($event)" >
308
  <div class="uk-grid uk-text-center uk-margin-expand uk-padding uk-child-width-1-3">
309

    
310
    <div *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 " (click)="closeSelectionModal('project')"
311
         style="cursor:pointer;">
312
      <button class="uk-icon-button portal-button">
313
        <span class="uk-icon">
314
                        <svg height="20" icon="album" ratio="1" viewBox="0 0 20 20" width="20"
315
                             xmlns="http://www.w3.org/2000/svg"><rect height="1" width="10" x="5" y="2"></rect><rect
316
                          height="1" width="14" x="3" y="4"></rect><rect fill="none" height="11" stroke="#000"
317
                                                                         width="17" x="1.5" y="6.5"></rect></svg></span>
318
      </button>
319
      <div>Projects</div>
320
    </div>
321
    <div *ngIf="showOptions.linkToEntities.indexOf('result')!=-1 " (click)="closeSelectionModal('result')"
322
         style="cursor:pointer;">
323
      <button class="uk-icon-button portal-button">
324
         <span class="uk-icon">
325
                           <svg height="20" icon="copy" ratio="1" viewBox="0 0 20 20" width="20"
326
                                xmlns="http://www.w3.org/2000/svg"><rect fill="none" height="16" stroke="#000"
327
                                                                         width="12" x="3.5" y="2.5"></rect><polyline
328
                             fill="none" points="5 0.5 17.5 0.5 17.5 17" stroke="#000"></polyline></svg></span>
329
      </button>
330
      <div>Research results</div>
331
    </div>
332
    <div *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 " (click)="closeSelectionModal('context')"
333
         style="cursor:pointer;">
334
      <button class="uk-icon-button portal-button">
335
        <span class="uk-icon">
336
                           <svg height="20" icon="users" ratio="1" viewBox="0 0 20 20" width="20"
337
                                xmlns="http://www.w3.org/2000/svg"><circle cx="7.7" cy="8.6" fill="none" r="3.5"
338
                                                                           stroke="#000" stroke-width="1.1"></circle><path
339
                             d="M1,18.1 C1.7,14.6 4.4,12.1 7.6,12.1 C10.9,12.1 13.7,14.8 14.3,18.3" fill="none"
340
                             stroke="#000" stroke-width="1.1"></path><path
341
                             d="M11.4,4 C12.8,2.4 15.4,2.8 16.3,4.7 C17.2,6.6 15.7,8.9 13.6,8.9 C16.5,8.9 18.8,11.3 19.2,14.1"
342
                             fill="none" stroke="#000" stroke-width="1.1"></path></svg></span>
343
      </button>
344
      <div>Communities</div>
345
    </div>
346

    
347
  </div>
348
</modal-alert>
(1-1/3)