1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2024-12-22 08:37:12 +00:00

fill changelog and add StoryShareParams factory function

This commit is contained in:
InsanusMokrassar 2024-08-01 17:38:16 +06:00
parent bd6ff747cb
commit 799ad6ca66
2 changed files with 20 additions and 1 deletions

View File

@ -4,6 +4,15 @@
**THIS UPDATE CONTAINS ADDING OF SUPPORT FOR BOTS API 7.8**
* `Core`:
* `OptionallyBusinessConnectionRequest` now extends `WithOptionalBusinessConnectionId`
* Add `hasMainWebApp` in `ExtendedBot`
* `API`:
* Add `BusinessConnectionId` to pin/unpin methods
* `WebApp`:
* Add `shareToStory` in `WebApp`
## 15.2.0

View File

@ -4,4 +4,14 @@ external interface StoryShareParams {
val text: String
@JsName("widget_link")
val widgetLink: StoryWidgetLink?
}
}
fun StoryShareParams(
text: String,
widgetLink: StoryWidgetLink?
): StoryShareParams {
val result: dynamic = js("{}")
result["text"] = text
widgetLink ?.let { result["widgetLink"] = it }
return result.unsafeCast<StoryShareParams>()
}