Skip to content

Commit

Permalink
fix(CreativeWork): Make about property refer to ThingTypes
Browse files Browse the repository at this point in the history
  • Loading branch information
nokome committed May 25, 2021
1 parent 6ece114 commit 3d38a3e
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 21 deletions.
38 changes: 19 additions & 19 deletions py/stencila/schema/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -619,7 +619,7 @@ class CreativeWork(Thing):
etc.
"""

about: Optional[Array["Thing"]] = None
about: Optional[Array["ThingTypes"]] = None
"""The subject matter of the content."""

authors: Optional[Array[Union["Person", "Organization"]]] = None
Expand Down Expand Up @@ -700,7 +700,7 @@ class CreativeWork(Thing):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
comments: Optional[Array["Comment"]] = None,
Expand Down Expand Up @@ -810,7 +810,7 @@ class Article(CreativeWork):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
comments: Optional[Array["Comment"]] = None,
Expand Down Expand Up @@ -903,7 +903,7 @@ class Claim(CreativeWork):
def __init__(
self,
content: Array["BlockContent"],
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
claimType: Optional["EClaimType"] = None,
Expand Down Expand Up @@ -988,7 +988,7 @@ class Collection(CreativeWork):
def __init__(
self,
parts: Array["CreativeWorkTypes"],
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
comments: Optional[Array["Comment"]] = None,
Expand Down Expand Up @@ -1068,7 +1068,7 @@ class Comment(CreativeWork):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
commentAspect: Optional[str] = None,
Expand Down Expand Up @@ -1151,7 +1151,7 @@ class Datatable(CreativeWork):
def __init__(
self,
columns: Array["DatatableColumn"],
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
comments: Optional[Array["Comment"]] = None,
Expand Down Expand Up @@ -1250,7 +1250,7 @@ class MediaObject(CreativeWork):
def __init__(
self,
contentUrl: str,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
bitrate: Optional[float] = None,
Expand Down Expand Up @@ -1344,7 +1344,7 @@ class AudioObject(MediaObject):
def __init__(
self,
contentUrl: str,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
bitrate: Optional[float] = None,
Expand Down Expand Up @@ -1670,7 +1670,7 @@ class Figure(CreativeWork):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
caption: Optional[Union[Array["BlockContent"], str]] = None,
Expand Down Expand Up @@ -1858,7 +1858,7 @@ class ImageObject(MediaObject):
def __init__(
self,
contentUrl: str,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
bitrate: Optional[float] = None,
Expand Down Expand Up @@ -2556,7 +2556,7 @@ class Periodical(CreativeWork):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
comments: Optional[Array["Comment"]] = None,
Expand Down Expand Up @@ -2906,7 +2906,7 @@ class PublicationIssue(CreativeWork):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
comments: Optional[Array["Comment"]] = None,
Expand Down Expand Up @@ -3009,7 +3009,7 @@ class PublicationVolume(CreativeWork):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
comments: Optional[Array["Comment"]] = None,
Expand Down Expand Up @@ -3150,7 +3150,7 @@ class Review(CreativeWork):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
comments: Optional[Array["Comment"]] = None,
Expand Down Expand Up @@ -3237,7 +3237,7 @@ class SoftwareApplication(CreativeWork):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
comments: Optional[Array["Comment"]] = None,
Expand Down Expand Up @@ -3526,7 +3526,7 @@ class SoftwareSourceCode(CreativeWork):

def __init__(
self,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
codeRepository: Optional[str] = None,
Expand Down Expand Up @@ -3712,7 +3712,7 @@ class Table(CreativeWork):
def __init__(
self,
rows: Array["TableRow"],
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
caption: Optional[Union[Array["BlockContent"], str]] = None,
Expand Down Expand Up @@ -3918,7 +3918,7 @@ class VideoObject(MediaObject):
def __init__(
self,
contentUrl: str,
about: Optional[Array["Thing"]] = None,
about: Optional[Array["ThingTypes"]] = None,
alternateNames: Optional[Array[str]] = None,
authors: Optional[Array[Union["Person", "Organization"]]] = None,
bitrate: Optional[float] = None,
Expand Down
2 changes: 1 addition & 1 deletion r/R/types.R
Original file line number Diff line number Diff line change
Expand Up @@ -676,7 +676,7 @@ CreativeWork <- function(
url = url
)
self$type <- as_scalar("CreativeWork")
self[["about"]] <- check_property("CreativeWork", "about", FALSE, missing(about), Array(Thing), about)
self[["about"]] <- check_property("CreativeWork", "about", FALSE, missing(about), Array(ThingTypes), about)
self[["authors"]] <- check_property("CreativeWork", "authors", FALSE, missing(authors), Array(Union(Person, Organization)), authors)
self[["comments"]] <- check_property("CreativeWork", "comments", FALSE, missing(comments), Array(Comment), comments)
self[["content"]] <- check_property("CreativeWork", "content", FALSE, missing(content), Array(Node), content)
Expand Down
2 changes: 1 addition & 1 deletion schema/CreativeWork.schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ properties:
subject areas the creative work relates to).
type: array
items:
$ref: Thing
$ref: ThingTypes
authors:
'@id': schema:author
description: The authors of this creative work.
Expand Down

0 comments on commit 3d38a3e

Please sign in to comment.