refactor: refactor SCThingTypes from union-type to enum. SCThingType-type-attributes are now string-type-attributes.

This commit is contained in:
Michel Jonathan Schmitz
2018-12-05 18:51:28 +01:00
parent 641eff15b8
commit f9056eeb33
25 changed files with 134 additions and 192 deletions

View File

@@ -18,15 +18,10 @@ import {
SCCreativeWorkWithoutReferences,
} from '../base/CreativeWork';
import {SCThingThatCanBeOfferedTranslatableProperties} from '../base/ThingThatCanBeOffered';
import {SCThingMeta} from '../Thing';
import {SCThingMeta, SCThingType} from '../Thing';
import {SCTranslations} from '../types/i18n';
import {SCISO8601Date} from '../types/Time';
/**
* Type of a message
*/
export type SCMessageType = 'message';
/**
* A message without references
*/
@@ -54,7 +49,7 @@ export interface SCMessageWithoutReferences extends SCCreativeWorkWithoutReferen
/**
* Type of a message
*/
type: SCMessageType;
type: SCThingType.Message;
}
/**
@@ -69,7 +64,7 @@ export interface SCMessage extends SCCreativeWork, SCMessageWithoutReferences {
/**
* Type of a message
*/
type: SCMessageType;
type: SCThingType.Message;
}
/**