StreamElements / widgets

279 stars 118 forks source link

CustomCode.md documentation lacks #34

Open thekillgfx opened 2 years ago

thekillgfx commented 2 years ago

CustomEvent.type: redemption and CustomEvent.type: perk are not mentioned into the CustomCode.md documentation that's an heavy lack since a lot of creative and helpful widget could be developed thanks to Stream Store items redemption integration.

Updates will follow - I may provide a PR that include their documentation. Any help or contribution is welcomed!

thekillgfx commented 2 years ago

Didn't find anything about custom font from PC's fonts. It's important to restart the browser after font installations.

"customFont": {
    "label": "Custom Font Name",
    "type": "text",
    "value": "Franklin Gothic Heavy"
}
thekillgfx commented 2 years ago

Possible keys within data contains probably a lot of errors, I can assure that data["tip-monthly-top-donation"] and data["tip-monthly-top-donator"] don't return an Array but a single object instead.

SilicDev commented 2 years ago

As I'm currently toying around with redemption events, here some observations: event contains: itemId: a hex number it seems, probably the unique id of the redeemed item. type: perk in my case, this seems to be the different types of redemptions name: the username of the redeemer item: the name of the item _id: another hex number sessionTop: a boolean I suspect true if this was the highest amount of points spent this session otherwise false.

thekillgfx commented 2 years ago

onEventsReceived(obj) > obj.detail.recents The docs state that it should contain only the last 25 events, instead a lot more can be in there.

There is also a list in chronological order of last 25 events (so if you want to make list of all events - use this one) - variable recents initialized one line after variable data.

thekillgfx commented 2 years ago

At this point we support all of HTML5 input types (except of file)

I feel like this sentence isn't that much prominent as it should and it also feels wrong since SE editor seems to not support other types like radio. Coders could also find useful all the types about dates and time like date - datetime-local - month - week - time. reference: https://www.w3schools.com/html/html_form_input_types.asp