Skip to content

Commit

Permalink
swap to slug on featured games
Browse files Browse the repository at this point in the history
  • Loading branch information
seangeng committed Oct 29, 2024
1 parent 2b45b16 commit 1a787a3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
13 changes: 8 additions & 5 deletions src/api/featured-game/content-types/featured-game/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,26 @@
"info": {
"singularName": "featured-game",
"pluralName": "featured-games",
"displayName": "Featured Games"
"displayName": "Featured Games",
"description": ""
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {},
"attributes": {
"gameId": {
"type": "uid",
"required": true
},
"recommended": {
"type": "boolean",
"required": false
},
"editorBlurb": {
"type": "text"
},
"slug": {
"type": "string",
"required": true,
"unique": true,
"regex": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
}
}
}
3 changes: 2 additions & 1 deletion types/generated/contentTypes.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -998,14 +998,15 @@ export interface ApiFeaturedGameFeaturedGame extends Schema.CollectionType {
singularName: 'featured-game';
pluralName: 'featured-games';
displayName: 'Featured Games';
description: '';
};
options: {
draftAndPublish: true;
};
attributes: {
gameId: Attribute.UID & Attribute.Required;
recommended: Attribute.Boolean;
editorBlurb: Attribute.Text;
slug: Attribute.String & Attribute.Required & Attribute.Unique;
createdAt: Attribute.DateTime;
updatedAt: Attribute.DateTime;
publishedAt: Attribute.DateTime;
Expand Down

0 comments on commit 1a787a3

Please sign in to comment.