Skip to content

Commit b74e686

Browse files
author
Ari
committed
Cleanup
1 parent 7b23870 commit b74e686

12 files changed

+99
-233
lines changed

src/components/AttributionDetailsStep.vue

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,35 @@
11
<template>
22
<div class="step-content">
3-
<div
4-
v-if="status==='current'"
5-
class="step-actions"
6-
>
3+
<div v-if="status==='current'"
4+
class="step-actions">
75
<p class="attribution-details-instructions">
86
{{ $t('stepper.AD.instructions') }}
97
</p>
108
<form class="attribution-details-form">
119
<b-field :label="this.$t('stepper.AD.form.creator-name.label')">
12-
<b-input
13-
v-model="creatorName"
10+
<b-input v-model="creatorName"
1411
:placeholder="this.$t('stepper.AD.form.creator-name.placeholder')"
1512
/>
1613
</b-field>
1714
<b-field :label="this.$t('stepper.AD.form.creator-profile.label')">
18-
<b-input
19-
v-model="creatorProfileUrl"
15+
<b-input v-model="creatorProfileUrl"
2016
:placeholder="this.$t('stepper.AD.form.creator-profile.placeholder')"
2117
/>
2218
</b-field>
2319
<b-field :label="this.$t('stepper.AD.form.work-title.label')">
24-
<b-input
25-
v-model="workTitle"
20+
<b-input v-model="workTitle"
2621
:placeholder="this.$t('stepper.AD.form.work-title.placeholder')"
2722
/>
2823
</b-field>
2924
<b-field :label="this.$t('stepper.AD.form.work-url.label')">
30-
<b-input
31-
v-model="workUrl"
25+
<b-input v-model="workUrl"
3226
:placeholder="this.$t('stepper.AD.form.work-url.placeholder')"
3327
/>
3428
</b-field>
3529
</form>
3630
</div>
3731
</div>
3832
</template>
39-
4033
<script>
4134
import { mapMutations, mapState } from 'vuex'
4235
@@ -83,7 +76,6 @@ export default {
8376
8477
}
8578
</script>
86-
8779
<style>
8880
.attribution-details-form {
8981
margin-top: 1rem;

src/components/CopyrightWaiverStep.vue

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,24 @@
11
<template>
22
<div class="step-content">
3-
<div
4-
v-if="status==='previous'"
5-
class="step-description vocab-body body-normal"
6-
>
3+
<div v-if="status==='previous'"
4+
class="step-description vocab-body body-normal">
75
<p class="vocab-body body-normal">
86
{{ $t('stepper.CW.selected') }}
97
</p>
108
</div>
11-
<div
12-
v-else-if="status==='current'"
13-
class="step-actions"
14-
>
9+
<div v-else-if="status==='current'"
10+
class="step-actions">
1511
<b-checkbox v-model="copyrightWaiverAgreed">
1612
{{ $t('stepper.CW.copyright-waive-agreement') }}
1713
</b-checkbox>
18-
<textarea
19-
:value="this.$t('cc0-waiver.text')"
20-
:class="'waiver-textarea'"
21-
/>
14+
<textarea :value="this.$t('cc0-waiver.text')"
15+
:class="'waiver-textarea'"/>
2216
<b-checkbox v-model="copyrightWaiverConfirmed">
2317
{{ $t("stepper.CW.copyright-waive-confirmation") }}
2418
</b-checkbox>
2519
</div>
2620
</div>
2721
</template>
28-
2922
<script>
3023
export default {
3124
name: 'CopyrightWaiverStep',
@@ -76,7 +69,6 @@ export default {
7669
}
7770
}
7871
</script>
79-
8072
<style lang="scss">
8173
.waiver-textarea {
8274
width: 100%;

src/components/DropdownStep.vue

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,13 @@
11
<template>
22
<div class="step-content">
3-
<div
4-
v-if="status==='previous'"
5-
class="step-description"
6-
>
3+
<div v-if="status==='previous'" class="step-description">
74
{{ cardText }}
85
</div>
9-
<div
10-
v-else-if="status==='current'"
11-
class="step-actions"
12-
>
6+
<div v-else-if="status==='current'" class="step-actions">
137
<LicenseDropdown @input="updateSelected" />
148
</div>
159
</div>
1610
</template>
17-
1811
<script>
1912
import { mapGetters } from 'vuex'
2013
import LicenseDropdown from './LicenseDropdown'
@@ -42,8 +35,4 @@ export default {
4235
}
4336
}
4437
}
45-
</script>
46-
47-
<style scoped>
48-
49-
</style>
38+
</script>

