Skip to content

Commit

Permalink
Adding language XDM schema, making changes to emailFormat enum
Browse files Browse the repository at this point in the history
  • Loading branch information
aarjain committed Apr 5, 2018
1 parent 1f01198 commit 0908546
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 6 deletions.
4 changes: 4 additions & 0 deletions schemas/context/language.example.1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"xdm:format": "iso-639-1",
"xdm:languageCode": "en"
}
42 changes: 42 additions & 0 deletions schemas/context/language.schema.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"meta:license": [
"Copyright 2017 Adobe Systems Incorporated. All rights reserved.",
"This work is licensed under a Creative Commons Attribution 4.0 International (CC BY 4.0) license",
"you may not use this file except in compliance with the License. You may obtain a copy",
"of the License at https://creativecommons.org/licenses/by/4.0/"
],
"$id": "https://ns.adobe.com/xdm/context/language",
"$schema": "http://json-schema.org/draft-06/schema#",
"title": "Language",
"type": "object",
"description":
"The system of communication used by a particular person, country or community.",
"definitions": {
"language": {
"properties": {
"xdm:format": {
"title": "Format Identifier",
"type": "string",
"description":
"Standardized nomenclature used to classify the language",
"meta:enum": {
"iso-639-1": "ISO-639-1",
"bcp-47": "BCP-47"
}
},
"xdm:languageCode": {
"title": "language",
"type": "string",
"description":
"The code assigned to the language, adhering to the language format."
}
}
}
},
"allOf": [
{
"$ref": "#/definitions/language"
}
],
"meta:status": "experimental"
}
12 changes: 6 additions & 6 deletions schemas/context/profile.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -93,8 +93,9 @@
},
"xdm:preferredLanguage": {
"title": "Preferred Language",
"type": "string",
"description": "Preferred language based on ISO-639-1 format"
"$ref": "https://ns.adobe.com/xdm/context/language",
"description":
"Describes the preferred system of communication used by the profile."
},
"xdm:profilePictureLink": {
"title": "Profile Picture Link",
Expand All @@ -104,12 +105,11 @@
"xdm:emailFormat": {
"title": "Email Format",
"type": "string",
"description": "Email format relevant to the user. This can be HTML/Text/Unknown",
"default": "unknown",
"description":
"Email format relevant to the user. This can be HTML/Plain Text",
"meta:enum": {
"html": "HTML",
"text": "Text",
"unknown": "Unknown"
"plaintext": "Plain Text"
}
},
"xdm:geoUnitID": {
Expand Down

0 comments on commit 0908546

Please sign in to comment.