-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Localization, English + French (#223)
- Loading branch information
1 parent
5d78397
commit bf8b374
Showing
43 changed files
with
963 additions
and
228 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
{ | ||
"checkepub": { | ||
"metadataviolation": { | ||
"testdesc": "Ensures a '{{name}}' metadata is present", | ||
"resdesc": "Add a '{{name}}' metadata property to the Package Document", | ||
"ruledesc": "Publications must declare the '{{name}}' metadata", | ||
"kbtitle": "Schema.org Accessibility Metadata" | ||
}, | ||
"titleviolation": { | ||
"testdesc": "Ensures the EPUB has a title", | ||
"resdesc": "Add a 'dc:title' metadata property to the Package Document", | ||
"ruledesc": "Publications must have a title", | ||
"kbtitle": "EPUB Title" | ||
}, | ||
"pagesourceviolation": { | ||
"testdesc": "Ensures the source of page breaks is identified", | ||
"resdesc": "Add a 'dc:source' metadata property to the Package Document", | ||
"ruledesc": "Publications with page breaks must declare the 'dc:source' metadata", | ||
"kbtitle": "Page Navigation" | ||
} | ||
}, | ||
"axecheck": { | ||
"matching-aria-role": { | ||
"pass": "Element has an ARIA role matching its epub:type", | ||
"fail": "Element has no ARIA role matching its epub:type" | ||
} | ||
}, | ||
"axerule": { | ||
"pagebreak-label": { | ||
"desc": "Ensure page markers have an accessible label" | ||
}, | ||
"epub-type-has-matching-role": { | ||
"help": "ARIA role should be used in addition to epub:type", | ||
"desc": "Ensure the element has an ARIA role matching its epub:type" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
{ | ||
"checkepub": { | ||
"metadataviolation": { | ||
"testdesc": "Vérifie que la métadonnée '{{name}}' est présente", | ||
"resdesc": "Ajouter la métadonnée '{{name}}' au Document de Package", | ||
"ruledesc": "Toute publication doit déclarer la métadonnée '{{name}}'", | ||
"kbtitle": "Métadonnées d'accessibilité Schema.org" | ||
}, | ||
"titleviolation": { | ||
"testdesc": "Vérifie que le EPUB a un titre", | ||
"resdesc": "Ajouter la métadonnée 'dc:title' au Document de Package", | ||
"ruledesc": "Une publication doit avoir un titre", | ||
"kbtitle": "Titre de l’EPUB" | ||
}, | ||
"pagesourceviolation": { | ||
"testdesc": "Vérifie que la source des sauts de page est identifiée", | ||
"resdesc": "Ajouter la métadonnée 'dc:source' au Document de Package", | ||
"ruledesc": "Une publication avec des sauts de page doit déclarer la métadonnée 'dc:source'", | ||
"kbtitle": "Navigation par page" | ||
} | ||
}, | ||
"axecheck": { | ||
"matching-aria-role": { | ||
"pass": "L’élément a un rôle ARIA correspondant à son epub:type", | ||
"fail": "L’élément n’a pas de rôle ARIA correspondant à son epub:type" | ||
} | ||
}, | ||
"axerule": { | ||
"pagebreak-label": { | ||
"desc": "Vérifie que les sauts de page ont un label accessible" | ||
}, | ||
"epub-type-has-matching-role": { | ||
"help": "Un rôle ARIA devrait être spécifié en plus de l’epub:type", | ||
"desc": "Vérifie qu’un élément a un rôle ARIA correspondant à son epub:type" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
const { newLocalizer } = require('@daisy/ace-localize'); | ||
|
||
const enJson = require("./locales/en.json"); | ||
const frJson = require("./locales/fr.json"); | ||
|
||
export const localizer = newLocalizer({ | ||
en: { | ||
name: "English", | ||
default: true, | ||
translation: enJson, | ||
}, | ||
fr: { | ||
name: "Français", | ||
translation: frJson, | ||
}, | ||
}); |
Oops, something went wrong.