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
                           <span *ngIf="showOptions.show!='source' && showOptions.show != 'claim'">
29
                             <span>LINK TO </span>
30
                             <mat-select [(ngModel)]="showOptions.show" class="uk-select uk-width-auto  uk-text-bold matSelection"
31
                                     *ngIf="showOptions.linkToEntities.length > 1"
32
                                     [disableOptionCentering]="true"
33
                                     panelClass="matSelectionPanel">
34
                               <mat-option *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 "
35
                                       value="project">PROJECTS</mat-option>
36
                               <mat-option *ngIf="showOptions.linkToEntities.indexOf('result')!=-1 " value="result">RESEARCH
37
                                 RESULTS</mat-option>
38
                               <mat-option *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 " value="context">COMMUNITIES
39
                               </mat-option>
40
                             </mat-select>
41
                             <span class=" uk-width-auto  uk-text-bold "
42
                                   *ngIf="showOptions.linkToEntities.length ==1">
43
                               <span *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 "
44
                                     value="project">PROJECTS</span>
45
                               <span *ngIf="showOptions.linkToEntities.indexOf('result')!=-1 " value="result">RESEARCH
46
                                 RESULTS</span>
47
                               <span *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 " value="context">COMMUNITIES
48
                               </span>
49
                             </span>
50
                           </span>
51
                        <span *ngIf="showOptions.show=='source'" class="uk-text-bold">
52
                            ADD LINKING SOURCES
53
                           </span>
54

    
55
                      </div>
56
                      <div *ngIf="showOptions.show=='source'">
57
                        <claim-result-search-form [selectedResults]="sources" [properties]=properties
58
                                                  [localStoragePrefix]="localStoragePrefix+'sources'" [basketLimit]="basketLimit"
59
                        ></claim-result-search-form>
60
                      </div>
61
                      <div *ngIf="showOptions.show=='project'">
62
                        <claim-projects-search-form [selectedProjects]="results" [properties]=properties
63
                                                    [localStoragePrefix]="localStoragePrefix+'results'" [basketLimit]="basketLimit"
64
                        ></claim-projects-search-form>
65
                      </div>
66
                      <div *ngIf="showOptions.show=='context'">
67
                        <claim-contexts-search-form [communityId]=communityId [results]="results" [sources]="sources"
68
                                                    [properties]=properties
69
                                                    [localStoragePrefix]="localStoragePrefix+'results'" [basketLimit]="basketLimit"
70
                        ></claim-contexts-search-form>
71
                      </div>
72
                      <div *ngIf="showOptions.show=='result'">
73
                        <claim-result-search-form [selectedResults]="results" [properties]=properties
74
                                                  [localStoragePrefix]="localStoragePrefix+'results'" [basketLimit]="basketLimit"
75
                        ></claim-result-search-form>
76
                      </div>
77

    
78
                    </div>
79
                    <!-- Basket-->
80
                    <div *ngIf="showOptions.show != 'claim'" class="uk-width-1-3" style="">
81
                      <div class="linksbasketheader uk-margin-bottom uk-text-bold uk-h5">
82
                        LINKS BASKET
83
                      </div>
84
                      <div class="linksbasket uk-inline uk-width-1-1" style="">
85
                        <div *ngIf="inlineEntity == null">
86
                          <div class="linksbaskettitles  uk-padding-small uk-animation-toggle"
87
                               (click)="showOptions.showBasketSources()"
88
                               [style.cursor]="(showOptions.show!='source'?'pointer':'default')">
89
                            <div class="uk-h6 uk-margin-remove portal-color" >
90
                              SOURCES ({{(sources.length) | number}})
91
                              <span *ngIf="showOptions.show!='source' && !showOptions.basketShowSources"
92
                                    class="uk-icon"><svg width="20"
93
                                                         height="20"
94
                                                         viewBox="0 0 20 20"
95
                                                         xmlns="http://www.w3.org/2000/svg"
96
                                                         icon="chevron-left"
97
                                                         ratio="1"><polyline
98
                                fill="none" stroke="#000" stroke-width="1.03" points="13 16 7 10 13 4"></polyline></svg></span>
