Skip to content

Commit

Permalink
Changes attribution close button label. Fixes #1075 (#1169)
Browse files Browse the repository at this point in the history
  • Loading branch information
LlGC-mag authored Oct 30, 2024
1 parent b808053 commit c394516
Show file tree
Hide file tree
Showing 15 changed files with 35 additions and 13 deletions.
1 change: 1 addition & 0 deletions src/content-handlers/iiif/BaseConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ export type CenterPanelOptions = {
export type CenterPanelContent = {
attribution: string;
close: string;
closeAttribution: string;
};

type CenterPanel = ModuleConfig & {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"alephCenterPanel": {
Expand All @@ -213,7 +214,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"settingsDialogue": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"avCenterPanel": {
Expand All @@ -250,6 +251,7 @@
"content": {
"attribution": "$attribution",
"close": "$close",
"closeAttribution": "$closeAttribution",
"currentTime": "$currentTime",
"delimiter": " - ",
"duration": "$duration",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"fileLinkCenterPanel": {
Expand All @@ -106,7 +107,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"footerPanel": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"ebookCenterPanel": {
Expand All @@ -208,7 +209,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"settingsDialogue": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"mediaelementCenterPanel": {
Expand All @@ -169,7 +170,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"restrictedDialogue": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"modelViewerCenterPanel": {
Expand All @@ -262,6 +263,7 @@
"content": {
"attribution": "$attribution",
"close": "$close",
"closeAttribution": "$closeAttribution",
"zoomIn": "$zoomIn",
"zoomOut": "$zoomOut",
"vr": "$vr"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"openSeadragonCenterPanel": {
Expand Down Expand Up @@ -364,6 +365,7 @@
"content": {
"attribution": "$attribution",
"close": "$close",
"closeAttribution": "$closeAttribution",
"goHome": "$goHome",
"imageUnavailable": "$imageUnavailable",
"next": "$next",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,8 @@
},
"content": {
"attribution": "$attribution",
"close": "$close"
"close": "$close",
"closeAttribution": "$closeAttribution"
}
},
"pdfCenterPanel": {
Expand All @@ -200,6 +201,7 @@
"content": {
"attribution": "$attribution",
"close": "$close",
"closeAttribution": "$closeAttribution",
"next": "$next",
"previous": "$previous"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ export class CenterPanel<
this.closeAttribution();

this.$closeAttributionButton = this.$attribution.find(".header .close");
this.$closeAttributionButton.attr("aria-label", this.content.close);
this.$closeAttributionButton.attr("aria-label", this.content.closeAttribution);
this.$closeAttributionButton.on("click", (e) => {
e.preventDefault();
this.closeAttribution();
Expand Down
1 change: 1 addition & 0 deletions src/locales/cy-GB.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"$contents": "Cynnwys",
"$volume": "cyfrol",
"$close": "Cau",
"$closeAttribution": "Cau panel priodoledd",
"$allPages": "Pob Tudalen",
"$currentViewAsJpg": "Delwedd ddethol {0} x {1}px (jpg)",
"$openNewWindow": "Agor mewn dwy ffenest newydd.",
Expand Down
1 change: 1 addition & 0 deletions src/locales/en-GB.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"$contents": "Contents",
"$volume": "volume",
"$close": "Close",
"$closeAttribution": "Close attribution panel",
"$allPages": "All Pages",
"$currentViewAsJpg": "Current view {0} x {1}px (jpg)",
"$openNewWindow": "Opens in a new window",
Expand Down
1 change: 1 addition & 0 deletions src/locales/fr-FR.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"$contents": "Contenus",
"$volume": "volume",
"$close": "Fermer",
"$closeAttribution": "Fermer le panneau d'attribution",
"$allPages": "Toutes les pages",
"$currentViewAsJpg": "Vue actuelle {0} x {1}px (jpg)",
"$openNewWindow": "Ouvre une nouvelle fenêtre",
Expand Down
1 change: 1 addition & 0 deletions src/locales/pl-PL.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"$contents": "Zawartość",
"$volume": "tom",
"$close": "Zamknij",
"$closeAttribution": "Zamknij panel atrybucji",
"$allPages": "Wszystkie strony",
"$currentViewAsJpg": "Aktualny widok {0} x {1}px (jpg)",
"$openNewWindow": "Otwiera się w nowym oknie",
Expand Down
1 change: 1 addition & 0 deletions src/locales/sv-SE.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"$contents": "Innehåll",
"$volume": "volym",
"$close": "Stäng",
"$closeAttribution": "Stäng upphovspanelen",
"$allPages": "Alla sidor",
"$currentViewAsJpg": "Aktuell vy {0} x {1}px (jpg)",
"$openNewWindow": "Öppnas i nytt fönster",
Expand Down

0 comments on commit c394516

Please sign in to comment.