diff --git a/src/schemas/Barcodes.ts b/src/schemas/Barcode.ts similarity index 91% rename from src/schemas/Barcodes.ts rename to src/schemas/Barcode.ts index 426289e..306bb68 100644 --- a/src/schemas/Barcodes.ts +++ b/src/schemas/Barcode.ts @@ -2,7 +2,6 @@ import Joi from "joi"; /** * @see https://developer.apple.com/documentation/walletpasses/pass/barcodes - * @TODO Rename "Barcode" in "Barcodes". It will be done in v3.0 */ export type BarcodeFormat = diff --git a/src/schemas/Beacons.ts b/src/schemas/Beacon.ts similarity index 88% rename from src/schemas/Beacons.ts rename to src/schemas/Beacon.ts index 47f4ff8..d8f8ea5 100644 --- a/src/schemas/Beacons.ts +++ b/src/schemas/Beacon.ts @@ -2,7 +2,6 @@ import Joi from "joi"; /** * @see https://developer.apple.com/documentation/walletpasses/pass/beacons - * @TODO Rename "Beacon" in "Beacons". This will be done in v3.0 */ export interface Beacon { diff --git a/src/schemas/PassFieldContent.ts b/src/schemas/Field.ts similarity index 93% rename from src/schemas/PassFieldContent.ts rename to src/schemas/Field.ts index 0445639..3f1b746 100644 --- a/src/schemas/PassFieldContent.ts +++ b/src/schemas/Field.ts @@ -1,9 +1,8 @@ import Joi from "joi"; -import { Semantics } from "./SemanticTags"; +import { Semantics } from "./Semantics"; /** * @see https://developer.apple.com/documentation/walletpasses/passfieldcontent - * @TODO Rename interface to PassFieldContent to conform to above. This will be done in v3.0 */ export interface Field { diff --git a/src/schemas/Location.ts b/src/schemas/Location.ts index 3e08cbb..18929a9 100644 --- a/src/schemas/Location.ts +++ b/src/schemas/Location.ts @@ -2,7 +2,6 @@ import Joi from "joi"; /** * @see https://developer.apple.com/documentation/walletpasses/pass/locations - * @TODO Rename "Location" in "Locations". This will be done in v3.0 */ export interface Location { diff --git a/src/schemas/PassFields.ts b/src/schemas/PassFields.ts index f85bbc8..96cd81d 100644 --- a/src/schemas/PassFields.ts +++ b/src/schemas/PassFields.ts @@ -1,5 +1,5 @@ import Joi from "joi"; -import { Field } from "./PassFieldContent"; +import { Field } from "./Field"; export type TransitType = | "PKTransitTypeAir" diff --git a/src/schemas/SemanticTags.ts b/src/schemas/Semantics.ts similarity index 98% rename from src/schemas/SemanticTags.ts rename to src/schemas/Semantics.ts index 423a037..e3a8993 100644 --- a/src/schemas/SemanticTags.ts +++ b/src/schemas/Semantics.ts @@ -52,8 +52,8 @@ const CurrencyAmount = Joi.object().keys({ amount: Joi.string(), }); -const PersonNameComponent = Joi.object().keys( - { +const PersonNameComponent = + Joi.object().keys({ givenName: Joi.string(), familyName: Joi.string(), middleName: Joi.string(), @@ -61,8 +61,7 @@ const PersonNameComponent = Joi.object().k nameSuffix: Joi.string(), nickname: Joi.string(), phoneticRepresentation: Joi.string(), - }, -); + }); const seat = Joi.object().keys({ seatSection: Joi.string(), diff --git a/src/schemas/index.ts b/src/schemas/index.ts index aaa282b..05d52ee 100644 --- a/src/schemas/index.ts +++ b/src/schemas/index.ts @@ -1,21 +1,21 @@ -export * from "./Barcodes"; -export * from "./Beacons"; +export * from "./Barcode"; +export * from "./Beacon"; export * from "./Location"; -export * from "./PassFieldContent"; +export * from "./Field"; export * from "./NFC"; -export * from "./SemanticTags"; +export * from "./Semantics"; export * from "./PassFields"; export * from "./Personalize"; export * from "./Certificates"; import Joi from "joi"; -import { Barcode } from "./Barcodes"; +import { Barcode } from "./Barcode"; import { Location } from "./Location"; -import { Beacon } from "./Beacons"; +import { Beacon } from "./Beacon"; import { NFC } from "./NFC"; import { PassFields, TransitType } from "./PassFields"; -import { Semantics } from "./SemanticTags"; +import { Semantics } from "./Semantics"; import { CertificatesSchema } from "./Certificates"; import formatMessage, * as Messages from "../messages";