99
                              <span *ngIf="showOptions.show!='source' &&  showOptions.basketShowSources"
100
                                    class="uk-icon"><svg width="20"
101
                                                         height="20"
102
                                                         viewBox="0 0 20 20"
103
                                                         xmlns="http://www.w3.org/2000/svg"
104
                                                         icon="chevron-down"
105
                                                         ratio="1"><polyline
106
                                fill="none" stroke="#000" stroke-width="1.03" points="16 7 10 13 4 7"></polyline></svg></span>
107
                            </div>
108
                            Research results to link
109
                          </div>
110

    
111
                          <div *ngIf="showOptions.basketShowSources"
112
                               class="  uk-margin-remove-top uk-height-medium  uk-overflow-auto ">
113
                            <div class="uk-background-muted uk-padding-small  " style="min-height: 17px;">
114
                              <div *ngIf="showOptions.show != 'source'" class="uk-text-center">
115
                                <a (click)="showOptions.showSource()">
116
                                  <!--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-->
117
                                  Edit sources</a>
118
                              </div>
119
                              <start-over *ngIf="showOptions.show == 'source' && (sources.length)> 0"
120
                                          [results]="sources"
121
                                          [localStoragePrefix]="localStoragePrefix+'sources'"
122
                                          message="all sources" class="uk-float-right"></start-over>
123
                              <bulk-claim *ngIf="showOptions.show == 'source'" [results]="sources"
124
                                          [properties]=properties
125
                                          [localStoragePrefix]="localStoragePrefix+'sources'" [basketLimit]="basketLimit"
126
                              >
127
                              </bulk-claim>
128

    
129
                            </div>
130
                            <div class="uk-animation-slide-top-small  uk-padding-small">
131

    
132
                              <div *ngIf="(sources.length) == 0 " class="uk-alert no-selected-message uk-text-center">
133
                                No Sources added yet. Start adding sources from the left panel. Or upload a DOI's CSV file.
134
                              </div>
135
                              <div *ngIf="sources.length >= basketLimit "
136
                                   class="uk-alert uk-alert-warning uk-text-center">
137
                                Basket reached the size limit. No more sources can be added.
138
                              </div>
139
                              <claim-selected-results [results]="sources"
140
                                                      [localStoragePrefix]="localStoragePrefix+'sources'" class=""
141
                                                      [enableRemove]="showOptions.show == 'source'">
142
                              </claim-selected-results>
143
                              <div id="test1"></div>
144
                            </div>
145
                          </div>
146
                        </div>
147
                        <div *ngIf="inlineEntity"
148
                             class="linkInlineEntity   uk-padding-small">
149
                          <div class="uk-h6 linkInlineEntity uk-margin-small-bottom ">
150
                            SOURCE
151

    
152
                          </div>
153
                          <claim-title [entity]="inlineEntity" [slice]="true" [sliceSize]="45"
154
                                       [shortVersion]="true"></claim-title>
155
                          <div class="uk-margin-small-top">
156
                            <span class="uk-label custom-label linkInlineEntityLabel"
157
                                  title="Type">{{inlineEntity.type}}</span>
158
                            <span *ngIf="inlineEntity.project">
159
                            <span class="uk-label custom-label linkInlineEntityLabel"
160
                                  title="Funder">{{inlineEntity.project.funderName}}</span>
161
                              <!--                            <span class="uk-label custom-label " title="Type">{{inlineEntity.type}}</span>-->
162
                          </span>
163
                            <span *ngIf="inlineEntity.result">
164
                            <span class="uk-label custom-label linkInlineEntityLabel "
165
                                  title="Access mode">{{inlineEntity.result.accessRights}}</span>
166
                          </span>
167
                          </div>
168

    
169
                        </div>
170
                        <div *ngIf="showOptions.show !='source'">
171
                          <div class=" linksbaskettitles   uk-padding-small  uk-animation-toggle" (click)="showOptions.basketShowLinksTo=!showOptions.basketShowLinksTo;
