Skip to content

Commit 227962e

Browse files
authored
Merge pull request #3194 from apinf/develop
0.52.0 release
2 parents a511cf9 + 70587f6 commit 227962e

File tree

170 files changed

+6894
-2341
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

170 files changed

+6894
-2341
lines changed

.eslintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
"no-underscore-dangle": [
4545
2,
4646
{
47-
"allow": ["_id", "__", "_initialized", "_config", "_debug"]
47+
"allow": ["_id", "__", "_initialized", "_config", "_debug", "_schema"]
4848
}
4949
],
5050
"no-negated-condition": [
File renamed without changes.

.gitignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
.vscode/
88
config.json
99
docker/api-umbrella/config/api-umbrella.yml
10-
docker/apinf/env
11-
docker/ssl/env
10+
docker/env.apinf
11+
docker/env.ssl
1212
mup.json
1313
node_modules/
1414
npm-debug.log*

.meteor/packages

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,6 @@ matb33:collection-hooks
5353
5454
meteorhacks:subs-manager
5555
michalvalasek:autoform-bootstrap-colorpicker
56-
mizzao:sharejs-ace
57-
mizzao:sharejs@=0.9.0
5856
5957
6058
nimble:restivus@=0.8.11
@@ -95,3 +93,5 @@ useraccounts:core
9593
useraccounts:flow-routing
9694
vsivsi:file-collection
9795
zimme:active-route
96+
aldeed:autoform-select2
97+
natestrauser:select2

.meteor/versions

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,14 @@ [email protected]
22
33
44
5-
65
6+
77
8-
98
10-
9+
10+
1111
12+
1213
1314
1415
@@ -31,9 +32,9 @@ [email protected]
3132
3233
3334
35+
3436
3537
36-
3738
3839
3940
@@ -43,23 +44,23 @@ cfs:[email protected]
4344
4445
4546
46-
4747
48+
4849
4950
51+
5052
5153
5254
5355
54-
5556
5657
5758
5859
60+
61+
5962
6063
61-
62-
6364
6465
6566
@@ -78,13 +79,13 @@ [email protected]
7879
7980
8081
81-
juliancwirko:[email protected]
8282
juliancwirko:[email protected]
83+
juliancwirko:[email protected]
8384
8485
8586
86-
8787
88+
8889
8990
9091
@@ -93,30 +94,29 @@ [email protected]
9394
9495
9596
96-
9797
98+
9899
meteorhacks:[email protected]
99100
meteorspark:[email protected]
100101
michalvalasek:[email protected]
101102
102103
103104
104-
105-
106105
107106
108-
109107
108+
110109
110+
111111
112112
113113
114-
114+
natestrauser:[email protected]
115115
116116
117117
118-
119118
119+
120120
121121
122122
@@ -148,18 +148,18 @@ [email protected]
148148
149149
150150
softwarerero:[email protected]
151-
152151
152+
153153
154154
155155
156156
157-
158157
158+
159+
159160
160161
161162
162-
163163
164164
165165
@@ -173,6 +173,6 @@ useraccounts:[email protected]
173173
useraccounts:[email protected]
174174
useraccounts:[email protected]
175175
176-
177176
177+
178178

INSTALL.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ Register a new admin account. The first user will become Admin.
5454
## With Docker Compose
5555
1. Create "docker-compose.yml" file on your server and copy content from [docker-compose.yml](https://github.com/apinf/platform/blob/develop/docker-compose.yml).
5656
2. In the same folder create file "docker/api-umbrella/config/api-umbrella.yml" based on example "docker/api-umbrella/config/api-umbrella.yml.example". ATTENTION: replace "example.com" on YOUR_SITE_DOMAIN for keys "ssl_cert" and "ssl_cert_key".
57-
3. Create file "docker/apinf/env" based on example "docker/apinf/env.example".
58-
4. Create file "docker/ssl/env" based on example "docker/ssl/env.example".
57+
3. Create file "docker/env.apinf" based on example "docker/env.apinf.example".
58+
4. Create file "docker/env.ssl" based on example "docker/env.ssl.example".
5959
5. Run ```docker-compose up -d```. The first launch of will be slow because (take couple of minutes) of the DH parameter computation and configure Let's Encrypt certificate.
6060
6. Visit https://YOUR_SITE_DOMAIN:3002/signup/ and fill form for get API Key.
6161
7. Visit https://YOUR_SITE_DOMAIN:3002/admin/ and click on 'My Account' link for find Admin API Token.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,6 @@ See the [high definition video (with music) of Apinf Development Activity up to
5454
You can preview our latest version at [nightly.apinf.io](http://nightly.apinf.io). Feel free to register an account and test things out.
5555

5656
# Contributing
57-
Please review our [Contributor Guide](https://github.com/apinf/platform/blob/develop/CONTRIBUTING.md) for details on how to get involved with the project.
57+
Please review our [Contributor Guide](https://github.com/apinf/platform/blob/develop/.github/CONTRIBUTING.md) for details on how to get involved with the project.
5858

5959
Please follow guidelines for community involvement in our [Code of Conduct](https://github.com/apinf/platform/blob/develop/CODE_OF_CONDUCT.md)

apinf_packages/about/client/about.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ <h3>
3333
Apinf
3434
</dt>
3535
<dd>
36-
0.51.0
36+
0.52.0
3737
</dd>
3838
<dt>
3939
API Umbrella

apinf_packages/api_catalog/client/api_catalog.js

Lines changed: 42 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,39 @@ https://joinup.ec.europa.eu/community/eupl/og_page/european-union-public-licence
55

66
// Meteor packages imports
77
import { Meteor } from 'meteor/meteor';
8-
import { TAPi18n } from 'meteor/tap:i18n';
98
import { Template } from 'meteor/templating';
109

1110
// Meteor contributed packages imports
11+
import { DocHead } from 'meteor/kadira:dochead';
1212
import { FlowRouter } from 'meteor/kadira:flow-router';
1313
import { Roles } from 'meteor/alanning:roles';
14+
import { TAPi18n } from 'meteor/tap:i18n';
1415

1516
// Collection imports
1617
import Apis from '/apinf_packages/apis/collection';
1718
import ApiBookmarks from '/apinf_packages/bookmarks/collection';
19+
import ApiDocs from '/apinf_packages/api_docs/collection';
20+
import Branding from '/apinf_packages/branding/collection';
1821

1922
import 'locale-compare-polyfill';
2023

24+
// Npm packages imports
25+
import _ from 'lodash';
26+
2127
Template.apiCatalog.onCreated(function () {
2228
// Get reference to template instance
2329
const instance = this;
2430

31+
instance.autorun(() => {
32+
// Get Branding collection content
33+
const branding = Branding.findOne();
34+
// Check if Branding collection and siteTitle are available
35+
if (branding && branding.siteTitle) {
36+
// Set the page title
37+
const pageTitle = TAPi18n.__('apiCatalogPage_title_apiCatalog');
38+
DocHead.setTitle(`${branding.siteTitle} - ${pageTitle}`);
39+
}
40+
});
2541
// Get user id
2642
const userId = Meteor.userId();
2743

@@ -57,6 +73,9 @@ Template.apiCatalog.onCreated(function () {
5773
filters,
5874
});
5975

76+
// Subscribe to apiDocs that contains either 'fileId' or 'remoteFileUrl'
77+
instance.subscribe('apisDocuments');
78+
6079
// Subscribe to bookmarks of current user
6180
instance.subscribe('userApiBookmarks');
6281

@@ -156,6 +175,28 @@ Template.apiCatalog.onCreated(function () {
156175
delete currentFilters.lifecycleStatus;
157176
}
158177

178+
// Check URL parameter for apisWithDocumentation filter
179+
const apisWithDocumentation = FlowRouter.getQueryParam('apisWithDocumentation');
180+
181+
// Checking if 'APIs with Documentation' filter is checked or not
182+
if (apisWithDocumentation === 'true') {
183+
// Fetching published ApiDocs
184+
const apiDocs = ApiDocs.find().fetch();
185+
// Creating array of ApiIds
186+
let apiIds = _.map(apiDocs, 'apiId');
187+
188+
// checking if 'My Bookmarks' filter is checked or not
189+
if (filterByParameter === 'my-bookmarks') {
190+
// fetch bookmarked ApiIds
191+
const bookmarkedApiIds = currentFilters._id.$in;
192+
// find ApiIds that are bookmarked and that contains Api Documentation
193+
apiIds = _.intersection(bookmarkedApiIds, apiIds);
194+
}
195+
196+
// Set filter for filtering out apiIds that dont contain Api Documentation
197+
currentFilters._id = { $in: apiIds };
198+
}
199+
159200
instance.pagination.filters(currentFilters);
160201
});
161202
});

apinf_packages/api_catalog/client/toolbar/toolbar.html

Lines changed: 23 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -50,25 +50,32 @@
5050
</div>
5151
</form>
5252
</div>
53-
53+
5454
{{# if currentUser }}
55-
<div class="nav navbar-nav">
56-
<div class="btn-group navbar-btn filter-options-menu" role="group" aria-label="Filter options" data-toggle="buttons">
57-
<label class="btn btn-default active" id="filterBy-all">
58-
<input type="radio" name="filter-options" value="all" checked>
59-
{{_ "catalog_toolbar_filterOptions_showAll" }}
60-
</label>
61-
<label class="btn btn-default" id="filterBy-my-apis">
62-
<input type="radio" name="filter-options" value="my-apis">
63-
{{_ "catalog_toolbar_filterOptions_myApis" }}
64-
</label>
65-
<label class="btn btn-default" id="filterBy-my-bookmarks">
66-
<input type="radio" name="filter-options" value="my-bookmarks">
67-
{{_ "catalog_toolbar_filterOptions_myBookmarks" }}
68-
</label>
55+
<div class="nav navbar-nav">
56+
<div class="btn-group navbar-btn filter-options-menu" role="group" aria-label="Filter options" data-toggle="buttons">
57+
<label class="btn btn-default active" id="filterBy-all">
58+
<input type="radio" name="filter-options" value="all" checked>
59+
{{_ "catalog_toolbar_filterOptions_showAll" }}
60+
</label>
61+
<label class="btn btn-default" id="filterBy-my-apis">
62+
<input type="radio" name="filter-options" value="my-apis">
63+
{{_ "catalog_toolbar_filterOptions_myApis" }}
64+
</label>
65+
<label class="btn btn-default" id="filterBy-my-bookmarks">
66+
<input type="radio" name="filter-options" value="my-bookmarks">
67+
{{_ "catalog_toolbar_filterOptions_myBookmarks" }}
68+
</label>
69+
</div>
70+
<div class="btn-group" data-toggle="buttons">
71+
<label class="btn btn-default" id="filterBy-with-docs">
72+
<input type="checkbox" name="filter-api-documentation" value="with-docs">
73+
{{_ "catalog_toolbar_filterOptions_apisWithDocumentation" }}
74+
</label>
75+
</div>
6976
</div>
70-
</div>
7177
{{/ if }}
78+
7279
<div class="nav navbar-nav navbar-right">
7380
<a href="/rss/apis" target="_blank" class="rss-feed fa fa-rss-square fa-3x btn" title="{{_ 'apisRssIcon_tooltipText_Rss'}}">
7481
</a>

0 commit comments

Comments
 (0)