diff options
author | 2018-12-09 20:48:25 +0100 | |
---|---|---|
committer | 2018-12-09 20:48:25 +0100 | |
commit | 5d6164973e92fa8a3e3c18a0eb2e29494aea4f48 (patch) | |
tree | 382e6c672bbc0f7582b3b627b02111dcce902894 /src/models | |
parent | Add React 16 didCatch/ErrorBoundary component (diff) | |
download | ferdium-app-5d6164973e92fa8a3e3c18a0eb2e29494aea4f48.tar.gz ferdium-app-5d6164973e92fa8a3e3c18a0eb2e29494aea4f48.tar.zst ferdium-app-5d6164973e92fa8a3e3c18a0eb2e29494aea4f48.zip |
Fix linting issues
Diffstat (limited to 'src/models')
-rw-r--r-- | src/models/News.js | 3 | ||||
-rw-r--r-- | src/models/Order.js | 5 | ||||
-rw-r--r-- | src/models/Plan.js | 1 | ||||
-rw-r--r-- | src/models/Recipe.js | 12 | ||||
-rw-r--r-- | src/models/RecipePreview.js | 6 | ||||
-rw-r--r-- | src/models/Service.js | 21 | ||||
-rw-r--r-- | src/models/User.js | 17 |
7 files changed, 63 insertions, 2 deletions
diff --git a/src/models/News.js b/src/models/News.js index caf1d70e5..acacb97dd 100644 --- a/src/models/News.js +++ b/src/models/News.js | |||
@@ -2,8 +2,11 @@ | |||
2 | 2 | ||
3 | export default class News { | 3 | export default class News { |
4 | id = ''; | 4 | id = ''; |
5 | |||
5 | message = ''; | 6 | message = ''; |
7 | |||
6 | type = 'primary'; | 8 | type = 'primary'; |
9 | |||
7 | sticky = false; | 10 | sticky = false; |
8 | 11 | ||
9 | constructor(data) { | 12 | constructor(data) { |
diff --git a/src/models/Order.js b/src/models/Order.js index 0e10b01d6..f7624c627 100644 --- a/src/models/Order.js +++ b/src/models/Order.js | |||
@@ -1,9 +1,14 @@ | |||
1 | export default class Order { | 1 | export default class Order { |
2 | id = ''; | 2 | id = ''; |
3 | |||
3 | subscriptionId = ''; | 4 | subscriptionId = ''; |
5 | |||
4 | name = ''; | 6 | name = ''; |
7 | |||
5 | invoiceUrl = ''; | 8 | invoiceUrl = ''; |
9 | |||
6 | price = ''; | 10 | price = ''; |
11 | |||
7 | date = ''; | 12 | date = ''; |
8 | 13 | ||
9 | constructor(data) { | 14 | constructor(data) { |
diff --git a/src/models/Plan.js b/src/models/Plan.js index c7b4a0962..3dedf0d5e 100644 --- a/src/models/Plan.js +++ b/src/models/Plan.js | |||
@@ -5,6 +5,7 @@ export default class Plan { | |||
5 | id: '', | 5 | id: '', |
6 | price: 0, | 6 | price: 0, |
7 | } | 7 | } |
8 | |||
8 | year = { | 9 | year = { |
9 | id: '', | 10 | id: '', |
10 | price: 0, | 11 | price: 0, |
diff --git a/src/models/Recipe.js b/src/models/Recipe.js index 43c44514c..b0d60e75e 100644 --- a/src/models/Recipe.js +++ b/src/models/Recipe.js | |||
@@ -5,21 +5,33 @@ import path from 'path'; | |||
5 | 5 | ||
6 | export default class Recipe { | 6 | export default class Recipe { |
7 | id = ''; | 7 | id = ''; |
8 | |||
8 | name = ''; | 9 | name = ''; |
10 | |||
9 | description = ''; | 11 | description = ''; |
12 | |||
10 | version = ''; | 13 | version = ''; |
14 | |||
11 | path = ''; | 15 | path = ''; |
12 | 16 | ||
13 | serviceURL = ''; | 17 | serviceURL = ''; |
14 | 18 | ||
15 | hasDirectMessages = true; | 19 | hasDirectMessages = true; |
20 | |||
16 | hasIndirectMessages = false; | 21 | hasIndirectMessages = false; |
22 | |||
17 | hasNotificationSound = false; | 23 | hasNotificationSound = false; |
24 | |||
18 | hasTeamId = false; | 25 | hasTeamId = false; |
26 | |||
19 | hasPredefinedUrl = false; | 27 | hasPredefinedUrl = false; |
28 | |||
20 | hasCustomUrl = false; | 29 | hasCustomUrl = false; |
30 | |||
21 | hasHostedOption = false; | 31 | hasHostedOption = false; |
32 | |||
22 | urlInputPrefix = ''; | 33 | urlInputPrefix = ''; |
34 | |||
23 | urlInputSuffix = ''; | 35 | urlInputSuffix = ''; |
24 | 36 | ||
25 | message = ''; | 37 | message = ''; |
diff --git a/src/models/RecipePreview.js b/src/models/RecipePreview.js index 7470d757a..cfb22f860 100644 --- a/src/models/RecipePreview.js +++ b/src/models/RecipePreview.js | |||
@@ -2,8 +2,12 @@ | |||
2 | 2 | ||
3 | export default class RecipePreview { | 3 | export default class RecipePreview { |
4 | id = ''; | 4 | id = ''; |
5 | |||
5 | name = ''; | 6 | name = ''; |
6 | icon = ''; // TODO: check if this isn't replaced by `icons` | 7 | |
8 | icon = ''; | ||
9 | |||
10 | // TODO: check if this isn't replaced by `icons` | ||
7 | featured = false; | 11 | featured = false; |
8 | 12 | ||
9 | constructor(data) { | 13 | constructor(data) { |
diff --git a/src/models/Service.js b/src/models/Service.js index 5ec42af80..03aec773b 100644 --- a/src/models/Service.js +++ b/src/models/Service.js | |||
@@ -6,9 +6,13 @@ const debug = require('debug')('Franz:Service'); | |||
6 | 6 | ||
7 | export default class Service { | 7 | export default class Service { |
8 | id = ''; | 8 | id = ''; |
9 | |||
9 | recipe = ''; | 10 | recipe = ''; |
11 | |||
10 | webview = null; | 12 | webview = null; |
13 | |||
11 | timer = null; | 14 | timer = null; |
15 | |||
12 | events = {}; | 16 | events = {}; |
13 | 17 | ||
14 | isAttached = false; | 18 | isAttached = false; |
@@ -16,26 +20,43 @@ export default class Service { | |||
16 | @observable isActive = false; // Is current webview active | 20 | @observable isActive = false; // Is current webview active |
17 | 21 | ||
18 | @observable name = ''; | 22 | @observable name = ''; |
23 | |||
19 | @observable unreadDirectMessageCount = 0; | 24 | @observable unreadDirectMessageCount = 0; |
25 | |||
20 | @observable unreadIndirectMessageCount = 0; | 26 | @observable unreadIndirectMessageCount = 0; |
21 | 27 | ||
22 | @observable order = 99; | 28 | @observable order = 99; |
29 | |||
23 | @observable isEnabled = true; | 30 | @observable isEnabled = true; |
31 | |||
24 | @observable isMuted = false; | 32 | @observable isMuted = false; |
33 | |||
25 | @observable team = ''; | 34 | @observable team = ''; |
35 | |||
26 | @observable customUrl = ''; | 36 | @observable customUrl = ''; |
37 | |||
27 | @observable isNotificationEnabled = true; | 38 | @observable isNotificationEnabled = true; |
39 | |||
28 | @observable isBadgeEnabled = true; | 40 | @observable isBadgeEnabled = true; |
41 | |||
29 | @observable isIndirectMessageBadgeEnabled = true; | 42 | @observable isIndirectMessageBadgeEnabled = true; |
43 | |||
30 | @observable iconUrl = ''; | 44 | @observable iconUrl = ''; |
45 | |||
31 | @observable hasCustomUploadedIcon = false; | 46 | @observable hasCustomUploadedIcon = false; |
47 | |||
32 | @observable hasCrashed = false; | 48 | @observable hasCrashed = false; |
49 | |||
33 | @observable isDarkModeEnabled = false; | 50 | @observable isDarkModeEnabled = false; |
51 | |||
34 | @observable spellcheckerLanguage = null; | 52 | @observable spellcheckerLanguage = null; |
35 | 53 | ||
36 | @observable isFirstLoad = true; | 54 | @observable isFirstLoad = true; |
55 | |||
37 | @observable isLoading = true; | 56 | @observable isLoading = true; |
57 | |||
38 | @observable isError = false; | 58 | @observable isError = false; |
59 | |||
39 | @observable errorMessage = ''; | 60 | @observable errorMessage = ''; |
40 | 61 | ||
41 | constructor(data, recipe) { | 62 | constructor(data, recipe) { |
diff --git a/src/models/User.js b/src/models/User.js index 3e4aa187d..bec78fc16 100644 --- a/src/models/User.js +++ b/src/models/User.js | |||
@@ -2,19 +2,34 @@ import { observable } from 'mobx'; | |||
2 | 2 | ||
3 | export default class User { | 3 | export default class User { |
4 | id = null; | 4 | id = null; |
5 | |||
5 | @observable email = null; | 6 | @observable email = null; |
7 | |||
6 | @observable firstname = null; | 8 | @observable firstname = null; |
9 | |||
7 | @observable lastname = null; | 10 | @observable lastname = null; |
11 | |||
8 | @observable organization = null; | 12 | @observable organization = null; |
13 | |||
9 | @observable accountType = null; | 14 | @observable accountType = null; |
10 | @observable emailIsConfirmed = true; // better assume it's confirmed to avoid noise | 15 | |
16 | @observable emailIsConfirmed = true; | ||
17 | |||
18 | // better assume it's confirmed to avoid noise | ||
11 | @observable subscription = {}; | 19 | @observable subscription = {}; |
20 | |||
12 | @observable isSubscriptionOwner = false; | 21 | @observable isSubscriptionOwner = false; |
22 | |||
13 | @observable isPremium = false; | 23 | @observable isPremium = false; |
24 | |||
14 | @observable beta = false; | 25 | @observable beta = false; |
26 | |||
15 | @observable donor = {}; | 27 | @observable donor = {}; |
28 | |||
16 | @observable isDonor = false; | 29 | @observable isDonor = false; |
30 | |||
17 | @observable isMiner = false; | 31 | @observable isMiner = false; |
32 | |||
18 | @observable locale = false; | 33 | @observable locale = false; |
19 | 34 | ||
20 | constructor(data) { | 35 | constructor(data) { |