172
                            showOptions.basketShowSources=!showOptions.basketShowLinksTo ">
173
                            <div *ngIf="!inlineEntity"> <!--Enable toggle -->
174
                              <span class="uk-h6 uk-margin-remove portal-color" >
175
                                  LINK TO ({{(results.length)  | number}})
176
                                  <span *ngIf="!showOptions.basketShowLinksTo" class="uk-icon"><svg width="20"
177
                                                                                                    height="20"
178
                                                                                                    viewBox="0 0 20 20"
179
                                                                                                    xmlns="http://www.w3.org/2000/svg"
180
                                                                                                    icon="chevron-left"
181
                                                                                                    ratio="1"><polyline
182
                                    fill="none" stroke="#000" stroke-width="1.03"
183
                                    points="13 16 7 10 13 4"></polyline></svg></span>
184
                                  <span *ngIf="showOptions.basketShowLinksTo" class="uk-icon"><svg width="20"
185
                                                                                                   height="20"
186
                                                                                                   viewBox="0 0 20 20"
187
                                                                                                   xmlns="http://www.w3.org/2000/svg"
188
                                                                                                   icon="chevron-down"
189
                                                                                                   ratio="1"><polyline
190
                                    fill="none" stroke="#000" stroke-width="1.03"
191
                                    points="16 7 10 13 4 7"></polyline></svg></span>
192
                                </span>
193
                            </div>
194
                            <div *ngIf="inlineEntity"> <!--Inline Entity - no toggle -->
195
                              <span class="uk-h6 uk-margin-remove portal-color">
196
                                  LINK TO ({{(results.length)  | number}})
197
                                  </span>
198
                            </div>
199

    
200

    
201
                            <div class="linksBasketSubtitles">
202
                              Entities to link with the sources
203
                            </div>
204
                          </div>
205
                          <div *ngIf="showOptions.basketShowLinksTo"
206
                               class="uk-height-medium  uk-overflow-auto">
207
                            <div  *ngIf="  (results.length)> 0 || showOptions.show=='result'"
208
                                  class="uk-background-muted uk-padding-small  " style="min-height: 17px;">
209
                              <start-over *ngIf="  (results.length)> 0"
210
                                          [results]="results" [localStoragePrefix]="localStoragePrefix+'results'"
211
                                          message="all results (projects, communities, research results)"
212
                                          class="uk-float-right"></start-over>
213
                              <bulk-claim *ngIf="showOptions.show=='result'" [results]="results" [properties]=properties
214
                                          [localStoragePrefix]="localStoragePrefix+'results'" [basketLimit]="basketLimit"></bulk-claim>
215
                            </div>
216

    
217
                            <div class="uk-padding-small uk-animation-slide-top-small">
218
                              <div *ngIf="results.length >= basketLimit "
219
                                   class="uk-alert uk-alert-warning uk-text-center">
220
                                Basket reached the size limit. No more entities can be added.
221
                              </div>
222
                              <claim-selected-results sectionTitle="Selected Results" [results]="results"
223
                                                      [localStoragePrefix]="localStoragePrefix+'results'">
224
                              </claim-selected-results>
225
                              <div *ngIf="(results.length) == 0 " class="uk-alert no-selected-message uk-text-center">
226
                                No entities to link with the sources. Start adding entities from the left panel.
227
                              </div>
228

    
229
                            </div>
230
                          </div>
231
                        </div>
232

    
233

    
234
                      </div>
235
                      <div *ngIf="showOptions.show=='source'"
236
                           [class]="((sources.length)>0?'linksbaskettitlesPortalColor ':'uk-disabled')+ ' linksbaskettitles uk-padding-small'"
237
                           (click)="openSelectionModal(); ">
238
                        <!--show = linkTo; basketShowSources=false;
239
                           basketShowLinksTo=true;-->
240
                        <div class="uk-h6 uk-margin-remove portal-color">CONTINUE TO - LINK TO <span
241
                          *ngIf="results.length > 0">({{(results.length)  | number}})</span>
242
                          <span class="uk-icon uk-float-right uk-text-bold uk-margin-small-right">