src/components/FirstStep.vue

Lines changed: 14 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,28 @@
11
<template>
22
<div class="step-content">
3-
<p
4-
v-if="status==='previous'"
5-
class="step-description vocab-body body-normal"
6-
>
3+
<p v-if="status==='previous'"
4+
class="step-description vocab-body body-normal">
75
{{ $t(cardText) }}
86
</p>
9-
<div
10-
v-else-if="status==='current'"
11-
class="step-actions"
12-
>
13-
<div
14-
class="field"
15-
:class="yesSelected"
16-
>
17-
<b-radio
18-
v-model="radio"
19-
native-value="yes"
20-
>
21-
<span
22-
class="vocab-body body-normal"
23-
>
24-
{{ $t('stepper.yes') }}{{ $t(yesText) }}</span>
7+
<div v-else-if="status==='current'" class="step-actions">
8+
<div class="field" :class="yesSelected">
9+
<b-radio v-model="radio"
10+
native-value="yes">
11+
<span class="vocab-body body-normal">
12+
{{ $t('stepper.yes') }}{{ $t(yesText) }}
13+
</span>
2514
</b-radio>
2615
</div>
27-
<div
28-
class="field"
29-
:class="noSelected"
30-
>
31-
<b-radio
32-
v-model="radio"
33-
native-value="no"
34-
>
35-
<span
36-
class="vocab-body body-normal"
37-
>{{ $t('stepper.no') }}{{ $t(noText) }}</span>
16+
<div class="field" :class="noSelected">
17+
<b-radio v-model="radio" native-value="no">
18+
<span class="vocab-body body-normal">
19+
{{ $t('stepper.no') }}{{ $t(noText) }}
20+
</span>
3821
</b-radio>
3922
</div>
4023
</div>
4124
</div>
4225
</template>
43-
4426
<script>
4527
export default {
4628
name: 'FirstStep',
@@ -84,7 +66,3 @@ export default {
8466
}
8567
}
8668
</script>
87-
88-
<style scoped>
89-
90-
</style>

src/components/HelpSection.vue

Lines changed: 12 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -4,30 +4,23 @@
44
{{ $t('help.heading') }}
55
</h3>
66
<ul class="help-links">
7-
<li
8-
v-for="(modal, idx) in modals"
7+
<li v-for="(modal, idx) in modals"
98
:key="idx"
10-
class="help-link"
11-
>
12-
<a
13-
class="vocab-body body-big help-link-a"
14-
@click="clickHandler(idx)"
15-
>{{ $t(`help.${modal.title}.heading`) }}</a>
9+
class="help-link">
10+
<a class="vocab-body body-big help-link-a"
11+
@click="clickHandler(idx)">
12+
{{ $t(`help.${modal.title}.heading`) }}
13+
</a>
1614
</li>
1715
</ul>
18-
1916
<b-modal :active.sync="modals[1].status">
2017
<header class="modal-card-head">
21-
<p
22-
class="modal-card-title modal-title"
23-
v-html="this.$t('help.what-are-cc-licenses.heading')"
24-
/>
18+
<p class="modal-card-title modal-title"
19+
v-html="this.$t('help.what-are-cc-licenses.heading')"/>
2520
</header>
2621
<section class="modal-card-body">
27-
<article
28-
class="help-text"
29-
v-html="this.$t('help.what-are-cc-licenses.text')"
30-
/>
22+
<article class="help-text"
23+
v-html="this.$t('help.what-are-cc-licenses.text')"/>
3124
<footer class="modal-card-foot">
3225
<p v-html="this.$t('help.what-are-cc-licenses.footer')" />
3326
</footer>
@@ -41,10 +34,8 @@
4134
</header>
4235
<section class="modal-card-body">
4336
<article v-html="this.$t('help.how-licenses-work.text')" />
44-
<footer
45-
class="modal-card-foot"
46-
v-html="this.$t('help.how-licenses-work.footer')"
47-
/>
37+
<footer class="modal-card-foot"
38+
v-html="this.$t('help.how-licenses-work.footer')"/>
4839
</section>
4940
</b-modal>
5041
<b-modal :active.sync="modals[3].status">

