Skip to content

Commit 13af5bb

Browse files
committed
style: fix linter
1 parent 4cc14db commit 13af5bb

3 files changed

Lines changed: 21 additions & 20 deletions

File tree

app/controllers/index.js

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ export default class IndexController extends Controller {
135135
this.model.fields.forEach((field) => {
136136
// Find the original field.
137137
const originalField = this.model.originalFields.find(
138-
(f) => f.uuid === field.uuid
138+
(f) => f.uuid === field.uuid,
139139
);
140140
if (originalField) {
141141
// Check if the field has been updated.
@@ -194,12 +194,12 @@ export default class IndexController extends Controller {
194194
${this.stringifyFormSubject(
195195
this.model.loadedFormUri,
196196
this.model.formTargetClass,
197-
this.model.fields
197+
this.model.fields,
198198
)}
199199
${this.stringifyFields(
200200
this.model.loadedFormUri,
201201
this.model.formTargetClass,
202-
fieldsToInsert
202+
fieldsToInsert,
203203
)}
204204
}`;
205205
if (this.model.newForm) {
@@ -210,12 +210,12 @@ export default class IndexController extends Controller {
210210
${this.stringifyFormSubject(
211211
this.model.loadedFormUri,
212212
this.model.originalFormTargetClass,
213-
this.model.originalFields
213+
this.model.originalFields,
214214
)}
215215
${this.stringifyFields(
216216
this.model.loadedFormUri,
217217
this.model.originalFormTargetClass,
218-
fieldsToDelete
218+
fieldsToDelete,
219219
)}
220220
} .
221221
`;
@@ -243,8 +243,8 @@ export default class IndexController extends Controller {
243243
// Remove all N3 rules that are Submit event policies as we are regenerating them after this.
244244
const keepRules = await Promise.all(
245245
matches.rules.map(
246-
async (rule) => await this.isEventSubmitRule(rule, matches.prefixes)
247-
)
246+
async (rule) => await this.isEventSubmitRule(rule, matches.prefixes),
247+
),
248248
);
249249
matches.rules = matches.rules.filter((rule, index) => !keepRules[index]);
250250

@@ -257,17 +257,17 @@ export default class IndexController extends Controller {
257257
matches.prefixes = this.model.addIfNotIncluded(
258258
matches.prefixes,
259259
'ex',
260-
'http://example.org/'
260+
'http://example.org/',
261261
);
262262
matches.prefixes = this.model.addIfNotIncluded(
263263
matches.prefixes,
264264
'fno',
265-
'https://w3id.org/function/ontology#'
265+
'https://w3id.org/function/ontology#',
266266
);
267267
matches.prefixes = this.model.addIfNotIncluded(
268268
matches.prefixes,
269269
'pol',
270-
'https://www.example.org/ns/policy#'
270+
'https://www.example.org/ns/policy#',
271271
);
272272

273273
// Re-add the N3 rules to the resource.
@@ -277,7 +277,7 @@ export default class IndexController extends Controller {
277277
// On successful save, update the original fields to the current fields.
278278
this.model.originalFields = JSON.parse(JSON.stringify(this.model.fields));
279279
this.model.originalPolicies = JSON.parse(
280-
JSON.stringify(this.model.policies)
280+
JSON.stringify(this.model.policies),
281281
);
282282
this.model.originalFormTargetClass = this.model.formTargetClass;
283283
} else {
@@ -418,7 +418,7 @@ export default class IndexController extends Controller {
418418
// Do call to prefix.cc to get the full URI
419419
const [prefix, suffix] = binding.split(':');
420420
const response = await fetch(
421-
`https://prefixcc-proxy.smessie.com/${prefix}.file.json`
421+
`https://prefixcc-proxy.smessie.com/${prefix}.file.json`,
422422
);
423423
const json = await response.json();
424424
const uri = json[prefix];
@@ -551,7 +551,7 @@ export default class IndexController extends Controller {
551551
const reasonerResult = await n3reasoner(
552552
'?id <http://example.org/event> <http://example.org/Submit> .',
553553
query,
554-
options
554+
options,
555555
);
556556
return reasonerResult.length > 0;
557557
}
@@ -585,7 +585,7 @@ export default class IndexController extends Controller {
585585
removePolicy(policy, event) {
586586
event?.preventDefault();
587587
this.model.policies = this.model.policies.filter(
588-
(p) => p.uuid !== policy.uuid
588+
(p) => p.uuid !== policy.uuid,
589589
);
590590
}
591591

app/routes/index.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ export default class IndexRoute extends Route {
4747
if (this.solidAuth.loggedIn) {
4848
const storageRoot = await findStorageRoot(
4949
this.solidAuth.loggedIn,
50-
fetch
50+
fetch,
5151
);
5252
this.loadedFormUri = `${storageRoot}private/tests/forms/${uuid()}.n3#${uuid()}`;
5353
} else {
@@ -102,7 +102,7 @@ export default class IndexRoute extends Route {
102102
const reasonerResult = await n3reasoner(
103103
`?id <http://example.org/event> <http://example.org/Submit> .`,
104104
content,
105-
options
105+
options,
106106
);
107107

108108
// Parse policies.
@@ -161,7 +161,7 @@ export default class IndexRoute extends Route {
161161
new URL(this.loadedFormUri /*, await this.solidAuth.podBase*/).href,
162162
{
163163
method: 'GET',
164-
}
164+
},
165165
);
166166

167167
if (!response.ok) {
@@ -373,7 +373,7 @@ export default class IndexRoute extends Route {
373373
uri: row.get('field').value,
374374
type: row.get('type')?.value,
375375
widget: this.shaclTypeToWidget(
376-
row.get('type')?.value || row.get('nodeKind')?.value
376+
row.get('type')?.value || row.get('nodeKind')?.value,
377377
),
378378
nodeKind: row.get('nodeKind')?.value,
379379
property: row.get('property')?.value,
@@ -556,7 +556,7 @@ export default class IndexRoute extends Route {
556556
setTimeout(() => {
557557
this.fields = fields;
558558
resolve();
559-
}, 0)
559+
}, 0),
560560
);
561561
}
562562

@@ -567,7 +567,7 @@ export default class IndexRoute extends Route {
567567
setTimeout(() => {
568568
this.policies = policies;
569569
resolve();
570-
}, 0)
570+
}, 0),
571571
);
572572
}
573573

app/styles/app.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
.card {
22
margin-top: 1.5em;
33
}
4+
45
.margin-top {
56
margin-top: 1.5em;
67
}

0 commit comments

Comments
 (0)