243
                          <svg width="30" height="30" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"
244
                               icon="chevron-right" ratio="1.5"><polyline fill="none" stroke="#000" stroke-width="1.03"
245
                                                                          points="7 4 13 10 7 16"></polyline></svg>
246
                          </span>
247
                        </div>
248
                        <div class="linksBasketSubtitles">
249
                          Entities to link with the sources
250
                        </div>
251
                      </div>
252
                      <div *ngIf="showOptions.show!='source'"
253
                           [class]="((results.length)>0?'linksbaskettitlesPortalColor ':'uk-disabled')+ ' linksbaskettitles uk-margin-small-top uk-padding-small'"
254
                           style="height:auto !important; " (click)="showOptions.show = 'claim'; scrollUp();">
255

    
256
                        <div class="uk-margin-remove portal-color uk-text-center">
257
                          FINISH LINKING
258
                          <span class="uk-icon uk-float-right uk-text-bold uk-margin-small-right">
259
                          <svg width="30" height="30" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"
260
                               icon="chevron-right" ratio="1.5"><polyline fill="none" stroke="#000" stroke-width="1.03"
261
                                                                          points="7 4 13 10 7 16"></polyline></svg>
262
                          </span>
263
                        </div>
264
                      </div>
265
                    </div>
266
                  </div>
267
                  <helper *ngIf="pageContents && pageContents['bottom'] && pageContents['bottom'].length > 0" [texts]="pageContents['bottom']"></helper>
268
                </div>
269

    
270

    
271
<!--                <helper position="right" styleName=" uk-width-1-5"></helper>-->
272
              </div>
273
<!--              <helper position="bottom"></helper>-->
274
            </div>
275

    
276

    
277
          </div>
278

    
279
        </div>
280
      </div>
281
    </div>
282
  </div>
283
</div>
284

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

    
288
    <div *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 " (click)="closeSelectionModal('project')"
289
         style="cursor:pointer;">
290
      <button class="uk-icon-button portal-button">
291
        <span class="uk-icon">
292
                        <svg height="20" icon="album" ratio="1" viewBox="0 0 20 20" width="20"
293
                             xmlns="http://www.w3.org/2000/svg"><rect height="1" width="10" x="5" y="2"></rect><rect
294
                          height="1" width="14" x="3" y="4"></rect><rect fill="none" height="11" stroke="#000"
295
                                                                         width="17" x="1.5" y="6.5"></rect></svg></span>
296
      </button>
297
      <div>Projects</div>
298
    </div>
299
    <div *ngIf="showOptions.linkToEntities.indexOf('result')!=-1 " (click)="closeSelectionModal('result')"
300
         style="cursor:pointer;">
301
      <button class="uk-icon-button portal-button">
302
         <span class="uk-icon">
303
                           <svg height="20" icon="copy" ratio="1" viewBox="0 0 20 20" width="20"
304
                                xmlns="http://www.w3.org/2000/svg"><rect fill="none" height="16" stroke="#000"
305
                                                                         width="12" x="3.5" y="2.5"></rect><polyline
306
                             fill="none" points="5 0.5 17.5 0.5 17.5 17" stroke="#000"></polyline></svg></span>
307
      </button>
308
      <div>Research results</div>
309
    </div>
310
    <div *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 " (click)="closeSelectionModal('context')"
311
         style="cursor:pointer;">
312
      <button class="uk-icon-button portal-button">
313
        <span class="uk-icon">
314
                           <svg height="20" icon="users" ratio="1" viewBox="0 0 20 20" width="20"
315
                                xmlns="http://www.w3.org/2000/svg"><circle cx="7.7" cy="8.6" fill="none" r="3.5"
316
                                                                           stroke="#000" stroke-width="1.1"></circle><path
317
                             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"
318
                             stroke="#000" stroke-width="1.1"></path><path
319
                             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"
320
                             fill="none" stroke="#000" stroke-width="1.1"></path></svg></span>
321
      </button>
322
      <div>Communities</div>
323
    </div>
324

    
325
  </div>
326
</modal-alert>
(1-1/3)