src/components/LicenseCode.vue

Lines changed: 22 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,28 @@
11
<template>
2-
<p
3-
xmlns:dct="http://purl.org/dc/terms/"
2+
<p xmlns:dct="http://purl.org/dc/terms/"
43
xmlns:cc="http://creativecommons.org/ns#"
5-
class="license-text"
6-
>
7-
<i18n
8-
path="license-use.richtext.full-text"
9-
tag="span"
10-
>
4+
class="license-text">
5+
<i18n path="license-use.richtext.full-text" tag="span">
116
<template v-slot:workTitle>
12-
<a
13-
v-if="workUrl && isWeb"
7+
<a v-if="workUrl && isWeb"
148
:href="workUrl"
15-
rel="cc:attributionURL"
16-
>
9+
rel="cc:attributionURL">
1710
<span v-if="!workTitle">{{ $t('license-use.richtext.workTitle') }}</span>
18-
<span
19-
v-else
20-
rel="dc:title"
21-
>{{ workTitle }}</span>
11+
<span v-else rel="dc:title">
12+
{{ workTitle }}
13+
</span>
2214
</a>
23-
<span
24-
v-else-if="workTitle"
25-
rel="dc:title"
26-
>{{ workTitle }}</span>
15+
<span v-else-if="workTitle" rel="dc:title">
16+
{{ workTitle }}
17+
</span>
2718
<span v-else>{{ $t('license-use.richtext.workTitle') }}</span>
2819
</template>
2920
<template v-slot:creator>
30-
<a
31-
v-if="creatorProfileUrl && isWeb"
21+
<a v-if="creatorProfileUrl && isWeb"
3222
:href="creatorProfileUrl"
33-
rel="cc:attributionURL"
34-
>
23+
rel="cc:attributionURL">
3524
<span v-html="creatorSpan" /></a>
36-
<span
37-
v-else-if="creatorName"
38-
v-html="creatorSpan"
39-
/>
25+
<span v-else-if="creatorName" v-html="creatorSpan" />
4026
</template>
4127
<template v-slot:by>
4228
{{ $t(byString) }}
@@ -45,33 +31,28 @@
4531
<span>{{ $t('license-use.richtext.licensed-text') }}</span>
4632
</template>
4733
<template v-slot:licenseName>
48-
<a
49-
v-if="isWeb"
34+
<a v-if="isWeb"
5035
:href="licenseUrl('web')"
5136
target="_blank"
5237
rel="license noopener noreferrer"
53-
style="display: inline-block;"
54-
>{{ shortName }}</a>
38+
style="display: inline-block;">
39+
{{ shortName }}
40+
</a>
5541
<span v-else>{{ shortName }}</span>
56-
<LicenseIcons
57-
v-if="isWeb"
42+
<LicenseIcons v-if="isWeb"
5843
:url="licenseUrl('web')"
59-
:icons-arr="iconsList"
60-
/>
44+
:icons-arr="iconsList" />
6145
</template>
6246
</i18n>
63-
<i18n
64-
v-if="!isWeb"
47+
<i18n v-if="!isWeb"
6548
path="license-use.richtext.print-instructions"
66-
tag="span"
67-
>
49+
tag="span">
6850
<template v-slot:linkToLicenseDeed>
6951
{{ licenseUrl('print') }}
7052
</template>
7153
</i18n>
7254
</p>
7355
</template>
74-
7556
<script>
7657
import { mapGetters, mapState } from 'vuex'
7758
import LicenseIcons from './LicenseIcons'

0 commit comments

Comments
 (0)