Skip to content

Commit

Permalink
fix: Missing props in MessagesPassThroughMethodOptions and MessagesPr…
Browse files Browse the repository at this point in the history
…ops (#6909)
  • Loading branch information
ivanpajon authored Jul 20, 2024
1 parent 54a8ee6 commit faf964a
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 0 deletions.
40 changes: 40 additions & 0 deletions components/doc/common/apidoc/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -35548,6 +35548,14 @@
"type": "CSSTransitionProps",
"default": "",
"description": "The properties of CSSTransition can be customized, except for \"nodeRef\" and \"in\" properties."
},
{
"name": "unstyled",
"optional": true,
"readonly": false,
"type": "boolean",
"default": "false",
"description": "When enabled, it removes component related styles in the core."
}
]
},
Expand Down Expand Up @@ -35596,6 +35604,24 @@
"optional": false,
"readonly": false,
"type": "MessagesProps"
},
{
"name": "state",
"optional": false,
"readonly": false,
"type": "MessagesState"
},
{
"name": "hostName",
"optional": true,
"readonly": false,
"type": "string"
},
{
"name": "index",
"optional": true,
"readonly": false,
"type": "number"
}
],
"callbacks": []
Expand Down Expand Up @@ -35670,6 +35696,20 @@
],
"callbacks": []
},
"MessagesState": {
"description": "Defines current inline state in Messages component.",
"relatedProp": "",
"props": [
{
"name": "messages",
"optional": false,
"readonly": false,
"type": "Object[]",
"description": "Array of messages"
}
],
"callbacks": []
},
"MessagesMessage": {
"relatedProp": "",
"props": [
Expand Down
21 changes: 21 additions & 0 deletions components/lib/messages/messages.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ export declare type MessagesPassThroughTransitionType = ReactCSSTransitionProps
*/
export interface MessagesPassThroughMethodOptions {
props: MessagesProps;
state: MessagesState;
hostName?: string;
index?: number;
}

/**
Expand Down Expand Up @@ -68,6 +71,19 @@ export interface MessagesPassThroughOptions {
transition?: MessagesPassThroughTransitionType;
}

/**
* Defines current inline state in Messages component.
*/
export interface MessagesState {
/**
* Array of messages
*/
messages: Array<{
_pId: number;
message: MessagesMessage;
}>;
}

export interface MessagesMessage {
/**
* Unique id of the message.
Expand Down Expand Up @@ -163,6 +179,11 @@ export interface MessagesProps extends Omit<React.DetailedHTMLProps<React.HTMLAt
* @type {PassThroughOptions}
*/
ptOptions?: PassThroughOptions;
/**
* When enabled, it removes component related styles in the core.
* @defaultValue false
*/
unstyled?: boolean;
}

/**
Expand Down

0 comments on commit faf964a

Please sign in to comment.