By Jeremy Lindblom (@jeremeamia)
- New GitHub repo: slack-php/slack-php-block-kit
- New Composer package: slack-php/slack-block-kit
- New root namespace:
SlackPhp\BlockKit
DEPRECATED: Use https://github.com/slack-php/slack-php-block-kit instead
License: MIT License
By Jeremy Lindblom (@jeremeamia)
SlackPhp\BlockKit
Inputs\Button
throws an exception when no value
is set. However, I noticed that the Slack Block Kit docs say the value isn't required.
Am I missing something? Will submit a PR if not.
Right now we can build the Block Json from the Element Objects, but what if we have the json and want to modify/add/delete something ?
The best scenario for this, and the reason why i request this feature, is actually the External Data Source for the Select Menu. on interacting with the dropdown, slack will send a request to the App's configured Options Load Api :
https://api.slack.com/reference/block-kit/block-elements#external_select
apparently slack did not docuement the request body of this particular request they send but i have debugged it and it seems inside the view property they simply send back the same whole block json that was actually previously sent to slack to open the view.
in addition to that they send further information like what value was typed into the input field and stuff like that (not in the block part!)
So we need some kind of Parser which accepts this Block JSON and creates an Object Tree so we can then modify it and then encode to json like in status quo.
Can I send messages as attachments?
https://api.slack.com/reference/messaging/attachments#example
Thank you for this amazing package .
does this supports Overflow menu elements ?
https://api.slack.com/reference/block-kit/block-elements#overflow
Hi,
I'm getting error if modal title is more than 24 character long. I think we need to add some validation for modal title.
Errors I'm getting from slack api:
[0] => [ERROR] failed to match all allowed schemas [json-pointer:/view/title]
[1] => [ERROR] must be less than 24 characters [json-pointer:/view/title/text]
eg code:
$msg = SlackBuilder::newModal();
$msg->title('this is a really long title')
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.