Skip to content

Commit b3fa421

Browse files
committed
Merge branch 'master' into modal-fix
2 parents 6cda0b0 + 991818f commit b3fa421

File tree

13 files changed

+154
-14
lines changed

13 files changed

+154
-14
lines changed

.github/CODEOWNERS

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# These owners will be the default owners for everything in
22
# the repo. Unless a later match takes precedence, they will
33
# be requested for review when someone opens a pull request.
4-
* @creativecommons/frontend @creativecommons/community-chooser
4+
* @creativecommons/frontend @creativecommons/ct-chooser-maintainers

src/App.vue

+1
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ export default {
111111
-moz-osx-font-smoothing: grayscale;
112112
color: #2c3e50;
113113
counter-reset: step-counter;
114+
background-color: #f5f5f5;
114115
}
115116
#site-container {
116117
padding: 0.75rem;

src/assets/license-icons/by.svg

+17
Loading

src/assets/license-icons/cc.svg

+26
Loading

src/assets/license-icons/nc.svg

+20
Loading

src/assets/license-icons/nd.svg

+17
Loading

src/assets/license-icons/sa.svg

+19
Loading

src/assets/license-icons/zero.svg

+23
Loading

src/components/LicenseCopy.vue

+3
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,9 @@ export default {
167167
#attribution-text p {
168168
margin-top: 0.5rem;
169169
margin-bottom: 1rem;
170+
background-color: #fff;
171+
padding: 24px 0 0 24px;
172+
height: 100px;
170173
}
171174
#generated-html-container {
172175
padding-top: 10px;

src/components/LicenseDetailsCard.vue

+5-5
Original file line numberDiff line numberDiff line change
@@ -108,19 +108,19 @@ export default {
108108
background-size: 35px 35px;
109109
}
110110
.license-list-item.zero::before {
111-
background-image: url("../assets/license-icons/cc-cc0_icon.svg");
111+
background-image: url("../assets/license-icons/zero.svg");
112112
}
113113
.license-list-item.by::before {
114-
background-image: url("../assets/license-icons/cc-by_icon.svg");
114+
background-image: url("../assets/license-icons/by.svg");
115115
}
116116
.license-list-item.nc::before {
117-
background-image: url("../assets/license-icons/cc-nc_icon.svg");
117+
background-image: url("../assets/license-icons/nc.svg");
118118
}
119119
.license-list-item.nd::before {
120-
background-image: url("../assets/license-icons/cc-nd_icon.svg");
120+
background-image: url("../assets/license-icons/nd.svg");
121121
}
122122
.license-list-item.sa::before {
123-
background-image: url("../assets/license-icons/cc-sa_icon.svg");
123+
background-image: url("../assets/license-icons/sa.svg");
124124
}
125125
.readable-string {
126126
padding-left:51px;

src/components/LicenseIcons.vue

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@
1010
class="photo-license-icon"
1111
alt="CC icon"
1212
title="CC icon"
13-
src="../assets/license-icons/cc_icon.svg"
13+
src="../assets/license-icons/cc.svg"
1414
>
1515
<img
1616
v-for="(license, index) in iconsArr"
1717
:key="index"
1818
class="photo-license-icon"
1919
:alt="license + ' icon'"
2020
:title="license + ' icon'"
21-
:src="require(`../assets/license-icons/cc-${license.toLowerCase()}_icon.svg`)"
21+
:src="require(`../assets/license-icons/${license.toLowerCase()}.svg`)"
2222
>
2323
</a>
2424
</template>

src/components/Stepper.vue

+13-1
Original file line numberDiff line numberDiff line change
@@ -380,6 +380,10 @@ export default {
380380
.current,
381381
.previous {
382382
color: black;
383+
background-color: #fff;
384+
}
385+
.inactive{
386+
background-color: #F5F5F5;
383387
}
384388
.previous.disabled {
385389
color: #B0B0B0;
@@ -396,10 +400,17 @@ export default {
396400
.step-navigation .pagination-previous {
397401
font-family: Roboto Condensed,sans-serif;
398402
font-style: normal;
399-
font-weight: 500;
400403
font-size: 18px;
401404
line-height: 24px;
402405
}
406+
.step-navigation,
407+
.step-navigation {
408+
font-weight: 500;
409+
}
410+
.pagination-next,
411+
.pagination-previous {
412+
font-weight: bold;
413+
}
403414
.step-navigation .pagination-previous {
404415
border: 2px solid #787878;
405416
color: #787878;
@@ -411,6 +422,7 @@ export default {
411422
}
412423
.pagination-next.disabled {
413424
background-color: #D8D8D8;
425+
color: #787878 !important;
414426
}
415427
.pagination-next.disabled:hover,
416428
.pagination-next.disabled:active {

src/utils/license-utilities.js

+7-5
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ function attrToFull(attr) {
4343

4444
function licenseUrl(attr, mode) {
4545
// Returns url to license from short license name with version number (eg. 'CC BY 4.0')
46-
// mode: web/ print (?ref=ccchooser is added to the end of the link if mode is web)
47-
const linkRef = mode === 'web' ? '/?ref=ccchooser' : ''
46+
// mode: web/ print (?ref=chooser-v1 is added to the end of the link if mode is web)
47+
const linkRef = mode === 'web' ? '/?ref=chooser-v1' : ''
4848
if (attr.BY === false) {
4949
return `https://creativecommons.org/publicdomain/zero/1.0${linkRef}`
5050
}
@@ -125,13 +125,14 @@ function generateHTML(attributionDetails, shortLicenseName) {
125125
' xmlns:cc="http://creativecommons.org/ns#"' +
126126
' class="license-text">'
127127
const iconStyle = 'style="height:22px!important;margin-left: 3px;vertical-align:text-bottom;"'
128-
const baseAssetsPath = 'https://search.creativecommons.org/static/img'
129-
let licenseIcons = `<img ${iconStyle} src="${baseAssetsPath}/cc_icon.svg" />`
128+
const baseAssetsPath = 'https://mirrors.creativecommons.org/presskit/icons'
129+
const linkRef = '?ref=chooser-v1'
130+
let licenseIcons = `<img ${iconStyle} src="${baseAssetsPath}/cc.svg/${linkRef}" />`
130131
if (shortLicenseName.includes('CC0')) {
131132
shortLicenseName = 'CC CC0 1.0'
132133
}
133134
licenseIcons += shortLicenseName.slice(3, shortLicenseName.length - 4).split('-').map(license =>
134-
`<img ${iconStyle} src="${baseAssetsPath}/cc-${license.toLowerCase()}_icon.svg" />`
135+
`<img ${iconStyle} src="${baseAssetsPath}/${license.toLowerCase()}.svg/${linkRef}" />`
135136
).join('')
136137
dataForHtmlGeneration.licenseIconsLink = `<a href="${licenseUrl(shortToAttr(shortLicenseName))}">${licenseIcons}</a>`
137138

@@ -153,6 +154,7 @@ function generateHTML(attributionDetails, shortLicenseName) {
153154
}
154155
return dataForHtmlGeneration
155156
}
157+
156158
export {
157159
defaultAttributes, CC0Attributes, CCBYAttributes, shortToAttr, attrToShort,
158160
attrToFull, licenseUrl, licenseSlug, licenseIconsArr, generateHTML, updateVisibleEnabledStatus

0 commit comments

Comments
 (0)