mirror of
https://github.com/marcogll/passkit-generator.git
synced 2026-03-15 21:25:26 +00:00
Improved EventDateInfo and set date as optional
This commit is contained in:
@@ -28,9 +28,8 @@ export const CurrencyAmount = Joi.object<CurrencyAmount>().keys({
|
||||
* @see \<undiclosed>
|
||||
*/
|
||||
|
||||
export type EventDateInfo =
|
||||
| {
|
||||
date: string;
|
||||
export interface EventDateInfo {
|
||||
date?: string;
|
||||
ignoreTimeComponents?: boolean;
|
||||
timeZone?: string;
|
||||
|
||||
@@ -41,11 +40,11 @@ export type EventDateInfo =
|
||||
* Leads to showing "TBA" in the UI when `date` is set.
|
||||
* Setting `ignoreTimeComponents` to true, has higher priority
|
||||
* over this property.
|
||||
*
|
||||
* When both `date` and `semantics.eventStartDate` are unset,
|
||||
* `Date: TBA` will be shown in the UI.
|
||||
*/
|
||||
unannounced?: boolean;
|
||||
}
|
||||
| {
|
||||
date?: string;
|
||||
|
||||
/**
|
||||
* @iOSVersion 18.1
|
||||
@@ -57,13 +56,11 @@ export type EventDateInfo =
|
||||
*
|
||||
* This property has higher priority over `unannounced`.
|
||||
*
|
||||
* --- Implementation note ---
|
||||
*
|
||||
* This is the reason it was splitted from unannounced above.
|
||||
* Furthermore, it apparently can live without specifying `date`.
|
||||
* When both `date` and `semantics.eventStartDate` are unset,
|
||||
* `Date: TBD` will be shown in the UI.
|
||||
*/
|
||||
undetermined: boolean;
|
||||
};
|
||||
undetermined?: boolean;
|
||||
}
|
||||
|
||||
export const EventDateInfo = Joi.alternatives(
|
||||
Joi.object<EventDateInfo>().keys({
|
||||
|
||||
Reference in New Issue
Block a user