Skip to content

Commit 137627e

Browse files
authored
[ts] Update definitions for I{Cre,Upd}ateArticle (#653)
1 parent fd6d034 commit 137627e

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

types/index.d.ts

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -996,32 +996,32 @@ declare namespace Shopify {
996996
}
997997

998998
interface ICreateArticle {
999-
author: string;
1000-
body_html: string;
999+
author?: string;
1000+
body_html?: string;
10011001
handle?: string;
1002-
image?: IBase64Image;
1002+
image?: ICreateArticleImage;
10031003
metafields?: ICreateObjectMetafield[];
10041004
published?: boolean;
10051005
published_at?: string;
10061006
summary_html?: string | null;
10071007
tags?: string;
10081008
template_suffix?: string | null;
1009-
title: string;
1009+
title?: string;
10101010
user_id?: number;
10111011
}
10121012

10131013
interface IUpdateArticle {
1014-
author: string;
1015-
body_html: string;
1014+
author?: string;
1015+
body_html?: string;
10161016
handle?: string;
1017-
image?: IBase64Image;
1017+
image?: ICreateArticleImage;
10181018
metafields?: ICreateObjectMetafield[];
10191019
published?: boolean;
10201020
published_at?: string;
10211021
summary_html?: string | null;
10221022
tags?: string;
10231023
template_suffix?: string | null;
1024-
title: string;
1024+
title?: string;
10251025
user_id?: number;
10261026
}
10271027

@@ -1034,8 +1034,10 @@ declare namespace Shopify {
10341034
alt: string | null;
10351035
}
10361036

1037-
interface IBase64Image {
1038-
attachment: string;
1037+
interface ICreateArticleImage {
1038+
attachment?: string;
1039+
src?: string;
1040+
alt?: string;
10391041
}
10401042

10411043
interface IObjectMetafield {

0 commit comments

Comments
 (0)